[ncl-talk] exact location of a lat/lon coodrinates in the grid-box

Athanasios Karagiannidis thankar at live.com
Sat Dec 23 02:26:00 MST 2017


Dear Mary


Thank you for the very clear and informative response!


Kind regards


Athanasios F. Karagiannidis
Physicist, PhD Meteorology and Climatology
E-mail: thankar at live.com


________________________________
From: Mary Haley <haley at ucar.edu>
Sent: Friday, December 22, 2017 7:42 PM
To: Athanasios Karagiannidis
Cc: ncl-talk at ucar.edu
Subject: Re: [ncl-talk] exact location of a lat/lon coodrinates in the grid-box

Dear Athanasios,

It depends.

There are three contouring methods: AreaFill (the default), RasterFill, and CellFill.

For these methods, lat=20, lon=20 will represent the center of the box, except for one special case.

For RasterFill, if you set sfXArray and sfYArray to arrays that have one more element than the dimensions of your data array, then the lat/lon points will represent the corners of a box, rather than the center.

I've created a sample NCL script that shows the three methods, plus the fourth RasterFill method with the corners method. This script uses dummy data, so you should be able to run it as is.

--Mary


On Fri, Dec 22, 2017 at 10:20 AM, Athanasios Karagiannidis via ncl-talk <ncl-talk at ucar.edu<mailto:ncl-talk at ucar.edu>> wrote:


Dear sirs/madams



I have a question that I’m going to formulate it using an example:

Let’s say I have a dataset (Lat, Lon, T). The grid is 1x1 degree. One of the many points may be Lat=20, Lon=20, T=10.

The question is: When ncl draws a map of T, what does the Lat=20, Lon=20 represents? The center of the 1x1 degree grid-box? Or maybe a corner? For example, if Lat=20, Lon=20 is the southwest corner of the 1x1 grid-box, then the center of the grid-box is at Lat=20.5, Lon=20.5.



Kind regards


Athanasios F. Karagiannidis
Physicist, PhD Meteorology and Climatology
E-mail: thankar at live.com<mailto:thankar at live.com>

_______________________________________________
ncl-talk mailing list
ncl-talk at ucar.edu<mailto:ncl-talk at ucar.edu>
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20171223/524298d8/attachment.html>


More information about the ncl-talk mailing list