Selects specified columns from a dataframe. If a column does not exist in the dataframe, it will be added with a specified replacement value.
select_columns(df, columns, replace_value = NA)
A dataframe containing the specified columns, with missing columns filled with the replacement value.
A dataframe from which columns are to be selected.
A vector of column names to select.
Value to use for columns that do not exist in the dataframe. Default is NA.