<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Forgot the offset, which is mentioned in the link Kevin sent.&nbsp;<div class=""><br class=""></div><div class=""><br class=""><div class="" style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div class=""><div class=""><div class="">ir_u = byte2flt( fbindirread (file_name_read ,0, (/2,3298,9896/),"ubyte"))<b class=""> +75.</b></div></div></div></div><div class=""><div class="" style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div class=""><div class=""><div class="">ir_u@_FillValue= 255<b class="">+75.</b></div></div></div></div></div><div class=""><br class=""></div><div class="">"<span style="white-space: pre-wrap;" class="">Each record is a 9896 x 3298 Fortran array of IR brightness temperatures that have </span><span style="white-space: pre-wrap;" class="">been scaled to fit into 1-byte by subtracting "75" from each datum.  Therefore it </span><span style="white-space: pre-wrap;" class="">is necessary for the user to add a value of "75" to each data value when using the </span><span style="white-space: pre-wrap;" class="">data."</span></div><br class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 4 Feb 2016, at 13:30, Alan Brammer &lt;<a href="mailto:abrammer@albany.edu" class="">abrammer@albany.edu</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">ok, wow. Don’t send the same message 3 times, if the first answers weren’t complete at least expand and attempt something not just copy paste the same lines again. &nbsp;<div class=""><br class=""></div><div class=""><div class="">as said before .Z means it’s compressed. &nbsp;gunzip&nbsp;merg_2016020123_4km-pixel.Z &nbsp;will uncompress it. Then you have a binary file as a small amount of googling would have told you. &nbsp;</div><div class="">The same search would have linked you to various messages on here and various scripts where other people have included simple examples of this file type (myself included). Here is an example of reading and making a simple plot. &nbsp;There are plenty of examples on how to write netcdf on the NCL website so you should develop code from there. &nbsp;Most simple example at bottom of script below.&nbsp;</div><div class=""><a href="https://www.ncl.ucar.edu/Applications/o-netcdf.shtml" class="">https://www.ncl.ucar.edu/Applications/o-netcdf.shtml</a></div><div class=""><br class=""></div><div class="">Read the documentation on the below functions and understand what is occurring .</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">begin</div><div class=""><div class="">file_name_read = "merg_2016020123_4km-pixel"</div><div class=""><br class=""></div><div class="">ir_u = byte2flt( fbindirread (file_name_read ,0, (/2,3298,9896/),"ubyte"))&nbsp;</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">lon_g = fspan(0.0182,360,9896)</div><div class="">lat_g = fspan(59.982,59.982-0.036383683*3298,3298)</div><div class="">&nbsp;</div><div class="">lon_g@units &nbsp; &nbsp; &nbsp;= "degrees_east"</div><div class="">lon_g@long_name &nbsp;= "longitude"</div><div class="">lon_g@short_name = "longitude"</div><div class="">lon_g!0 = "lon"</div><div class="">lon_g&amp;lon = lon_g</div><div class=""><br class=""></div><div class="">lat_g@units &nbsp; &nbsp; &nbsp;= "degrees_north"</div><div class="">lat_g@long_name &nbsp;= "latitude"</div><div class="">lat_g@short_name = "latitude"</div><div class="">lat_g!0 = "lat"</div><div class="">lat_g&amp;lat = lat_g</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">ir_u!0 &nbsp; &nbsp; &nbsp;= "time"</div><div class="">ir_u!1 &nbsp; &nbsp; &nbsp;= "lat"</div><div class="">ir_u!2 &nbsp; &nbsp; &nbsp;= "lon"</div><div class=""><br class=""></div><div class="">ir_u&amp;lat &nbsp; &nbsp;= lat_g</div><div class="">ir_u&amp;lon &nbsp; &nbsp;= lon_g</div><div class=""><br class=""></div><div class="">ir_u@_FillValue= 255</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">wks = gsn_open_wks("X11","")</div><div class="">res = True</div><div class="">res@cnFillOn = True</div><div class="">res@cnFillMode = "RasterFill"</div><div class="">res@cnLinesOn = False</div><div class="">plot = gsn_csm_contour_map(wks, ir_u(0,:,:), res)</div></div><div class=""><br class=""></div><div class="">ncout = addfile(file_name_read+”.nc”,”c”)</div><div class="">ncout-&gt;ir_data = ir_u</div><div class=""><br class=""></div><div class="">end</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">On 4 Feb 2016, at 13:04, Benjamin Alabi &lt;<a href="mailto:alabibenjamin2@gmail.com" class="">alabibenjamin2@gmail.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class=""><div class=""><div class="">Thanks for your assistance sir. I've tried the cdo to get general information on the data, but it didn't work<br class="">I need help from someone that can guide me to convert this data format - 'merg_2012091000_4km-pixel.Z' to netcdf format.<br class="">I
 download Gobally-merged (60N-60S) pixel-resolution IR brightness 
temperature data (equivalent blackbody temps), merged from all available
 geostationary satellites (GOES-8/10, METEOSAT-7/5)<br class="">This is the link:<br class=""><a href="http://mirador.gsfc.nasa.gov/cgi-bin/mirador/presentNavigation.pl?tree=project&amp;dataset=Global-merged%20IR%20Brightness%20Temperature%20Data&amp;project=TRMM&amp;dataGroup=Ancillary&amp;version=001&amp;CGISESSID=25c6337b80163b3743e8bea85d015558" target="_blank" class="">http://mirador.gsfc.nasa.gov/cgi-bin/mirador/presentNavigation.pl?tree=project&amp;dataset=Global-merged%20IR%20Brightness%20Temperature%20Data&amp;project=TRMM&amp;dataGroup=Ancillary&amp;version=001&amp;CGISESSID=25c6337b80163b3743e8bea85d015558</a>.<br class=""></div>I really want it to be in netcdf format.<br class=""><br class=""></div>Regard<br class=""><br class=""><br class=""></div><br class=""></div>
_______________________________________________<br class="">ncl-talk mailing list<br class=""><a href="mailto:ncl-talk@ucar.edu" class="">ncl-talk@ucar.edu</a><br class="">List instructions, subscriber options, unsubscribe:<br class=""><a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" class="">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br class=""></div></blockquote></div><br class=""></div></div></div></div></blockquote></div><br class=""></div></body></html>