[gradsusr] "constant field = 0" when calculating probabilities

dzengiz.tafa at telenet.be dzengiz.tafa at telenet.be
Wed Aug 10 08:07:03 EDT 2016


Hi everybody 

I am building a script to calculate the probability that the 10m windspeed wil surpass the 20 m/s mark (>= 9 beafort), using the GEFS with all 20 members including the control. 

It looks like this 

'set e 1' 
'define spd = sqrt(ugrd10m*ugrd10m+vgrd10m*vgrd10m)' 
'define wind1 = const( const( maskout( spd, spd - 20), 1), 0.0, -u)' 

'set e 2' 
'define spd = sqrt(ugrd10m*ugrd10m+vgrd10m*vgrd10m)' 
'define wind2 = const( const( maskout( spd, spd - 20), 1), 0.0, -u)' 
... 
'set e 21' 
'define spd = sqrt(ugrd10m*ugrd10m+vgrd10m*vgrd10m)' 
'define wind21 = const( const( maskout( spd, spd - 20), 1), 0.0, -u)' 
'define windavg = (wind1 + wind2 + ... + wind21)/21' 
'define percentage = windavg * 100' 
'd percentage' 
When there are no members, nor control with data at or above the treshold of 20 m/s the field is constant (zero, 0) throughout the plot. 
When plotting such a probability, I always hit that pesky "constant field = 0" message and the plot is filled with a solid red color, while actually it should just show me a map with my color defined at "0%" probability (which is plain white) 
The script itsself works because when I lower the treshold, say to 5, I do get a normal plot with the colorscale i have set. 
Is there a way to turn off the "constant field = 0" message & the resulting red plot, so the map i programmed can be plotted, even when there are no members or control that reach or surpass the given treshold? Is there another possibility to circumvent this problem or a trick any1 can think of? 
I am looking forward to a reply from the grads-community. 


Best regards, 

Jen 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20160810/498c9b17/attachment.html 


More information about the gradsusr mailing list