One of the main contributing factors to GPS position accuracy is the geometric configuration (the position in the sky) of the satellites used to obtain a position.
The best position fix is given when a satellite is directly overhead and another three are equally spaced around the horizon.
This aspect is called the 'geometry' of the system and is measured as DOP (Dilution of Precision).
The influence of satellite geometry on imprecision is demonstrated in the image below. When both satellites are widely separated (figure left) the position error (area in red) is smaller. If the satellites are close to one another (right figure), then the area of error is more spread out. This is valid when the uncertainty for determining the position,
known as the Range Error (R-E: yellow and blue areas), is the same for both satellites. R (R1 and R2) refers to the
measured distance of the satellites to the user (pseudorange).

There are a number of different DOP elements which can be used, we will focus on HDOP (Horizontal-DOP).
The HDOP can be seen when using gpsmon. The image below has HDOP highlighted;
The HDOP can also be found in the GSA sentence. Below it is shown as 1.3;
$GPGSA,A,3,04,05,,09,12,,,24,,,,,2.5,1.3,2.1*39
A HDOP value of 1 or below would give you an accuracy of about 2.5 meters.
When in mountainous areas, forests and urban canyons, you can experience high HDOP values as some of the available satellites will be obstructed. The satellites used will be closer together creating a large area of error as the signal from each satellite have a larger intersect.

Out on the open sea, you should be able to see a low HDOP value as the satellites used would be spread out and has less area of a intersect.
