Hi Jim, looks perfect to me. Thank you very much. One last question. Is there any possibility to add 3 horizontal lines in the graph. One at 25%, the other one at 50% and the last one at 75%? So I can see the process a bit better?
Thank you. Best regards. Mat -----Ursprüngliche Nachricht----- Von: Jim Lemon [mailto:j...@bitwrit.com.au] Gesendet: Samstag, 25. Oktober 2014 03:27 An: Matthias Weber Cc: r-help@r-project.org Betreff: Re: AW: [R] dotplot with library lattice On Fri, 24 Oct 2014 12:49:39 PM Matthias Weber wrote: > > I want always to see the "Process" of the green button in dependence > of the blue button at 100%. Okay. mwdat<-read.table(text= "KOST Budget IST 1060 -2.18 0 1080 91037.71 91647.15 1100 955573.87 907938.98 1120 23326.8 0 1150 2521.57 0 1180 51302.03 48760.45 1200 2027.04 -1667.5 1210 2385.03 2386.06 1220 0 0 1250 528.87 0 1255 766.54 0 1260 12154.97 4861.41 Gesamtbudget 1141622.25 1054236.55", header=TRUE) par(las=1,mar=c(5,7,4,6)) plot(rep(100,13),1:13,main="IST against Budget", xlab="IST/Budget (prozent)",ylab="KOST", xlim=c(0,100),type="n",yaxt="n") abline(h=1:13,lty=2,col="lightgray") points(rep(100,13),1:13,pch=19,col="blue",cex=3) mwdat$ISTpct<-100*mwdat$IST/mwdat$Budget # fix divide by zero mwdat$ISTpct[9]<-0 points(mwdat$ISTpct,1:13,pch=19,col="green",cex=3) legend(105,10,c("Budget","IST"),pch=19, col=c("blue","green"),bty="n",xpd=TRUE) axis(2,at=1:13,labels=mwdat$KOST) par(las=0,mar=c(5,4,4,2)) Jim This e-mail may contain trade secrets, privileged, undisclosed or otherwise confidential information. If you have received this e-mail in error, you are hereby notified that any review, copying or distribution of it is strictly prohibited. Please inform us immediately and destroy the original transmittal. Thank you for your cooperation. Diese E-Mail kann Betriebs- oder Geschaeftsgeheimnisse oder sonstige vertrauliche Informationen enthalten. Sollten Sie diese E-Mail irrtuemlich erhalten haben, ist Ihnen eine Kenntnisnahme des Inhalts, eine Vervielfaeltigung oder Weitergabe der E-Mail ausdruecklich untersagt. Bitte benachrichtigen Sie uns und vernichten Sie die empfangene E-Mail. Vielen Dank. ______________________________________________ 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.