This function is an extension of the `tidyr::gather()` function. It can `tidyr::gather()` on multiple keys and values
reshape_gather(x, variable.names, values, id = NULL, separate.pattern = NULL)
x | dataframe |
---|---|
variable.names | The variable used for gathering |
values | If using more than one variables column then specify name of a new combined column |
id | What column is not being reorganized and needs to be preserved. Usually "Subject" |
separate.pattern | stuff |
reshape_gather(x, variables = "variable", values = c("value1", "value2"), by = "Subject")#> Error in reshape_gather(x, variables = "variable", values = c("value1", "value2"), by = "Subject"): unused arguments (variables = "variable", by = "Subject")