That is likely because ferm is a factor.  A scatterplot is two numeric 
variables.  To make it a scatterplot wrap ferm with as.numeric. 
Cheers,
Tyler
----------------------------------------
Date: Mon, 14 May 2012 12:21:12 -0700
From: kellycoo...@yahoo.com
To: r-help@r-project.org
Subject: [R] Plot


Hello,

I am trying to make a plot of the rates of an enzyme against three different 
protein concentrations (there are 45 rates in total and split up into 3 groups 
of 15, each receiving one of the 3 protein concentrations). When I enter the 
following code I instead get 3 separate boxplots for each of the three 
different protein concentrations ...


plot(rate ~ ferm, data=LDH, col=LDH$rate, 
pch=c(17,18,19)[(as.numeric(LDH$rate)%%3)+1])


but I want a scatterplot showing 3 different lines indicating each of the 
protein concentrations. I'm not sure if I need to tweak my data set in order to 
get what I want?

I was also wondering how to include the origin (0,0) in the plots. I'm not sure 
if I'm missing something on the plot help page?

Any help would be appreciated. Thanks so much.
        [[alternative HTML version deleted]]


______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
                                          
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to