byrow
controls whether edited cells will extend
from the anchor across a row or down a column.gs_edit_cells(ss, ws = 1, input = "", anchor = "A1", byrow = FALSE,
col_names = NULL, trim = FALSE, verbose = TRUE)
googlesheet
objectbyrow =
TRUE
) or down a column (byrow = FALSE
, default); consulted only
when input
is a vector, i.e. dim(input)
is NULL
length(dim(input))
equals 2, i.e. input
is a matrix or
data.framegs_add_row
yo <- gs_new("yo")
yo <- gs_edit_cells(yo, input = head(iris), trim = TRUE)
gs_read(yo)
yo <- gs_ws_new(yo, ws = "byrow_FALSE")
yo <- gs_edit_cells(yo, ws = "byrow_FALSE",
input = LETTERS[1:5], anchor = "A8")
gs_read_cellfeed(yo, ws = "byrow_FALSE", range = "A8:A12") %>%
gs_simplify_cellfeed()
yo <- gs_ws_new(yo, ws = "byrow_TRUE")
yo <- gs_edit_cells(yo, ws = "byrow_TRUE", input = LETTERS[1:5],
anchor = "A8", byrow = TRUE)
gs_read_cellfeed(yo, ws = "byrow_TRUE", range = "A8:E8") %>%
gs_simplify_cellfeed()
yo <- gs_ws_new(yo, ws = "col_names_FALSE")
yo <- gs_edit_cells(yo, ws = "col_names_FALSE", input = head(iris),
trim = TRUE, col_names = FALSE)
gs_read_cellfeed(yo, ws = "col_names_FALSE") %>%
gs_reshape_cellfeed(col_names = FALSE)
gs_delete(yo)
Run the code above in your browser using DataLab