Map overlay on plot

From: zilore mumba <zmumba_at_nyahnyahspammersnyahnyah>
Date: Tue Dec 27 2011 - 07:45:48 MST

I firstly request to be excused for my my very basic question as a newbie to ncl. I am trying to use ncl to plot WRF output. I have used some sample scripts on the WRFOnLineTutorial. wrf_ter4.ncl plots the terrain height without a map overlat and appears to plot the terrain height correctly. wrf_ter5.ncl on the other hand has height only up to 1000m and the wrong way round and does not overlay the map. Assistance will be appreciated. Once more my excuses for so many attachments. Zilore ________________________________ From: "ncl-talk-request_at_ucar.edu" <ncl-talk-request_at_ucar.edu> To: ncl-talk_at_ucar.edu Sent: Friday, December 23, 2011 9:00 PM Subject: ncl-talk Digest, Vol 97, Issue 31 Send ncl-talk mailing list submissions to     ncl-talk_at_ucar.edu To subscribe or unsubscribe via the World Wide Web, visit     http://mailman.ucar.edu/mailman/listinfo/ncl-talk or, via email, send a message with subject or body 'help' to     ncl-talk-request_at_ucar.edu You can reach the person managing the list at     ncl-talk-owner_at_ucar.edu When replying, please edit your Subject line so it is more specific than "Re: Contents of ncl-talk digest..." Today's Topics:   1. wrapit and cygwin updates? (Joseph Jakuta)   2. Re: Use our own setting for Ythicklabel for Hovmoller    diagram       (juki juki) ---------------------------------------------------------------------- Message: 1 Date: Thu, 22 Dec 2011 15:13:42 -0500 From: "Joseph Jakuta" <JJakuta_at_otcair.org> Subject: wrapit and cygwin updates? To: <ncl-talk_at_ucar.edu> Message-ID: <952BF75B8CC0DE438C50F2C266C08EBC463C21_at_fs.OTCair.local> Content-Type: text/plain; charset="us-ascii" I was reading through the back entries of the group and saw that in 2005 there were plans to update WRAPIT for cygwin.  I was wondering if that ever happened?  If it has not, I was wondering if anyone found other solutions to getting fortran functions to run in NCL if you are using cygwin since you can't simply open a shared object file? Thanks, Joseph Jakuta Environmental Associate OTC / MANE-VU 202.508.3839 444 North Capitol Street NW #638 Washington, DC 20001 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20111222/7bbac344/attachment.html ------------------------------ Message: 2 Date: Thu, 22 Dec 2011 17:42:12 -0800 (PST) From: juki juki <juky_emc2_at_yahoo.com> Subject: Re: Use our own setting for Ythicklabel for     Hovmoller    diagram To: Mary Haley <haley_at_ucar.edu> Cc: "ncl-talk_at_ucar.edu" <ncl-talk_at_ucar.edu> Message-ID:     <1324604532.62982.YahooMailNeo_at_web120303.mail.ne1.yahoo.com> Content-Type: text/plain; charset="iso-8859-1" Thanks Mary, it works... Have a nice weekend...:) Juky ________________________________ From: Mary Haley <haley_at_ucar.edu> To: juki juki <juky_emc2_at_yahoo.com> Cc: "ncl-talk_at_ucar.edu" <ncl-talk_at_ucar.edu> Sent: Friday, December 23, 2011 2:47 AM Subject: Re: Use our own setting for Ythicklabel for Hovmoller diagram Juky, I misread your email before. I thought you were doing a height, but you have a time v.s. longitude plot. I think you simply need to use tmYLValues and tmYLLabels: ? res_at_tmYLMode = "Explicit" ? res_at_tmYLValues = ispan(0,48,8) ? res_at_tmYLLabels = (/"00","08","16","24","8","16","24"/) If this still doesn't work, it would help if I could see your full script and data. --Mary On Dec 22, 2011, at 2:29 AM, juki juki wrote: Hi Mary ! > > >Thanks for nice reply.. > > >>You have a typo in your code. These resources should be "tmYRValues" and "tmYRLabels". The "YR" stands for "Right Y axis". > > >>However, this still probably won't work. > >Yes it does not work..:) > >>Your Y axis values are probably in values of pressure, not height, so when you? >>provide the list of values for tmYRValues, these need to be pressure values, not height values. ? I don't understand >>why ?you have the same height value multiple times ("00","08","16","24","8","16","24"), but you will need to map your height values >into corresponding > >This plot is daily-meridionally-averaged data. Therefore, I have 24 hours data (24 rows) for each longitude (401 coulumn). But to clarify some diurnal characteritics the diurnal cycle is repeated so that the? data become 24 x 2 (48 rows) with the same longitude (401 coulumn). Thus, I have the same value multiple times. I read this data from Ascii file, and I add the time and longitude as: > >? lon?????? =? fspan( 80,160, ncols) >?? lon!0???? = "lon" >?? lon_at_units = "degrees_east" > > >?? time?????? =? fspan(1, 48, nrows) >?? time!0???? = "time" >?? time_at_units = "UTC" > >?? data!0??? = "time" >?? data!1??? = "lon" >?? data&time? =? time >?? data&lon? =? lon > >But I need to set the Ythick lable, if not, the Ythick will be like "0, 8, 16, 24, 32, 40, 48" or others, and they do not reflect the time because time must be repeated ("0, 8, 16, 24, 8, 16, 24")..I hope you understand what I mean, please see my rough-plot result to make clear it.. > >thanks again for best help.. > >Regards, >Juky > > > > > > > >________________________________ > From: Mary Haley <haley_at_ucar.edu> >To: juki juki <juky_emc2_at_yahoo.com> >Sent: Wednesday, December 21, 2011 9:58 PM >Subject: Re: Use our own setting for Ythicklabel for Hovmoller diagram > > >Dear Juky, > > >You have a typo in your code. These resources should be "tmYRValues" and "tmYRLabels". The "YR" stands for "Right Y axis". > > >However, this still probably won't work. Your Y axis values are probably in values of pressure, not height, so when you? >provide the list of values for tmYRValues, these need to be pressure values, not height values. ? I don't understand >why ?you have the same height value multiple times ("00","08","16","24","8","16","24"), but you will need to map your height values into corresponding >pressure values > > >The way the code for this works internally is that a set of height values are calculated based on pressure values: > > >? ? hgt ? ?= gsn_geop_hgt(ptmp) ? ? ; Calculate heights as a function of pressure ? ? ? ? > > >And then these height values, which are floating point numbers, are turned into "nice" height values via: > > >? ? hrange = fabs(hgt(0)-hgt(dimsizes(hgt)-1)) > > >;---Figure out a "nice" spacing to use for the tickmarks >? ? if(hrange.le.35) then >? ? ? step = 4 >? ? else >? ? ? if(hrange.le.70) then >? ? ? ? step = 7 >? ? ? else >? ? ? ? step = 10 >? ? ? end if >? ? end if > > >? ? step = tointeger(step) >? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ; Set range of "nice" hgt values. ? ? ? ?? >? ? hnice = tofloat(ispan(tointeger(floor(hgt(0))), tointeger(ceil(hgt(dimsizes(hgt)-1))),step)) >? ? pnice = ftcurv(hgt,ptmp,hnice) ?; Get pres vals at nice hgt vals. ? ? ? ? ? ? ? ?? > > >Finally, you can use the hnice and pnice values with the tmYRLabels and tmYRValues resources: > > >? ? res_at_tmYRMode ? = "Explicit" >?? ?res_at_tmYRLabels =?hnice >? ? res_at_tmYRValues = pnice > > >You will need to figure out what pressure values match with the height values you want, and use them in place of "pnice" above. > > >--Mary > > >On Dec 21, 2011, at 2:01 AM, juki juki wrote: > >Hi all, >> >> >>I am plotting a daily longitude-hovmoller diagram, 24 hours, to clarify the result the data were plotted twice. I want to set the Ythicklable (time) as follow: >> >> >>?res_at_trYReverse = True??? >>? >>?res_at_tmYBValues = (/0,8,16,24,32,40,48/) >>?res_at_tmYBLabels = (/"00","08","16","24","8","16","24"/) >> >> >>Time is generated as: >> >> >>?? time?????? =? fspan(1, 48, nrows); nrows = 48 >>?? time!0???? = "time" >>?? time_at_units = "UTC" >> >>?? data!0??? = "time"; data contain hourly data which are written twice. >>?? data!1??? = "lon" >>?? data&time? =? time >>?? data&lon? =? lon >> >> >>Problem, some errors said that the above comment (res_at_tmYBValues ...) can not be used for hovmoller case. Are there any suggestion to deal with this kind of problem ? >> >> >>Thanks again for help... >> >> >>Regards, >>JuKy_______________________________________________ >>ncl-talk mailing list >>List instructions, subscriber options, unsubscribe: >>http://mailman.ucar.edu/mailman/listinfo/ncl-talk >> > > ><hov.000001.png>_______________________________________________ >ncl-talk mailing list >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/20111222/2f4b2276/attachment.html ------------------------------ _______________________________________________ ncl-talk mailing list ncl-talk_at_ucar.edu http://mailman.ucar.edu/mailman/listinfo/ncl-talk End of ncl-talk Digest, Vol 97, Issue 31 ****************************************

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk

Received on Tue Dec 27 07:46:16 2011

This archive was generated by hypermail 2.1.8 : Wed Jan 04 2012 - 10:18:09 MST