Hi Neha, Have a look at the "names" argument to boxplot. Something like this:
boxplot(a,aa,b,bb,c,cc,e,dd, col="Green", names=c("ab","cd","ef","gh","lm","pq","xy","yz") ) Jim On Fri, Mar 6, 2020 at 7:07 AM Neha gupta <neha.bologn...@gmail.com> wrote: > > Hi > I have a boxplot using the following code and I get the boxplots, but at > the x axis, instead of 1,2,3, how can I get my own captions like , random, > grid, genetic, pso etc. > > a=ran_CV$results$MAE > aa=grid_CV$results$MAE > b=ran_boot$results$MAE > bb=grid_boot$results$MAE > c=ran_locv$results$MAE > cc=grid_locv$results$MAE > e=ran_5CV$results$MAE > dd=grid_5CV$results$MAE > > boxplot(a,aa,b,bb,c,cc,e,dd, col="Green") > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.