Click here to see the SAS code.
Click here to see the example.

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

See my blog for more information about this graph!


This plot includes data from several different files:

http://epec.saw.usace.army.mil/jormsr.txt
http://epec.saw.usace.army.mil/jord00pr.txt
http://epec.saw.usace.army.mil/bejrept.txt


I use a couple of tricks here - perhaps so subtle that you wouldn't notice them 
unless I point them out...

In the first plot, you probably notice that I make it *very* wide, 
using "goptions xpixels" - I tried several values, and this width
seemed 'appropriate' for this data.

Also, the data has the year & numeric month (1-12), and I had to
come up with a way to combine the year & month and make it come out
as a correctly-paced value.  A wrong way to do it would be to 
combine the year & month like 1983.1, 1983.2, ... 1983.12
(this would not come out as a properly-spaced numeric axis,
or if it's character then it wouldn't sort correctly).
One correct way would be to create a string of the year & month
(and say the data is on the 1st day of the month) and then 
'input' it into a date variable.  But instead, I chose to 
calculate the time value as ...

    timevar=year+((month-1) * 1/12);

The 2nd & 3rd plots are pretty much standard, except for the 13th tick
along the x-axis ... The data has the lake level for both the beginning
and ending of the month, so I plot the beginning lake-level value, and
then on the final (december, month=12) tickmark month, I output another
obsn which contains the ending value for december.  This gives a little
bit of wrap-around & duplication of the Jan 1st values (since the Dec 31
and the Jan 1 values are essentially the same), but I think it shows
some valuable info, and helps you visually follow the trend better.


Back to Samples Index