[ncl-talk] Problem with linint2_Wrap

Ipsita Putatunda ipsita.putatunda at gmail.com
Mon Aug 6 11:52:40 MDT 2018


Hi Toni,
 If you look in my script, in line 20 I have already lonFlip the data
longitude. lonFlip is a function which flips the longitude from -180/+180
to 0/360 or vice versa. So though my initial data lon is in -180/+180
format, I have changed it to 0/360 via lonFlip and there after creating the
variable for regridding.
a1=fspan(0.,359.75,1441)
Thanks,
Ipsita

On Mon, Aug 6, 2018 at 11:06 PM, Toni Klemm <toni-klemm at tamu.edu> wrote:

> Ipsita,
>
> It looks indeed like your longitudes are shifted. In your script you
> created an array that spans 0 to 359
>
> a1=fspan(0.,359.75,1441)
>
> but the metadata of your file lists as the longitudes of your data ranging
> from -180 to 179.375 degrees.
>
> :WesternmostLongitude = "-180.0" ;
> :EasternmostLongitude = "179.375" ;
>
>
> I’m not familiar with the function lining_Wrap, but try setting up the
> array a1 so it ranges from -180 to +179.375 and see what happens.
>
> a1=fspan(-180,179.375,1441)
>
>
> Also, at first I wondered why the plot only covers the region around
> the equator (30 S to 30 N). But from your script I assume you only want to
> plot that region.
>
> b1=fspan(-30.,30.,241)
>
> If not, that try changing the fspan from -90 to 90 and the steps from 241
> to 723 (3x 241).
>
>
> Toni
>
>
>
> *Toni Klemm, Ph.D.*Postdoctoral Research Associate
> Department of Ecosystem Science and Management
> College of Agriculture and Life Sciences
> Texas A&M University, College Station, TX
> Contributor at the Early Career Climate Forum <http://www.eccforum.org>
> www.toni-klemm.de | @toniklemm <http://twitter.com/toniklemm>
>
>
>
>
>
>
>
> On Aug 6, 2018, at 12:20 PM, Ipsita Putatunda <ipsita.putatunda at gmail.com>
> wrote:
>
> Hi Toni,
>  Please find the attachment.
>
> Thanks,
> Ipsita
>
> On Mon, Aug 6, 2018 at 10:43 PM, Toni Klemm <toni-klemm at tamu.edu> wrote:
>
>> Ipsita,
>>
>> Could you run the command
>>
>> ncdump -h MERRA2_400.inst3_3d_asm_Np.20170101.SUB.nc
>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__MERRA2-5F400.inst3-5F3d-5Fasm-5FNp.20170101.SUB.nc&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=SLg59Bo2un5Gc1gbYkbJx-YvAwqss_Dek2CXQ2STNHE&s=dxd4uHhDSIhFa7kqqt2VPyDxzvaTTJHrtiFXR-JfcmQ&e=>
>>
>> and share the result of that? It should give you a summary of the header
>> of your netCDF file, i.e. the metadata of the file and each variable, like
>> latitude and longitude range, units, etc.
>>
>> Toni
>>
>>
>>
>> *Toni Klemm, Ph.D.*Postdoctoral Research Associate
>> Department of Ecosystem Science and Management
>> College of Agriculture and Life Sciences
>> Texas A&M University, College Station, TX
>> Contributor at the Early Career Climate Forum
>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.eccforum.org&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=SLg59Bo2un5Gc1gbYkbJx-YvAwqss_Dek2CXQ2STNHE&s=484HpwSun6C0ZiMj1-0Kg5OgKfF5MPH9TD5mFbp-Neg&e=>
>> www.toni-klemm.de
>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.toni-2Dklemm.de&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=SLg59Bo2un5Gc1gbYkbJx-YvAwqss_Dek2CXQ2STNHE&s=HkRbQg4yW_BcdF8HHwfqByYj8e4_s3t6-apgDERmspQ&e=>
>>  | @toniklemm
>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__twitter.com_toniklemm&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=SLg59Bo2un5Gc1gbYkbJx-YvAwqss_Dek2CXQ2STNHE&s=Lz6FlJH03nFr_L2Yqb2bVwWMICIpwxF41tbkRjASn5Y&e=>
>>
>>
>>
>>
>>
>>
>>
>> On Aug 6, 2018, at 12:05 PM, Ipsita Putatunda <ipsita.putatunda at gmail.com>
>> wrote:
>>
>> Hi all,
>> Attaching my script herewith, though can't send the data file through
>> email(already sent in ftp) due to its huge volume.
>>
>> Thanks,
>> Ipsita
>>
>> On Mon, Aug 6, 2018 at 10:33 PM, Ipsita Putatunda <
>> ipsita.putatunda at gmail.com> wrote:
>>
>>> Hi Toni,
>>> I have already sent my data and script through ftp, as the data file is
>>> big I can't attach it in mail.
>>> I first lonFlip my data from -180 to +180 to 0 to 360, till that point
>>> the plot was coming fine.
>>> After that I tried to regrid from 0.5 * 0.625 to 0.25*0.25, which is
>>> giving this plot.
>>> The point you mentioned for shifting 180 degree, I have noticed that
>>> also, but somehow not able to fix it.
>>>
>>> Thanks,
>>> Ipsita
>>>
>>>
>>> On Mon, Aug 6, 2018 at 10:25 PM, Toni Klemm <toni-klemm at tamu.edu> wrote:
>>>
>>>> Ipsita,
>>>>
>>>> Would you mind sharing your NCL script and the metadata of your
>>>> variables, i.e. an ncdump -h of your data files, with the listserv? I’m not
>>>> sure many on the listserv have access to your data files and your script on
>>>> the ftp server.
>>>>
>>>> From which to which resolution did you regrid? Maybe check if your
>>>> latitude range before and after the regrinding is the same, for example
>>>> from 0 to 359 degrees or from -180 to +179 degrees? Judging from your plot
>>>> (the position of Africa, for example) there might be a 180 degree shift
>>>> between your data and your map overlay.
>>>>
>>>> Toni
>>>>
>>>>
>>>>
>>>> *Toni Klemm, Ph.D.*Postdoctoral Research Associate
>>>> Department of Ecosystem Science and Management
>>>> College of Agriculture and Life Sciences
>>>> Texas A&M University, College Station, TX
>>>> Contributor at the Early Career Climate Forum
>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.eccforum.org&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=XVNuJ4lF58XrFDJa3KuL2JhhOUYC9qhu5P0f2FbS4jg&s=pwUb1iORHQjLkcIoGsCduDCmKc1xCPHjvAGzpZk2S1E&e=>
>>>> www.toni-klemm.de
>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.toni-2Dklemm.de&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=XVNuJ4lF58XrFDJa3KuL2JhhOUYC9qhu5P0f2FbS4jg&s=AyO6EOxiMiJtuJjCG8E6gJxcyuY_DhvETISLN3Ik-Ns&e=>
>>>>  | @toniklemm
>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__twitter.com_toniklemm&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=XVNuJ4lF58XrFDJa3KuL2JhhOUYC9qhu5P0f2FbS4jg&s=fCKqNGjGZ_eVYsnTBfGzcaC9dMplBdDod9UH7gzlW9Y&e=>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> On Aug 6, 2018, at 11:45 AM, Ipsita Putatunda <
>>>> ipsita.putatunda at gmail.com> wrote:
>>>>
>>>> Hi Barry,
>>>>
>>>> There is actually no particular reason for not using other regridding
>>>> options. As I  have used this method several times in my previous scripts
>>>> and am much familiar with this method, and also  feel it is quicker process
>>>> compare to other options, that is why I have chosen it. You are always
>>>> welcome to suggest something different as well.
>>>>
>>>> Thanks,
>>>> Ipsita
>>>>
>>>> On Mon, Aug 6, 2018 at 10:04 PM, Barry Lynn <barry.h.lynn at gmail.com>
>>>> wrote:
>>>>
>>>>> Hi:
>>>>>
>>>>> Is there  a particular reason you don't use
>>>>>
>>>>> https://www.ncl.ucar.edu/Applications/regrid.shtml
>>>>> <https://urldefense.proofpoint.com/v2/url?u=https-3A__www.ncl.ucar.edu_Applications_regrid.shtml&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=z_8XH5Nfko--z8kQcoLyR7TgUbSIqNJios95j_gBDhU&s=Rhqzff0XfY92jYqWoyOdJvMWFgdzGZP1L5Ngpclzknc&e=>
>>>>>  ?
>>>>>
>>>>> On Mon, Aug 6, 2018 at 7:20 PM Ipsita Putatunda <
>>>>> ipsita.putatunda at gmail.com> wrote:
>>>>>
>>>>>> Dear all,
>>>>>> I am not able to plot correctly after I regrid my data, using
>>>>>> linint2_Wrap. I am attaching the plot herewith what I am getting.
>>>>>>  I have already sent my data file and script via ftp. Any help in
>>>>>> this issue will be appreciated.
>>>>>>
>>>>>> Thanks in advance,
>>>>>> Ipsita
>>>>>> _______________________________________________
>>>>>> ncl-talk mailing list
>>>>>> ncl-talk at ucar.edu
>>>>>> List instructions, subscriber options, unsubscribe:
>>>>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__mailman.ucar.edu_mailman_listinfo_ncl-2Dtalk&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=z_8XH5Nfko--z8kQcoLyR7TgUbSIqNJios95j_gBDhU&s=0-9HbNHh-gfdMU8beZJdMGrGf7Mo8tSSWdBpUaEjMGo&e=>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Barry H. Lynn, Ph.D
>>>>> Senior Associate Scientist, Lecturer,
>>>>> The Institute of the Earth Science,
>>>>> The Hebrew University of Jerusalem,
>>>>> Givat Ram, Jerusalem 91904, Israel
>>>>> Tel: 972 547 231 170
>>>>> Fax: (972)-25662581
>>>>>
>>>>> C.E.O, Weather It Is, LTD
>>>>> Weather and Climate Focus
>>>>> http://weather-it-is.com
>>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__weather-2Dit-2Dis.com&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=z_8XH5Nfko--z8kQcoLyR7TgUbSIqNJios95j_gBDhU&s=7H-awogmLMDx41uEHgNM5reEnkQstsgQ6tdGZAekd88&e=>
>>>>> Jerusalem, Israel
>>>>> Local: 02 930 9525
>>>>> Cell: 054 7 231 170
>>>>> Int-IS: x972 2 930 9525
>>>>>
>>>>>
>>>> _______________________________________________
>>>> ncl-talk mailing list
>>>> ncl-talk at ucar.edu
>>>> List instructions, subscriber options, unsubscribe:
>>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__mailman.ucar.edu_mailman_listinfo_ncl-2Dtalk&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=XVNuJ4lF58XrFDJa3KuL2JhhOUYC9qhu5P0f2FbS4jg&s=S9k6flfF-_MuGpqVi3aMoYm1p6ZxWbqEFW99Mqmy_pM&e=>
>>>>
>>>>
>>>>
>>>
>> <merra1.ncl>_______________________________________________
>> ncl-talk mailing list
>> ncl-talk at ucar.edu
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>> <https://urldefense.proofpoint.com/v2/url?u=http-3A__mailman.ucar.edu_mailman_listinfo_ncl-2Dtalk&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=SLg59Bo2un5Gc1gbYkbJx-YvAwqss_Dek2CXQ2STNHE&s=nNYd_0WKTngaTKj5RQIssYSpNFpOuKsISGVrzxYuUfk&e=>
>>
>>
>>
> <ncdump1.txt>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20180806/d33df4fa/attachment.html>


More information about the ncl-talk mailing list