[Thread Prev][Thread Next][Index]

Re: [ferret_users] Plotting data from ASCII file.



Hi Imran,
Are your data on a grid? We can view data in Ferret either as "point" or "in-situ" data, located at scattered points, or it may be on a grid.

When the data is in this form, you can use the polygon command to show the locations of the data and the values of the variable. This is a good way to explore what's in data like this:

yes? file/skip=1/grid=xygrid/var="lon_deg, lon_min, lat_deg, lat_min, pre"

yes? ! convert degrees and minutes to decimal degrees
yes? let longs = long_deg + lon_min/60
yes? let lats = lat_deg + lat_min/60

yes? go basemap x= 0:20 y=30:50 5
yes? go polymark  polygon/over/key/title="Pre" longs, lats, pre, circle, 0.5

This will show the distribution of the data.

 If your data were already  on a grid, you could read the data as in Example 4 under the "reading ASCII data" section in the Users Guide. ( Ch2 Sec5.1.  Reading ASCII files)  Here you would ignore the  longitude and latitude data

It looks as though your data are at specific points which could be a subset of a  grid, but some points in longitude are missing from the list of values at 43 5 latitude. To use the idea in Example 4, for each latitude, there needs to be the same list of longitudes. This is not the case for your data; the longitudes for lat = 43'5" are not the same as the longitudes at lat=43'15"

You can use one of the scat2grid functions, either SCAT2GRIDGAUSS_XY or SCAT2GRIDLAPLACE_XY, to put the data onto a rectangular grid that you define.  You will give the function arguments which are the variables longs, lats, pre as we defined them above, and arguments that define the grid you want to use. The function will put the data onto your grid.

Ansley

IMRAN NADEEM wrote:
Dear ferret Users,

             I am new ferret user. I have data in ASCII format. The three columns in the attached file are longitude,latitude and precipitation.
I know how to read data from ASCII files but I cant plot precipitation on given latitude and longitude. Actually I dont know who to define grid from the given
lat/lon. The first few lines of the data files are attached.Looking forward for some suggestion


Thanks in Advance



Imran Nadeem
PhD Student
Institute of Meteorology
Department of Water, Atmosphere and Environment
Uni. of Natural Resources and Applied Life Sciences (BOKU)

Peter-Jordan Strasse 82
1190 Vienna, Austria

Mobile: +43 699 1194 3044
Tel.: +43 1 47654 5614
Fax: +43 1 47654 5610

[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement