<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); ">
<div>
<div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; ">Kyle -</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; ">I have successfully read in these files in both MATLAB and Python. I have given a snippet below of the Python code, so you can adapt it to make your .ctl file. You will need the lon and lat binary
files (25x25 km) to go with it (did you grab those?) as well as possibly the grid area if you are doing areal coverage calculations. The data are on an irregular grid. I can send those files to you in a separate e-mail (or you can get them off of the ftp site).</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; ">- Jason</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "> </div>
<div><span class="Apple-style-span" style="font-size: 14px; font-family: Calibri, sans-serif; "> </span><span class="Apple-style-span" style="font-size: 12px; "><font class="Apple-style-span" face="Consolas">import numpy as np</font></span></div>
<div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> # Get the latitude, longitude, and grid_area files.</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> COLS=304; ROWS=448 #Number of columns and rows for the data matrices.</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> </font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lonfile = open('psn25lons_v3.dat','rb')</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> latfile = open('psn25lats_v3.dat','rb')</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> areafile = open('psn25area_v3.dat','rb')</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> </font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lons = np.fromfile(lonfile,dtype='int32'); lons[lons<=0]=lons[lons<=0]+360</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lats = np.fromfile(latfile,dtype='int32')</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> area = np.fromfile(areafile,dtype='int32')</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> </font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> # Numpy reads in the data into a 1-D array. Reshape into 2-D arrays.</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lons = lons.reshape((COLS,ROWS),order='F').astype('float')/1e5</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lats = lats.reshape((COLS,ROWS),order='F').astype('float')/1e5</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> area = area.reshape((COLS,ROWS),order='F').astype('float')/1e9</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> </font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> lonfile.close()</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> latfile.close()</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> areafile.close()</font></div>
</div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"><br>
</font></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;"> # Sample read-in for one daily file.</font></div>
<div><span class="Apple-style-span" style="font-family: Courier; font-size: 12px; "> icefile = open(</span><span class="Apple-style-span" style="font-family: Courier; font-size: 12px; ">'nt_20070916_f13_v01_n.bin'</span><span class="Apple-style-span" style="font-family: Courier; font-size: 12px; ">,'rb')</span></div>
<div><font class="Apple-style-span" face="Courier" style="font-size: 12px;">
<div><br>
</div>
<div> hdr1 = icefile.read(300)</div>
<div> c = np.fromfile(icefile,dtype='uint8')</div>
<div> </div>
</font><span class="Apple-style-span" style="font-family: Courier; font-size: 12px; "> # Numpy reads in the data into a 1-D array. Reshape into 2-D arrays.</span><font class="Apple-style-span" face="Courier" style="font-size: 12px;">
<div> </div>
</font><font class="Apple-style-span" face="Courier" style="font-size: 12px;">
<div> c = c.reshape((COLS,ROWS),order='F').astype('float')</div>
<div> icefile.close()</div>
<div><br>
</div>
<div> # Values 0-250 represent fractional ice coverage scaled by 250.</div>
<div> # 251: hole around pole due to orbital inclination</div>
<div> # 253: coastlines </div>
<div> # 254: land mask </div>
<div> # 255: missing data </div>
<div><span class="Apple-tab-span" style="white-space:pre"></span></div>
<div> c[c==251]=250; # treat hole as 100% concentration</div>
<div> c[(c==253) | (c==254) | (c==255)]=np.nan; # treat coast, land, or missing as NaN</div>
<div><span class="Apple-tab-span" style="white-space:pre"></span></div>
<div> c = c/250. # ice concentration (0 to 1)</div>
<div><br>
</div>
</font></div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; ">
<div>
<div>-- </div>
<div>
<div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">Jason C. Furtado, Ph.D.</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">Staff Scientist</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">Atmospheric and Environmental Research (AER), a Verisk Analytics company</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">131 Hartwell Ave.</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">Lexington, MA 02421</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; "><br>
</span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">E-mail: <a href="mailto:jfurtado@aer.com">jfurtado@aer.com</a></span></font></div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; ">Phone: 781-761-2384</span></font></div>
</div>
</div>
<div><font class="Apple-style-span" face="Arial"><span class="Apple-style-span" style="font-size: 12px; "><br>
</span></font></div>
<div><br>
</div>
</div>
</div>
</div>
</div>
<div style="font-size: 14px; font-family: Calibri, sans-serif; "><br>
</div>
<span id="OLK_SRC_BODY_SECTION" style="font-size: 14px; font-family: Calibri, sans-serif; ">
<div style="font-family:Calibri; font-size:11pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<span style="font-weight:bold">From: </span>Kyle Clem <<a href="mailto:Kyle.Clem@vuw.ac.nz">Kyle.Clem@vuw.ac.nz</a>><br>
<span style="font-weight:bold">Reply-To: </span>GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<span style="font-weight:bold">Date: </span>Tuesday, August 26, 2014 9:48 PM<br>
<span style="font-weight:bold">To: </span>"<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>" <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<span style="font-weight:bold">Subject: </span>[gradsusr] a good sea ice data set for GrADS<br>
</div>
<div><br>
</div>
<div dir="ltr"><style type="text/css" id="owaParaStyle"></style>
<div fpstyle="1" ocsi="0">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">Hello,
<div><br>
</div>
<div>I am trying to use sea ice concentration data from <a href="http://nsidc.org/data/docs/daac/nsidc0051_gsfc_seaice.gd.html" target="_blank">http://nsidc.org/data/docs/daac/nsidc0051_gsfc_seaice.gd.html</a>, but am unable to plot it in GrADS because I don't
understand how to find the PDEF Syntax information. Can anyone provide advice on how to obtain the PDEF Syntax information? Or, does anyone have any other sea ice data recommendations for using in GrADS?</div>
<div><br>
</div>
<div>Thanks,</div>
<div>Kyle</div>
<div><br>
<div><br>
<div style="font-family:Tahoma; font-size:13px">
<div style="font-family:Tahoma; font-size:13px">
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-weight:bold; background-color:rgb(255,255,255)">
<span style="font-family: 'Monotype Corsiva'; "><font class="Apple-style-span" color="#000080" size="4">----------------------<br>
</font></span></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-weight:bold; background-color:rgb(255,255,255)">
<span style="font-family: 'Monotype Corsiva'; "><font class="Apple-style-span" color="#000080" size="4">Kyle Clem, M.Sc.</font></span></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:16px; background-color:rgb(255,255,255)">
<font face="Tahoma,Geneva,sans-serif" size="2">PhD Student</font></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:16px; background-color:rgb(255,255,255)">
<font face="Tahoma,Geneva,sans-serif" size="2">School of Geography, Environment and Earth Sciences</font></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:16px; background-color:rgb(255,255,255)">
<font face="Tahoma,Geneva,sans-serif" size="2">Victoria University of Wellington</font></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:16px; background-color:rgb(255,255,255)">
<font face="Tahoma,Geneva,sans-serif" size="2">Cotton Building, Room 222</font></p>
<p class="MsoNormal" style="margin-top:0px; margin-bottom:0px; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:16px; background-color:rgb(255,255,255)">
<font face="Tahoma,Geneva,sans-serif" size="2"><a href="mailto:kyle.clem@vuw.ac.nz">kyle.clem@vuw.ac.nz</a></font></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</span><br>
<hr>
<font face="Arial" color="Gray" size="1"><br>
This email is intended solely for the recipient. It may contain privileged, proprietary or confidential information or material. If you are not the intended recipient, please delete this email and any attachments and notify the sender of the error.<br>
</font>
</body>
</html>