0

I am using pairs to plot mosaic plots of various variables in the SleepStudy dataset.

SleepStudy_factors <- SleepStudy[sapply(SleepStudy, is.factor)] 
SleepStudy_factors <- table(SleepStudy_factors)


pairs(SleepStudy_factors, diag_panel = pairs_text,highlighting = 2,direction=c("v","h"))

With this, I get a pairs plot where the diagonal entries are the names of the variables and the different levels they have.

Pairs Plot

I am trying to decrease the font size of the text in the diagonal boxes , I have tried cex with text.panel but that is not making any difference.

pairs(SleepStudy_factors, diag_panel = pairs_text,highlighting = 2,direction=c("v","h") ,text_panel=list(cex=0.5))

Need some tips to decrease the text font?

Vijay Kalmath
  • 178
  • 11

1 Answers1

0

If I remembered right, you should change the parameter cex.labels.

Also you can change a style of text by font.labels

And try to cut/write text in multiple lines. It will look better.

manro
  • 3,529
  • 2
  • 9
  • 22