View source: R/utils_columns.R
billionaiRe_add_columns | R Documentation |
The function takes in a data frame, a vector of column names, and a vector of base fill to use for the column. If the column doesn't already exist, it is added to the data frame and filled with the relevant fill value.
billionaiRe_add_columns(df, cols, fill)
df |
A data frame. |
cols |
A character vector of column names to add. |
fill |
A list of fill to be used for each column. If length 1, same fill
is used for each column. Can also be a vector, but lists allow different types
of fill, e.g. |
A data frame.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.