R: How do I remove the sub (error) label in partimat plot from klaR package

75 views Asked by At

I am wanting to produce a klaR::partimat plot with as small margins as I can (so it shows up nicely in a quarto document.) I have managed to play with the margins & font size to get it close to what I want, but can't figure out how to remove the main label on each subplot (or at least set its font size to something tiny.)

This is the code I am currently using and I have attached a picture showing what I want to remove. Thanks for your help!

require(klaR)
partimat(Species ~ ., data=iris, method="qda",mar=c(1,1,1,1),plot.control=list(cex=1,cex.axis=0.01,tcl=NA,mgp=c(0.2,0.1,0.1)),main="")

partimat plot

1

There are 1 answers

1
zos474 On

I figured it out via a comment in the help file that says plot parameters are passed to drawparti. For that function, it allows you to set print.err=0, which fixes it:

require(klaR) partimat(Species ~ ., data=iris, method="qda",mar=c(1,1,1,1),plot.control=list(cex=1,cex.axis=0.01,tcl=NA,mgp=c(0.2,0.1,0.1)),main="",print.err = 0)

enter image description here