Standard-evaluation version of
This is a S3 generic.
spread_(data, key_col, value_col, fill = NA, convert = FALSE, drop = TRUE, sep = NULL)
- A data frame.
- key_col, value_col
- Strings giving names of key and value cols.
- If set, missing values will be replaced with this value. Note
that there are two types of missingness in the input: explicit missing
NA), and implicit missings, rows that simply aren't present. Both types of missing value will be replaced by
asis = TRUEwill be run on each of the new columns. This is useful if the value column was a mix of variables that was coerced to a string. If the class of the value column was factor or date, note that will not be true of the new columns that are produced, which are coerced to character before type conversion.
FALSE, will keep factor levels that don't appear in the data, filling in missing combinations with
NULL, the column names will be taken from the values of
keyvariable. If non-
NULL, the column names will be given by "
Looks like there are no examples yet.