[gradsusr] Plotting Station data

Lukas Mosimann lumosimann at gmail.com
Fri Mar 19 10:11:03 EDT 2010


Hi Jennifer

 

Thanks a lot. That’s exactly what I’ve been looking for!

 

Sry that I haven’t found any older archives than March 2010.

 

Von: gradsusr-bounces at gradsusr.org [mailto:gradsusr-bounces at gradsusr.org] Im
Auftrag von Jennifer Adams
Gesendet: Freitag, 19. März 2010 15:03
An: GrADS Users Forum
Betreff: Re: [gradsusr] Plotting Station data

 

Hi, Lukas -- 

This question has come up before, but the archives are hard to search
through at the moment. Attached below is the question and the script
fragment and image sample that illustrate how it works. 

--Jennifer 

 

On Mar 19, 2010, at 9:53 AM, Lukas Mosimann wrote:





Hello everybody

I have already used Grads for a few months but I have never tried to plot
station data. And now I tried to do so - but I didn't have much effort ;)

I would like to plot the temperatures of some weather stations in different
colors depending on the value. I tried the following



...

set gxout value

set ccolor rainbow

d var


But I only got white values - but I would like to get colored values (not
points. When I use "set gxout stnmark" instead of value, I don't have any
problems).
Is there any possibility to plot such a map with station data? And what did
I do wrong?

Thanks a lot.

Lukas

 

-------------------------------------------------

 

On Aug 10, 2009, at 3:55 AM, Jennifer Faber wrote:





Hi Jennifer

 

I was wondering if you and your team are considering adding a feature fto
GrADS to colour station value according to their value.

Until so far there was been no good solution to my problem.

 

Here is a script fragment I composed, followed by the image output. I think
this is what you are trying to do...

 

'set lat 22 55'

'set lon -130 -60'

var = 'ts'

levs = '-15 -10 -5 0 5 10 15'

cols = '9  4   5  3 7 8  2  6'

ncols=8

c=1

while (c<=ncols)

  col=subwrd(cols,c)

  maxlev=subwrd(levs,c)

  if (c>1)

    minlev=subwrd(levs,c-1)

  endif

  'set ccolor 'col

  'set gxout value'

  'set stat on'

  if (c=1)

    belowmax='(maskout('var',('maxlev'-0.0001)-'var'))'

    'd 'belowmax

  else

    minandabove='(maskout('var','var'-('minlev')))'

    if (c=ncols)

      'd 'minandabove

    else

      belowmax='maskout('minandabove',('maxlev'-0.0001)-'minandabove')'

      'd 'belowmax

    endif

  endif  

  c=c+1

endwhile

 

 



 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20100319/ee4d225a/attachment-0003.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/png
Size: 20490 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20100319/ee4d225a/attachment-0003.png 


More information about the gradsusr mailing list