powered by
set_contents() is a convenience function to change the cell contents of a huxtable within a dplyr chain. set_contents(ht, x, y, foo) just calls ht[x, y] <- foo and returns ht.
set_contents()
set_contents(ht, x, y, foo)
ht[x, y] <- foo
ht
contents(ht) contents(ht) <- value set_contents(ht, row, col, value, byrow = FALSE) map_contents(ht, row, col, fn)
A huxtable.
Cell contents.
A row specifier. See rowspecs for details.
An optional column specifier.
A mapping function. See mapping-functions for details.
Deprecated. Use by_cols() instead.
by_cols()
# NOT RUN { set_contents(jams, 2, 1, "Blackcurrant") map_contents(jams, by_regex(".*berry" = "Snodberry")) # }
Run the code above in your browser using DataLab