Description Usage Arguments Value Storing parameters on goooglesheets Best for tabular data
When googlesheets4::gs4_has_token(), returns updated ss from sheet, otherwise local copy from last run.
See googlesheets4::read_sheet() for details.
1 2 3 4 5 6 7 |
sheet |
Sheet to read, in the sense of "worksheet" or "tab". You can identify a sheet by name, with a string, or by position, with a number. Ignored if the sheet is specified via |
ss |
Something that identifies a Google Sheet: its file ID, a URL from
which we can recover the ID, an instance of |
dir |
|
update |
|
... |
Arguments passed on to
|
A tibble
On the one hand, it is best to keep all survey application parameters (such as response options) under source control management (SCM). On the other hand, some study collaborators may want to frequently and easily change parameters, and be unable or unwilling to use SCM.
This function allows such "non-tech" collaborators to edit survey parameters in a Google Spreadsheet online, while regularly committing their contributions to the source.
To use this function:
Set up a Google Spreadsheet; authorize collaborators and optionally add write protections and notifications for the developer where appropriate.
Let collaborators edit the Google Spreadsheet.
Whenever an edit has been made, the developing collaborator can pull updates from Google Spreadsheets using this function from her local development machine (or wherever (googlesheets4::gs4_has_token()) and commit the result as a deparsed tibble.
Ensure that changing entry parameters will not compromise data collection, the database schema or analysis.
This helper pertains only to those survey parameters best edited and represented in tabular form, such as dropdown options in different languages and the like.
Longer strings (several sentences), especially with markup, are awkward in spreadsheets and deparsed tibble::tribble()s and better served via strings_from_mdfile().
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.