Update: Gone manual, cut and paste into multiple sheets. Would be great to find a workaround all the same.
Question: Given the dummy data set below:
structure(list(V1 = structure(c(8L, 6L, 2L, 4L, 1L, 1L, 1L, 1L,
9L, 5L, 2L, 1L, 1L, 1L, 1L, 10L, 7L, 3L), .Label = c("", "1",
"12", "5", "Age", "Class A", "Height", "Number of Boys", "More Boys",
"More Girls"), class = "factor"), V2 = structure(c(1L, 5L, 3L,
4L, 1L, 1L, 1L, 1L, 1L, 6L, 3L, 1L, 1L, 1L, 1L, 1L, 7L, 2L), .Label = c("",
"12", "2", "6", "Class B", "Time", "Weight"), class = "factor"),
V3 = structure(c(1L, 5L, 3L, 4L, 1L, 1L, 1L, 1L, 1L, 6L,
3L, 1L, 1L, 1L, 1L, 1L, 7L, 2L), .Label = c("", "13", "3",
"7", "Class C", "Next", "Time"), class = "factor"), V4 = structure(c(1L,
5L, 3L, 4L, 1L, 1L, 1L, 1L, 1L, 6L, 3L, 1L, 1L, 1L, 1L, 1L,
6L, 2L), .Label = c("", "14", "4", "8", "Class D", "Day"), class = "factor"),
V5 = c(NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA), V6 = c(NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), V7 = c(NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA
), V8 = c(NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA), V9 = c(NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), V10 = structure(c(5L,
4L, 3L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L), .Label = c("", "1", "8", "Class E", "Number of Girls"
), class = "factor"), V11 = structure(c(1L, 4L, 3L, 2L, 1L,
1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = c("",
"2", "8", "Class F"), class = "factor"), V12 = structure(c(1L,
4L, 3L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L), .Label = c("", "3", "9", "Class G"), class = "factor"),
V13 = structure(c(1L, 4L, 2L, 3L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = c("", "0", "4",
"Class Q"), class = "factor"), V14 = c(NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA)), class = "data.frame", row.names = c(NA,
-18L))
This visually looks like(truncated):
V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14
1 Number of Boys NA NA NA NA NA Number of Girls NA
2 Class A Class B Class C Class D NA NA NA NA NA Class E Class F Class G Class Q NA
3 1 2 3 4 NA NA NA NA NA 8 8 9 0 NA
4 5 6 7 8 NA NA NA NA NA 1 2 3 4 NA
5 NA NA NA NA NA NA
6 NA NA NA NA NA NA
7 NA NA NA NA NA NA
8 NA NA NA NA NA NA
9 More Boys NA NA NA NA NA NA
10 Age Time Next Day NA NA NA NA NA NA
11 1 2 3 4 NA NA NA NA NA NA
12 NA NA NA NA NA NA
As can hopefully be seen, these are separate "files" on the same worksheet. I've looked for a quick way to scoop out the different data sets but haven't(yet). Could there be a work around? My idea was to use a sequence based selection, say select every 20 rows but this will obviously fail if you have millions of rows?
Expected Ouptut(with their respective rows)
Three data sets:
A: Number of Boys
B: Number of Girls
C: More Boys
Thanks in advance.