Question: Assume object a contains the data you need to plot the following graph. To generate the following graph, in which the error bars stand for
Assume object "a" contains the data you need to plot the following graph. To generate the following graph, in which the error bars stand for the standard deviation (SD) and the background is white, what can be a line of the codes you write by using the R package "ggplot2"?
ggplot2(a,aes(x=Months_of_Age,y=Mean,fill=Mouse))+geom_bar(position=position_dodge(),stat=="identity",col="black")+geom_errorbar(aes(ymin=Mean-SD,ymax=Mean+SD),width=.2, position=position_dodge(.9)+theme_bw())
ggplot2(a,aes(x=Age_Months))+geom_bar(position=position_dodge(),stat="identity",colour="black")+geom_errorbar(aes(ymin= SEM,ymax= SEM),width=.2, position=position_dodge(.9))+theme_bw()
ggplot(a,aes(x=Age_Months,y=Mean,fill=Mouse))+geom_bar(position=position_dodge(),stat="identity",colour="black")+geom_errorbar(aes(ymin=Mean-SEM,ymax=Mean+SEM),width=.2, position=position_dodge(.9))+theme_bw()
ggplot(a,aes(x=Age_Months,y=Mean,fill=Mouse))+geom_bar(position=position_dodge(),stat="identity",col="black")+geom_errorbar(aes(ymin=Mean-SD,ymax=Mean+SD),width=.2, position=position_dodge(.9))+theme_bw()
ggplot(a,aes(x=Age_Months,y=Mean,fill=Mouse))+geom_bar(position=position_dodge(),stat="identity",colour="black")+geom_errorbar(aes(ymin= SD,ymax= SD),width=.2, position=position_dodge(.9))
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
