[gradsusr] Trying to plot values (grid? ascii?) of weasdsfc onto map.

Jeff Duda jeffduda319 at gmail.com
Sat Sep 26 11:05:22 EDT 2015


I'm pretty sure the white areas (with no numbers plotted) are being set to
missing because the mask expression is negative there. Plot
weasdsfc-weasdsfc(t-1) alone. I bet you'll see negative numbers there.
Seems reasonable that means snow melted so that there is less snow than
there was the time step before. Is weasdsfc the only snow variable you
have? Memory tells me that the standard GFS data also have a categorical
precip type array as well as a snow ratio estimation, so you can couple
that with apcpsfc to get an estimation of snow precipitation if that's what
you're looking for.

Jeff Duda

On Fri, Sep 25, 2015 at 11:55 PM, Christopher Gilroy <chris.gilroy at gmail.com
> wrote:

> Hey guys, I'm kinda getting there, but I've run into another problem, and
> I have no idea at all what's causing this. But when I use 'd weasdsfc'
> everything is colored. When I do (the "right" way to do 6-hr snow accum?):
> 'd sum(maskout(weasdsfc-weasdsfc(t-1),weasdsfc-weasdsfc(t-1)),t=2,t='%i%')'
> I get the attached image output.
>
> Any guesses? :-/
>
> Note: This is a super-zoomed in area of Alaska, since I was debugging and
> thinking maybe grads was hitting a memory limit or something, but it
> happens regardless and I know it's related to that expression. :-/
>
> http://i.imgur.com/CKAfnIy.png
>
> On Fri, Sep 25, 2015 at 10:56 AM, Jennifer Adams <jma at cola.iges.org>
> wrote:
>
>> Hi, Chris —
>>
>> Here’s how I think the numbers could be drawn in the sample from
>> WeatherBell.
>> 1. You have a particular grid point in mind, with a specific lat/lon
>> 2. Set lat/lon to a range of values and draw the spatially varying
>> graphic with shaded contours to set up the scaling.
>> 3. Use ‘q w2xy’ to get the position of the lat/lon on the page, GrADS
>> will return something like "X = 2.72222  Y = 5.58333”. Parse these with
>> substr() to retain the x,y positions.
>>
>> 4. Fix lat/lon to the desired coordinates, display the variable, which
>> should just print some text to the screen like “Result value = 0.33”
>> 5. Parse that result to extract the value: val=subwrd(result,4)
>> 6. use ‘draw string’ with the x,y positions and the data value to place
>> the number on top of the shaded contours.
>>
>> If the numbers are based on station data, then it’s a different ball of
>> wax.
>> —Jennifer
>>
>>
>>
>>
>>
>> On Sep 25, 2015, at 9:59 AM, Christopher Gilroy <chris.gilroy at gmail.com>
>> wrote:
>>
>> I do want it to draw snowfall amounts, but like in the two images, not
>> "griddy". If you look at,
>> http://blog.chron.com/weather/wp-content/blogs.dir/2579/files/2014/01/gfs_6hr_snow_acc_se_19.png
>> that doesn't appear to be drawing those numbers based on a grid at all.
>> They are all scattered about on the map with no real "grid" structure to
>> them. The only way I know how to "control" the frequency (perhaps
>> "stepping" might be a better word?) of the drawing of values would really
>> be to maskout coupled with re-gridding so it doesn't put a number on every
>> possible area that weasdsfc has a value for is. If that makes sense?
>>
>> On Fri, Sep 25, 2015 at 9:53 AM, Stephen McMillan <
>> smcmillan at planalytics.com> wrote:
>>
>>> Hello Chris,
>>>
>>> If you don't want to display all the grid values, then you can use 'draw
>>> string...' using the coordinates of whatever stations or locations you want
>>> displayed on top of the shaded contours.  See
>>> http://www.iges.org/grads/gadoc/gradcomddrawstring.html
>>>
>>> Stephen McMillan
>>>
>>> On Fri, Sep 25, 2015 at 8:55 AM, Christopher Gilroy <
>>> chris.gilroy at gmail.com> wrote:
>>>
>>>> I'm trying to plot something like this:
>>>> http://i60.tinypic.com/2v9voe0.jpg (WXBell has the same basic setup,
>>>> http://blog.chron.com/weather/wp-content/blogs.dir/2579/files/2014/01/gfs_6hr_snow_acc_se_19.png)
>>>> with the inch's plotting on-top of the shaded area but the only way I know
>>>> how to display "values" like that is with gxout grid, which then makes the
>>>> numbers plot in grids (obviously) and unless I'm missing something with
>>>> options I don't see a way to make it output as "loose" as theirs are,
>>>> instead of literally in a "grid" (square box) format.
>>>>
>>>> I'm currently simply doing:
>>>>
>>>> 'set gxout grid'
>>>> 'set gridln off'
>>>> 'set dignum 1'
>>>> 'set digsiz 0.05'
>>>> 'd re(maskout(weasdsfc, weasdsfc-3), 0.25)'
>>>>
>>>> Which, you can image it will output tons of numbers all over, making it
>>>> completely illegible. Any clue on how to do something like the above two
>>>> images?
>>>>
>>>> --
>>>> -Chris A. Gilroy
>>>>
>>>> _______________________________________________
>>>> gradsusr mailing list
>>>> gradsusr at gradsusr.org
>>>> http://gradsusr.org/mailman/listinfo/gradsusr
>>>>
>>>>
>>>
>>> _______________________________________________
>>> gradsusr mailing list
>>> gradsusr at gradsusr.org
>>> http://gradsusr.org/mailman/listinfo/gradsusr
>>>
>>>
>>
>>
>> --
>> -Chris A. Gilroy
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>>
>> --
>> Jennifer M. Adams
>> Center for Ocean-Land-Atmosphere Studies (COLA)
>> 111 Research Hall, Mail Stop 2B3
>> George Mason University
>> 4400 University Drive
>> Fairfax, VA 22030
>>
>>
>>
>>
>>
>>
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>>
>
>
> --
> -Chris A. Gilroy
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>


-- 
Jeff Duda
Graduate research assistant
University of Oklahoma School of Meteorology
Center for Analysis and Prediction of Storms
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20150926/6ebe44d8/attachment-0001.html 


More information about the gradsusr mailing list