[ncl-talk] Trying to understand code in NCL example documentation...

Adam Phillips asphilli at ucar.edu
Thu Apr 25 10:36:11 MDT 2019


Hi Srishti,
That snippet of code is assigning coordinate variables (hgt and xcoord) to
each dimension of the depol array. See page 11 of the NCL User's Guide here:
http://www.ncl.ucar.edu/Document/Manuals/NCL_User_Guide/NCL_User_Guide_v1.1_Legal.pdf
Adam

On Thu, Apr 25, 2019 at 10:30 AM Srishti Dasarathy <srdasara at ucsd.edu>
wrote:

> Dear NCL-talk community,
>
> I have a bit of an unusual question. I'm currently in the midst of
> transferring my code over to MATLAB for various reasons, but I'm having
> trouble understanding the syntax of certain sections pasted here
> <https://www.ncl.ucar.edu/Applications/calipso.shtml> under
> calipso_3.ncl. I was wondering if you can help me understand what is going
> on.
>
> I am trying to produce a similar imagine in MATLAB, but do not understand
> these lines completely even after looking at the documentation.
>
> The lines I'm struggling to understand are below:
>
> ;----------------------------------------------
> ;  ASSIGN NEW DIMENSIONS AND ATTRIBUTES TO COORDINATE CALIPSO DATA WITH  ;  ALTITUDE
> ;----------------------------------------------
>    depol!0   = "hgt"
>    depol&hgt =  hgt
>    xcoord    = ispan(0,dimsizes(lat(:,0)) - 1,1)
>    depol!1   = "xcoord"
>    depol&xcoord = xcoord
>
>
> I understand that hgt is the array of altitude values, but I do not
> understand how depolorization is getting associated with either hgt or
> xcoord.
>
> If anyone has any guidance on understanding this code example so that I
> can logically transfer the syntax to MATLAB, I'd really appreciate it!
>
> Thank you,
> Srishti Dasarathy
>
> --
> Srishti Dasarathy
> Graduate Student
> Integrative Oceanography Division
> Scripps Institution of Oceanography
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>


-- 
Adam Phillips
Associate Scientist,  Climate and Global Dynamics Laboratory, NCAR
www.cgd.ucar.edu/staff/asphilli/   303-497-1726

<http://www.cgd.ucar.edu/staff/asphilli>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190425/8107c2cc/attachment.html>


More information about the ncl-talk mailing list