rplotrix

Modify axis size when using gap.plot


I am creating a plot with axes breaks using the package plotrix, but the standard cex.axis does not seem to work when I build a gap.plot.

Do you know how to proceed to modify the size of the axis?


Solution

  • If you set cex.axis using the par command, you can modify the size of the magnification for axis annotation:

    library(plotrix)
    
    twogrp <- c(rnorm(5)+4,rnorm(5)+20,rnorm(5)+5,rnorm(5)+22)
    gpcol <- c(2,2,2,2,2,3,3,3,3,3,4,4,4,4,4,5,5,5,5,5)
    
    par(cex.axis=2, cex.lab=1.5)
    gap.plot(twogrp, gap=c(8,16), xlab="Index", ylab="Group values",
      main="Gap on Y axis", col=gpcol)
    

    enter image description here