[R] symbol in the plot
Johannes Graumann
johannes_graumann at web.de
Fri Nov 20 09:33:08 CET 2009
How about
plot(sigma, delta1, ylim=range(-0.5, 2), xlab='sigma', ylab='delta', pch=22,
type='o')
points(sigma, delta2, col='red', axes=FALSE, type='o')
legend("topleft",c("Delta1","Delta2"),fill=TRUE,col=c("black","red"))
Send runnable example next time.
HTH, Joh
gcheer3 wrote:
>
> TO be specific, here is how I graphed
>
> plot(sigma, delta1, ylim=range(-0.5, 2), xlab='sigma',
> ylab='delta1--square delta2--circle', pch=22, type='o')
> par(new=TRUE)
> plot(sigma, delta2, ylim=range(-0.5, 2), xlab='sigma',
> ylab='delta1--square delta2--circle', col='red', axes=FALSE, type='o')
>
> Thanks a lot
>
>
> gcheer3 wrote:
>>
>> a graph question. Thanks a lot in advance.
>>
>> I made two scatterplots on one graph (sigma vs. delta1, sigma vs. delta2)
>> (20 observations of delta1, delta2 and corresponding sigma) the x-axis is
>> sigma, the y-axis is either delta1 or delta2. I connected both
>> scatterplots. To seperate them, one curves is a line with circles, the
>> other curve is a line with squares on it.
>>
>> I want to make a notation either on the y-axis or on the graph. The
>> notiaion is "delta1--square; delta2--circle". So when people look at the
>> graph, they can easily tell each curve's meaning. The curve with squares
>> on it means the sigma vs. delta1, and the curve with circles on it means
>> sigma vs. delta2. I think I can use 'expression' to write delta1, delta2
>> and sigma in greek letters, but I am not sure how to denote the square
>> and cirle I graphed.
>>
>
More information about the R-help
mailing list