[ncl-talk] region of interest

Dennis Shea shea at ucar.edu
Thu Oct 25 21:25:56 MDT 2018


Your script has:

ncl 13>   lat2d = f->Latitude
ncl 14>
ncl 15>   minlat = -87 ; or some val
ncl 16>   maxlat = 76 ; or some val
ncl 17>   minlev = 0
ncl 18>   maxlev = 100 ;
ncl 19>   ii = *ind*
<https://www.ncl.ucar.edu/Document/Functions/Built-in/ind.shtml>(lat2d.ge.minlat.and.lat2d.le.maxlat.and.ii
= *ind* <https://www.ncl.ucar.edu/Document/Functions/Built-in/ind.shtml>
(lat2d.ge.minlat.and.lat2d.le.maxlat

fatal:And: Number of dimensions do not match, can't continue

 *ind* <https://www.ncl.ucar.edu/Document/Functions/Built-in/ind.shtml>
only works on **one-dimensional arrays**. I assume lat2d is
two-dimensions.

You would have to use *ndtooned*
<https://www.ncl.ucar.edu/Document/Functions/Built-in/ndtooned.shtml> and,
subsequently *ind_resolve*
<https://www.ncl.ucar.edu/Document/Functions/Built-in/ind_resolve.shtml>

Further, line 19 would have to be broken into multiple parts.

lat1d = *ndtooned*(lat2d)
ii1d   = *ind*
<https://www.ncl.ucar.edu/Document/Functions/Built-in/ind.shtml>(lat1d.ge.minlat
.and. lat1d.le.maxlat)
ii       = *ind_resolve*(ii1d, lat2d)
printVarSummary(ii)

Then from this sunset, find the level information.


<https://www.ncl.ucar.edu/Document/Functions/Built-in/ind.shtml>

On Thu, Oct 25, 2018 at 5:43 AM Elham Ghasemifar <
elham.ghasemifar at modares.ac.ir> wrote:

> Dear colleges
>
> hello
>
> i want to use MIRS data for getting cross section, the data has 3
> dimensions but 2 dimensions of them are not latitude and longitude , they
> are scanline and field of view, i introduce latitude separately in the
> script, how i can plot vertical section of the data against latitude ,
>
> i attached the script here ,
>
> i want to plot vertical section of water vapor against latitude,
>
> best regards
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20181025/a6272e2c/attachment.html>


More information about the ncl-talk mailing list