[ncl-talk] same data but different spatial pattern

Md. Jalal Uddin dmjalal90 at gmail.com
Wed Feb 13 01:14:06 MST 2019


My data is hourly. I want to plot hourly data without dimension average.
Could you tell me where I need to change from my loop? I want to take whole
time 2444.

f = addfile("bob_dd.nc","r")
do i =0,2443
  TRMM = f->pcp(i,{0:30},{65:110})
 end do

Best Regards,
Jalal

On Wed, Feb 13, 2019 at 12:46 PM Toni Klemm <toni-klemm at tamu.edu> wrote:

> Hi Jamal,
>
> It looks like your do loop in your first attempt does not average. You’re
> simply replacing the first dimension in TRMM with the next dataset every
> time you repeat the loop. That’s why your first and second plot look so
> different.
>
> In your second attempt you're copying the entire first dimension and then
> average, that’s why it looks different. If you mean to do that (average the
> first dimension), your second attempt seems fine.
>
> I hope that makes sense.
>
> 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 to the Early Career Climate Forum <http://www.eccforum.org>
> www.toni-klemm.de | @toniklemm <http://twitter.com/toniklemm>
>
>
>
>
>
>
>
>
> On Feb 12, 2019, at 2:20 PM, Md. Jalal Uddin <dmjalal90 at gmail.com> wrote:
>
>  Hi all,
> When I did loop over time, I got a spatial figure that I did not expect
> (dd_loop figure).
> f = addfile("bob_dd.nc
> <https://urldefense.proofpoint.com/v2/url?u=http-3A__bob-5Fdd.nc&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=00Y6K5t3WswGmNOO6WFFhxReMcZp10_pqq3Gh_aSm1c&s=1UQT6wjQp2nsSrxV7rcEPkMkD2C2aMAPttXb-3HRnnw&e=>
> ","r")
> do i =0,2443
>   TRMM = f->pcp(i,{0:30},{65:110})
>  end do
>
> I got the right spatial pattern when I did dimension average (dd_avg
> figure).
> f = addfile("bob_dd.nc
> <https://urldefense.proofpoint.com/v2/url?u=http-3A__bob-5Fdd.nc&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=00Y6K5t3WswGmNOO6WFFhxReMcZp10_pqq3Gh_aSm1c&s=1UQT6wjQp2nsSrxV7rcEPkMkD2C2aMAPttXb-3HRnnw&e=>
> ","r")
> TRMM = f->pcp(:,{0:30},{65:110})
>  dd_ave = dim_avg_n_Wrap(TRMM,0)
>
> How can I get similar spatial pattern? What is the difference between time
> loop and dimension average? Could you explain, please?
>
> Jalal
> --
> *Md. Jalal Uddin*
> MSc in Applied Meteorology (English Language)
> Nanjing University of Information, Science and Technology, China
> B.Sc. in Disaster Management (Hons.)
> Patuakhali Science and Technology University, Bangladesh.
> Cell: +8613260859092, +8801792052662
> Web: www.dmjalal90.weebly.com
> <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.dmjalal90.weebly.com&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=00Y6K5t3WswGmNOO6WFFhxReMcZp10_pqq3Gh_aSm1c&s=84I3BnXlOpSL3H8dxEaHylU9iBYalkvo1MlMON5vUsQ&e=>
>
> Facebook: jalal.hossen.39
> LinkedIn: https://bd.linkedin.com/in/md-jalal-uddin-80a026b0
> <https://urldefense.proofpoint.com/v2/url?u=https-3A__bd.linkedin.com_in_md-2Djalal-2Duddin-2D80a026b0&d=DwMFaQ&c=ODFT-G5SujMiGrKuoJJjVg&r=WsLJ5ywbW3XnTzqo_ETV62H6s1a5bcGgnrpl7xPRfic&m=00Y6K5t3WswGmNOO6WFFhxReMcZp10_pqq3Gh_aSm1c&s=6UgI5FMI3Ol23LyLDegxH5Kymdnzb6kdbxyqtVgYRbY&e=>
>
> Twitter: dmjalal90
> Skype: dmjalal90
> <dd_loop.png><dd_avg.png>_______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
>

-- 
*Md. Jalal Uddin*
MSc in Applied Meteorology (English Language)
Nanjing University of Information, Science and Technology, China
B.Sc. in Disaster Management (Hons.)
Patuakhali Science and Technology University, Bangladesh.
Cell: +8613260859092, +8801792052662
Web: www.dmjalal90.weebly.com
Facebook: jalal.hossen.39
LinkedIn: https://bd.linkedin.com/in/md-jalal-uddin-80a026b0
Twitter: dmjalal90
Skype: dmjalal90
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190213/d359e774/attachment.html>


More information about the ncl-talk mailing list