HELP! I'm new to Rstudio.
How can change the orientation of my x-axis to be perpendicular to the axis? and how do I make the names in the x-axis to be in Italics?
Code: #boxplot of the species’ growth rates
boxplot((Spines$GR ~ Spines$Sp),
xlab= "Species",
ylab= "Growth rate (cm/year)",
main = "Growth Rates of Different Species",
names=c("Pinus sylvestris","Pinus uncinata","Pinus pinea","Pinus halepensis","Pinus nigra"),
col = c("grey","grey","grey","grey","grey"))
Like R itself, many of us who answer questions here follow the principle of lazy evaluation. That why you should see the FAQ: What's a reproducible example (`reprex`) and how do I create one? The most common problem, even when complete code such as you've provided, is a lack of the data object.
There's a variety of ways to handle this:
dput(your_data) and cut and paste the output
If large, do the same with a sample
gist a csv file
Find a built-in data set that has the same structure
In this case, the iris dataset is parallel.
I'm going to be further lazy and use ggplot2 because it makes the solution easier.