[ncl-talk] Incorrect plot

Rashed Mahmood rashidcomsis at gmail.com
Mon Oct 31 12:44:25 MDT 2022


Hi Mauro,
I think the data file is poorly formatted. There are several issues with
the data, most important ones are:

*1) mismatch of dimensions between variable and the coordinates:*
Lat/Lon: Dimensions and sizes: [*yc | 912]* x [xc | 444]
prec:      Dimensions and sizes: [zt | 48] x [yt | 444] x [*xt | 912*]

This can be solved by dimension reordering (see in the attached script).

*2) The data contains NaNs:*
   GRISO hourly precip rate (mm/h) : min=-nan   max=-nan
 NCL has a special function to deal with these (see also in the attached
script).

Also you can use NCL's special attributes lat2d and lon2d for assigning 2d
coordinates to the variable (see in attached script).

The attached script seems to plot correctly, but make sure that dimension
reordering is correct (that is lat and lon are not swapped incorrectly).

Cheers,
Rashed





On Mon, Oct 31, 2022 at 11:27 AM Mauro Morichetti via ncl-talk <
ncl-talk at mailman.ucar.edu> wrote:

> Hi all,
>
> I have problem to plot the data from the following link:
>
>
> GRISO_Vaia.nc
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
> drive.google.com
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
>
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
>
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
> <https://drive.google.com/file/d/12jGkoDXOn636XJY2WT15W8fnS_Tk90a4/view?usp=sharing>
>
> I have nominated the variables and added the units to the coordinates, but
> the plot is not plot correctly, what I am missing?
>
> The scripts I used is attached, could you help me please?
>
> Thanks
>
> Regards
>
> Mauro
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at mailman.ucar.edu
> List instructions, subscriber options, unsubscribe:
> https://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20221031/18055c94/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: drive_2020q4_32dp.png
Type: image/png
Size: 831 bytes
Desc: not available
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20221031/18055c94/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: GRISO_map.ncl
Type: application/octet-stream
Size: 3950 bytes
Desc: not available
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20221031/18055c94/attachment.obj>


More information about the ncl-talk mailing list