Newmodel <- read.csv("Torsion .csv")
ggplot(Newmodel, aes( y = Axial, x = Percen, fill = Species)) + geom_boxplot() +theme_classic() + xlab("Head Length percentage") + ylab("Axial Force (mN)")
Newmodel$Percen <- factor(Newmodel$Percen)
I am trying to get a ggplot box plot of species and head length percentages with the response variable axial force. I am getting individual dots along with a strange y-axis bar. I tried putting head length percentages as a factor, but it generates the same plot. I have used the same code for previous files, and it worked. However, this file is not working. Please help! I would appreciate it. [Here is the "box plot" generated from ggplot geom__boxplot before and after using Percen as a factor
Here is the plot before and after establishing percent as a factor