define independant data set
Bernd Becker
bernd.becker at METOFFICE.GOV.UK
Wed Apr 29 11:30:19 EDT 2009
Hello,
this is an odd question:
can one define a data set in grads independent from any external data
set?
How do you:
define x='1 2 3 4 5 6 7 8 9'
define y=x*x
d y
and get an y ver. x line plot ?
The background:
I compiled event statistics by mask and const,
count some numbers at individual grid points,
constructed a curve, or at least the vector for it
and now I want to plot it.
I can draw a line, scaling the numbers to the plot window.
That looks really bland.
I also like to get appropriate axis and other nice bits.
Any ideas how to do that?
t = 0
sum = 1
scalex = 6.5/32.
scaley = 5.5/1.
xstr=''
ystr=''
linestr=''
while ( t <= 32 )
xstr= xstr ' ' t ' '
ystr= ystr ' ' cdf.t ' '
xx = 1 + t* scalex
yy = 1 + cdf.t* scaley
linestr= linestr' ' xx ', ' yy ', '
t = t + 1
endwhile
* plot cdf
say linestr
'draw line 'linestr
cdf.t are numbers [ 1, 0 ] over 32 steps.
--
Bernd Becker The Monthly Outlook
Met Office FitzRoy Road Exeter Devon EX1 3PB United Kingdom
Tel.: +44 (0) 1392 884511 Fax: +44 (0)870 900 5050
E-mail:bernd.becker at metoffice.com - http://www.metoffice.com
More information about the gradsusr
mailing list