<div dir="ltr">Thanks Dave, that makes it simpler,<div>Mark</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 21, 2019 at 8:01 PM Dave Allured - NOAA Affiliate <<a href="mailto:dave.allured@noaa.gov">dave.allured@noaa.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div>Mark, I should have caught this before.  There are unnecessary elements in your read statement.  A simpler version would be better:</div><div><br>lats = obsfile->$"latitude@MetaData"$</div><div><br></div><div>The whole-array subscript (:) is not needed unless you have a specific reason to trap a latitude variable that has more than one dimension.</div><div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 21, 2019 at 7:40 PM M P <<a href="mailto:mzp3769@gmail.com" target="_blank">mzp3769@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Thanks very much that solved this problem but another one occurred related to scatter-plotting that I will follow-up<div>in a separate thread,</div><div>Mark</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 21, 2019 at 4:37 PM Dave Allured - NOAA Affiliate <<a href="mailto:dave.allured@noaa.gov" target="_blank">dave.allured@noaa.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div>Mark has a netcdf file with an "at sign" embedded in a variable name.  This is quite odd, but it is legal netcdf.</div><div><br></div>This needs special quoting in NCL, because the "at sign" is an active NCL operator.  Special quoting is needed.  This should work:<br><br> lats = ndtooned (obsfile->$"latitude@MetaData"$(:))<br><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 21, 2019 at 4:27 PM Rick Brownrigg via ncl-talk <<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>I for one don't understand this line:</div><div>    <br><div>  float latitude@MetaData(nlocs) ;<br></div><div><br></div><div>Could you perhaps open the file and provide the output from "printVarSummary(obsfile)" ??</div><div><br></div><div>Rick</div><div><br></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 21, 2019 at 4:02 PM M P via ncl-talk <<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hello,<div><br></div><div>I have a file in the following format</div><div>netcdf aod_viirs_obs_2018041500_f {<br>dimensions:<br>        nvars = 1 ;<br>        nlocs = UNLIMITED ; // (27545 currently)<br>variables:<br>         ....<br>        float latitude@MetaData(nlocs) ;<br></div><div><br></div><div>with  latitude@MetaData just being a variable name</div><div><br></div><div>That is falsely being read as an attribute with a code </div><div><br></div><div> obsfile   = addfile("./indata/aod_viirs_obs_2018041500_s.nc4","r")        ; lons, lats, AOD<br> lats  =   ndtooned(obsfile->latitude@MetaData(:))    ; Pull off lat<br><br></div><div>and warning/error </div><div><br></div><div>warning:["NclAdvancedFile.c":5317]:AdvancedFileReadVarAtt: (MetaData) is not an attribute of (latitude)<br><br></div><div>How to correct it so that the variable latitude@MetaData is read properly?</div><div><br></div><div>Thanks,</div><div><br></div><div>Mark</div></div></blockquote></div></blockquote></div></div></div>
</blockquote></div>
</blockquote></div></div></div>
</blockquote></div>