UCLA Academic Technology Services HomeServicesClassesContactJobs
Search

SPSS FAQ
How can I graph two (or more) groups using different symbols?

Suppose we are using the High School and Beyond data file (hsb2) which has test scores for 200 students, 91 males and 109 females.  We could make a graph of their read and write scores as shown below with the graph command.

get file 'c:\hsb2.sav'.

graph
 /scatterplot(bivar) = write with read.
 Scatter of read write 

Now, let's make a graph where we see the scores separately for the males and the females.  We will use the by option with the graph command, and SPSS will assign different symbols to each group.

GRAPH
  /SCATTERPLOT=read WITH write by female.


Scatter of write read by female

If you would like to change the symbols (SPSS calls them "markers") used for the groups, double click on the graph to open the chart editor, select select "format", then "marker", and then select the marker and the size that you would like. Click on "apply", "close" and then close the chart editor. If you would like to have different markers for the different groups, double click on the graph, double click on the legend on the right that labels the groups, and select (i.e., single click on) the group whose marker you would like to change. Next, select "format", "marker", and then select the marker and the size that you would like. Click on "apply", click on "close" and then close the chart editor.

GRAPH
  /SCATTERPLOT=read WITH write by female.

Scatter of write read by female


How to cite this page

Report an error on this page

UCLA Researchers are invited to our Statistical Consulting Services
We recommend others to our list of Other Resources for Statistical Computing Help
These pages are Copyrighted (c) by UCLA Academic Technology Services


The content of this web site should not be construed as an endorsement of any particular web site, book, or software product by the University of California