splitA(whale)
# teasel -fertilitiles in last column
splitA(teasel, r=1:6, c=6)
# hudsonia - fertilities in first two columns
A <- hudsonia[[1]]
splitA(A, r=1:2)
## example using a logical matrix (if fertilities were in the upper diagonal)
splitA(A, row(A)
Run the code above in your browser using DataLab