sheet_resize | R Documentation |
Changes the number of rows and/or columns in a (work)sheet.
sheet_resize(ss, sheet = NULL, nrow = NULL, ncol = NULL, exact = FALSE)
ss |
Something that identifies a Google Sheet:
Processed through |
sheet |
Sheet to resize, in the sense of "worksheet" or "tab". You can identify a sheet by name, with a string, or by position, with a number. |
nrow , ncol |
Desired number of rows or columns, respectively. The default
of |
exact |
Logical, indicating whether to impose |
The input ss
, as an instance of sheets_id
Makes an UpdateSheetPropertiesRequest
:
Other worksheet functions:
sheet_add()
,
sheet_append()
,
sheet_copy()
,
sheet_delete()
,
sheet_properties()
,
sheet_relocate()
,
sheet_rename()
,
sheet_write()
# create a Sheet with the default initial worksheet
(ss <- gs4_create("sheet-resize-demo"))
# see (work)sheet dims
sheet_properties(ss)
# no resize occurs
sheet_resize(ss, nrow = 2, ncol = 6)
# reduce sheet size
sheet_resize(ss, nrow = 5, ncol = 7, exact = TRUE)
# add rows
sheet_resize(ss, nrow = 7)
# add columns
sheet_resize(ss, ncol = 10)
# add rows and columns
sheet_resize(ss, nrow = 9, ncol = 12)
# re-inspect (work)sheet dims
sheet_properties(ss)
# clean up
gs4_find("sheet-resize-demo") %>%
googledrive::drive_trash()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.