How can I plot data on continuous not ordinal scale

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

How can I plot data on continuous not ordinal scale

valerie_s

Help please

 

I am plotting a series of graphs but I cannot work out how to get spssx to plot year on continuous scale – there is no data for the years 1986 to 1990. At the moment I can get plots but data for 1991 plotted next to that for 1985. My syntax is below. I have defined year to be scale, and have used chart builder to get  year plotted out correctly for single lines  but then cant work out how to get multiple lines on same plot.

 

I seem to remember, I had a similar problem before but I cant remember how I solved it.

 

Many thanks

Valerie

 

>>> 

GRAPH

  /LINE(MULTIPLE)=MEAN(rate) BY year BY gp

  /PANEL COLVAR=agegp COLOP=CROSS ROWVAR=sex ROWOP=CROSS   /MISSING=REPORT.

Reply | Threaded
Open this post in threaded view
|

Re: How can I plot data on continuous not ordinal scale

Maguin, Eugene

Valerie,

 

Do you have records for the years 86 to 90 in your dataset? It sounds like you have missing data for those years. I don’t know how graph deals with missing data in a problem such as yours. Alternatively, would the meaning be damaged if you gave those years a very small value or a value of 0?

 

Gene Maguin

 

 

From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Valerie Seagroatt
Sent: Tuesday, August 21, 2012 8:33 AM
To: [hidden email]
Subject: How can I plot data on continuous not ordinal scale

 

Help please

 

I am plotting a series of graphs but I cannot work out how to get spssx to plot year on continuous scale – there is no data for the years 1986 to 1990. At the moment I can get plots but data for 1991 plotted next to that for 1985. My syntax is below. I have defined year to be scale, and have used chart builder to get  year plotted out correctly for single lines  but then cant work out how to get multiple lines on same plot.

 

I seem to remember, I had a similar problem before but I cant remember how I solved it.

 

Many thanks

Valerie

 

>>> 

GRAPH

  /LINE(MULTIPLE)=MEAN(rate) BY year BY gp

  /PANEL COLVAR=agegp COLOP=CROSS ROWVAR=sex ROWOP=CROSS   /MISSING=REPORT.

Reply | Threaded
Open this post in threaded view
|

Re: How can I plot data on continuous not ordinal scale

Andy W
In reply to this post by valerie_s
Generate the graph through the chart builder dialog (i.e. GGRAPH). Those legacy GRAPH statements force everything to be categorical on the X axis I believe.

If you provide an example of your dataset I would provide an example with your data, but the chart builder dialog is pretty simple to figure out on your own IMO.
Andy W
apwheele@gmail.com
http://andrewpwheeler.wordpress.com/