-1

I am trying to write a script that plots violin plot without explicitly describing the levels of the plot. lets say: x1=c(x11,x22,....,x1n), x2=c(x21,x22,...,x2m), ... xp=(xl1,....,xlj). If I had the number of levels in advance I could have enterend: violin(x1,x2,...,xp). However, I can't (the number of levels (p) is defined is a variable). I am tried to put it in datastrucre (x=list(x1,x2,...xp) and than do violin(x). But it did not work. is there someway else to put the vector in some data structure that could be passed to violin().
Thank you

user552231
  • 1,095
  • 3
  • 21
  • 40

1 Answers1

0

Gregor gave the answer:
do.call(what = vioplot, args = x)

user552231
  • 1,095
  • 3
  • 21
  • 40