How to create more than one level using split function in R

r

#1

I was studying about split function and understand that we can create the level. I am able to generate the one level but struggled to generate more than one level.

For example:
x<-rnorm(10)
I want to divided in two level


#2

@sid100158-It is better to use two gl function for creating two level and then use interaction function to it
f1<-gl(2,5)
f2<-gl(5,2)
and then interaction of f1 and f2
y<- interaction(f1,f2)
then use split function on it
split(x,y)
Hope this helps!