Category Archives: R

R – barplot with error-bars

I have not found any simple way to make a barplot with error-bars in R, so I had to write a script for it: errorbarplot< -function(data,error,ylab,xlab,main){ palette(c('gray75','grey50','grey25','white')) mar=par()$mar par(xpd=T, mar=par()$mar+c(0,0,0,8)) # Makes a bit space to place the legend maxy=max(data+error)*1.05 … Continue reading

Posted in R | Comments Off on R – barplot with error-bars

How to make a bar graph with a split Y axis in R

There is a function, gap.barplot for doing that in the plotrix package, but I was not happy with the way the result looked, so I started out making my own way using subplot in the TeachingDemos library. I have gutted … Continue reading

Posted in Data, R | Comments Off on How to make a bar graph with a split Y axis in R