Dear researchers I wish to plot a box plot without the mean line (the black line) and the i wish a full line for the standard deviation This is an example mytest <- c(2.1,2.6,2.7,3.2,4.1,4.3,5.2,5.1,4.8,1.8,1.4,2.5,2.7,3.1,2.6,2.8) boxplot(mytest) really thanks Gianni [[alternative HTML version deleted]]
Hi Gianni, Have a look at this function: http://hosho.ees.hokudai.ac.jp/~kubo/Rdoc/library/gplots/html/plotCI.html And please also read this: http://en.wikipedia.org/wiki/Box_plot So to know how a boxplot is constructed... ----------------Contact Details:------------------------------------------------------- Contact me: Tal.Galili@gmail.com | 972-52-7275845 Read me: www.talgalili.com (Hebrew) | www.biostatistics.co.il (Hebrew) | www.r-statistics.com (English) ---------------------------------------------------------------------------------------------- On Fri, Jan 27, 2012 at 4:47 PM, gianni lavaredo <gianni.lavaredo@gmail.com>wrote:> Dear researchers > > I wish to plot a box plot without the mean line (the black line) and the i > wish a full line for the standard deviation > > This is an example > > mytest <- > c(2.1,2.6,2.7,3.2,4.1,4.3,5.2,5.1,4.8,1.8,1.4,2.5,2.7,3.1,2.6,2.8) > boxplot(mytest) > > > really thanks > > Gianni > > [[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. >[[alternative HTML version deleted]]
On Jan 27, 2012, at 9:47 AM, gianni lavaredo wrote:> Dear researchers > > I wish to plot a box plot without the mean lineIt's not at the mean.> (the black line) and the i > wish a full line for the standard deviationAnd the boxplot whiskers are not at the standard deviations, either. It is a non-parametric plot. ?boxplot ?boxplot.stats ?fivenum There are many requests over the years from people with varying degrees of knowledge about what box-and-whisker plots really are .... and with posted responses to requests for plotting results that meet their desired preconceptions about what boxplots should be (but aren't). You should exercise (or build) your searching skills. (This is practically a plotting FAQ.)> > This is an example > > mytest <- > c(2.1,2.6,2.7,3.2,4.1,4.3,5.2,5.1,4.8,1.8,1.4,2.5,2.7,3.1,2.6,2.8) > boxplot(mytest) >Try putting in a large number in that vector, say a single 500, print the mean and standard deviations and then see what happens to the boxplot. It won't be as you expect. -- David Winsemius, MD West Hartford, CT