I am trying to plot ggplot matrix, the box plot version works just fine but when I try to do the same with ggplot I fail miserably
boxplot version:
par(mfrow=c(3, 3))
for (scale in c("POMS",
"POMS_post",
"DERS",
"DERS_post",
"REAPPRAISAL",
"REAPPRAISAL_POST",
"NEGATIV",
"NEGATIVE_POST")) {
boxplot(kata1[, scale] ~ Skupina, data=kata1, ylab=scale)
}
ggplot version:
# Testing
for (scale in c("POMS",
"POMS_post",
"DERS",
"DERS_post",
"REAPPRAISAL",
"REAPPRAISAL_POST",
"NEGATIV",
"NEGATIVE_POST")) {
ggally_box(kata1, aes(Skupina, kata1[, scale])) # This does not work...
}
I think it should not be that difficult but I am stuck.
Thank you for help!