Description Usage Arguments Value Examples
Work around different treatment of character types across remote data sources when adding a constant column to a table. Deals with issues such as Postgresql requiring a character-cast and MySQL not allowing such.
1 2 3 4 5 6 7 | addConstantColumn(
d,
colName,
val,
...,
tempNameGenerator = mk_tmp_name_source("replyr_addConstantColumn")
)
|
d |
data.frame like object to add column to. |
colName |
character, name of column to add. |
val |
scalar, value to add. |
... |
force later arguments to be bound by name. |
tempNameGenerator |
temp name generator produced by wrapr::mk_tmp_name_source, used to record dplyr::compute() effects. |
table with new column added.
1 2 | d <- data.frame(x= c(1:3))
addConstantColumn(d, 'newCol', 'newVal')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.