Calculating -R ymax from a given xmax and plot width

Kristof Koch <[email protected]>
Newsgroups gmane.comp.gis.gmt.user
Message-ID <[email protected]>
Dear List,

I'm trying to plot a Lambert Conformal Projection on it leaving a 5mm margin around it. I have a page of A4 paper in landscape orientation measuring 297mm x 210mm. After shifting the plot origin by +0.5c in x- & y-direction to get the left and lower margin, I use

-JLlon0/lat0/lat1/lat2/28.7c

to get the 5mm margin on the right side. To get the same margin at the upper border, I currently take a rough guess on the xmax and ymax values for -R...r and then tweaking these values until I get an eyeballed 5mm margin. This is not exact and becomes a really tedious task for charts at higher latitudes. 

Therefore I'm looking to automate this. My current thinking is to take my eyeballed -R xmax and calculate the required ymax value from xmax and the plot height of 200mm. I had a close look at mapproject -I, but my experimentation didn't yield anything useful so far. I have problems mixing the geodetical xmax with the Cartesian plot height.

Any input is greatly appreciated.

All the best,
Kristof

To unsubscribe, send the message "signoff gmt-help" to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.