[R] Boxplot with grouped data

Jakson A. Aquino jaksonaquino at gmail.com
Thu Oct 22 18:31:23 CEST 2009


On Thu, Oct 22, 2009 at 04:36:22PM +0100, Paul Smith wrote:
> Is there some way of drawing a boxplot, with R, when one does not have
> the original continuous data, but only the data grouped in classes?
> The function boxplot() can only deal with original data.

Do you mean a numeric vector grouped by a factor? If you have a
numeric vector x and a categorical variable f, then:

boxplot(x ~ f)




More information about the R-help mailing list