[gradsusr] More on hurricane track forecast graphics

Jennifer M Adams jadams21 at gmu.edu
Mon Sep 18 08:55:05 EDT 2017


Many have asked me for the code to draw cyclone tracks. My scripts to draw these plots are still under development and are being hardened with every forecast cycle. I will share when they are ready. The core of the algorithm is below, starting with a ulon/ulat that are close to the center of a local minimum in sea level pressure:

'set lon 'ulon
'set lat 'ulat
dimexpr='lon='ulon-radius',lon='ulon+radius',lat='ulat-radius',lat='ulat+radius
* get the grid coordinates
'd aminlocx(mslp.1,'dimexpr')' ; minlocx=subwrd(result,4)
'd aminlocy(mslp.1,'dimexpr')' ; minlocy=subwrd(result,4)

* Convert the grid coordinates to lat/lon, save in a script variable
'set x 'minlocx ; minlon.e.t=subwrd(result,4)
'set y 'minlocy ; minlat.e.t=subwrd(result,4)

The above code is in a loop, so that each minlon/minlat becomes the starting point (ulon/ulat) for the next time step/ensemble. After I have all the slp minimum location data for each ensemble member and time step, then I draw the lines. Start with an empty lat/lon map to set up the scaling, then use ‘q w2xy’ to get the page coordinates for each point and save them in another script variable. Connect the points with ‘draw line’:

*   get the page coordinates
'q w2xy 'minlon.e.t' 'minlat.e.t
minx.e.t=subwrd(result,3)
miny.e.t=subwrd(result,6)
*   draw the line
tm1=t-1
'draw line 'minx.e.tm1' 'miny.e.tm1' 'minx.e.t' ‘miny.e.t

Bells and whistles include the background map, line styles and colors, mark types and sizes, watches and warnings and position data from NHC, annotation, and the wind masks, which are defined using the following expressions:

'spd39=sum(sum(const(const(maskout(mph.2,mph.2-39),1),0,-u),t=1,t='tfinal'),e=2,e='efinal')'
'spd58=sum(sum(const(const(maskout(mph.2,mph.2-58),1),0,-u),t=1,t='tfinal'),e=2,e='efinal')'
'spd74=sum(sum(const(const(maskout(mph.2,mph.2-74),1),0,-u),t=1,t='tfinal'),e=2,e='efinal')'

That ought to be enough to get you started drawing your own cyclone tracks.

In the meanwhile, here is my latest, with Jose and Maria:

[cid:2AFE93CD-A2FC-4E13-A95C-E655390F8E75 at mesa.gmu.edu]


On Sep 7, 2017, at 3:40 PM, Frank Colby <Frank_Colby at uml.edu<mailto:Frank_Colby at uml.edu>> wrote:

Jennifer,

Beautiful map!  Would you share the script?

Thanks,
Frank Colby
UMass Lowell

_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
http://gradsusr.org/mailman/listinfo/gradsusr

--
Jennifer Miletta Adams
Center for Ocean-Land-Atmosphere Studies (COLA)
George Mason University



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20170918/98a8dfc4/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: JoseMaria_2017091800_6.png
Type: image/png
Size: 258495 bytes
Desc: JoseMaria_2017091800_6.png
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20170918/98a8dfc4/attachment-0001.png 


More information about the gradsusr mailing list