Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

change thickness of the whole line geom_boxplot()

Tags:

r

ggplot2

boxplot

I would like to increase the boldness of the entire boxplot to be more visible on the hard copy. from Here seems "fatten" parameter change the thickness of the only median line. Is there any other parameter that control the thickness/width of the the whole box plot ?

require(reshape) require(ggplot2) cars_melt = melt(cars)  ggplot(aes(x = variable, y = value), data = cars_melt) +    geom_boxplot(fatten = 2)  
like image 858
Areza Avatar asked May 02 '14 17:05

Areza


People also ask

How do I change the thickness of a line in ggplot2?

Line width in ggplot2 can be changed with argument size= in geom_line() .

Which argument should I use and in geom_boxplot () to dictate the width of the lines in my graph?

We can do this by using lwd argument of geom_boxplot function of ggplto2 package.

How do I increase the size of a Boxplot in R?

When we create a boxplot for a column of an R data frame that contains outlying values, the points for those values are smaller in size by default. If we want to increase the size for those outlying points then outlier. size argument can be used inside geom_boxplot function of ggplto2 package.


1 Answers

Use geom_boxplot(lwd=3) ("lwd" for "line width"). Also, if lwd makes the median too thick, you can use lwd and fatten together to make the median line thinner relative to the other lines.

like image 191
eipi10 Avatar answered Sep 16 '22 16:09

eipi10