-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
project.org] On Behalf Of Naser Jamil
Sent: Monday, March 11, 2013 3:10 PM
To: R help
Subject: [R] vertical lines in R plot
Dear All,
May I seek your suggestion on a simple issue. I want to draw vertical
lines at some positions in the following R plot. To be more specific, I
wish to draw vertical lines at d=c(5.0,5.5,6) and they should go till
p=c(0.12,0.60,0.20) . I haven't found any way out, though made
several attempts. Please run the following commands first if you are
interested in!
#######################################################
psi1<-function(alpha1,beta1,alpha2,beta2,d){
exp(alpha1+beta1*d)/((1+exp(alpha1+beta1*d))*(1+exp(alpha2+beta2*d)))
}
alpha1<--3.5
beta1<-1
alpha2<--6
beta2<-0.72
d<-seq(0.5,10,0.01)
plot(d,psi1(alpha1,beta1,alpha2,beta2,d),type="l",pch=18, ylim=c(0,1),
xlab="Dose", ylab="Probabilitty")
##########################################################
Many thanks for the help!
Regards,
Jamil.
[[alternative HTML version deleted]]