I have an Excel file with 4 tabs, I read these tabs using the following codes:
library(rio)
library(tidyverse)
list<- import_list("test.xlsx", setclass = "tbl")
I get 4 Tibbles for each tab in Excel. I want to stack these Tibbles to get one file. I don't know how to uses stack().
Here is a small sample of the data
Sheet 1
ID colour size
12 Yellow 2
11 Red 3
Sheet 2
ID colour size
11 Blue 1
9 Red 1
sheet3
ID colour size
7 black 1
9 yellow 2
sheet 4
ID colour size
2 Red 1
4 Yellow 1
and the outcome is
ID colour size
12 Yellow 2
11 Red 3
11 Blue 1
9 Red 1
7 black 1
9 yellow 2
2 Red 1
4 Yellow 1