corrplot icon indicating copy to clipboard operation
corrplot copied to clipboard

corrRect does not draw full rect at the y limits

Open Famondir opened this issue 2 years ago • 1 comments

Hello there, I just started using corrPlot and tried to draw some custom rects with namesMat. Here my code:

M <- data %>% select(starts_with("Anwendung"), Selbstwirksamkeit, ExtMotiv_Ergebnis, IntrinsischeMotivation, Interesse) %>% 
  select(-Anwendung_Anzahl) %>% 
  mutate_all(as.double) %>% 
  setNames(str_replace(names(.), "_",  "\n")) %>% 
  cor(method = "kendall", use="pairwise.complete.obs")
 
corrplot.mixed(M, upper = 'shade', order = 'AOE', tl.cex = .7) %>% 
  corrRect(namesMat = c("ExtMotiv\nErgebnis", "Anwendung\nAbgestimmt", "Interesse", "Anwendung\nModulbedeutung"))

image

The problem is that the rect is not drawed completely on the lower border. Same happens on the top border:

corrplot.mixed(M, upper = 'shade', order = 'AOE', tl.cex = .7) %>% 
  corrRect(namesMat = c("Anwendung\nAbgestimmt", "ExtMotiv\nErgebnis", "Anwendung\nModulbedeutung", "Interesse"))

image

I use R 4.2.1 on Windows 10 build 19042.1889.

I hope you can help me out here.

Famondir avatar Sep 07 '22 08:09 Famondir

This is due to the resolution.

You can save it as a pdf file.

taiyun avatar Sep 26 '22 03:09 taiyun