Learn R Programming

googlesheets4 (version 0.1.0)

sheets_find: Find Google Sheets

Description

Finds your Google Sheets. This is a very thin wrapper around googledrive::drive_find(), that specifies you want to list Drive files where type = "spreadsheet". Therefore, note that this will require auth for googledrive! See the article Using googlesheets4 with googledrive if you want to coordinate auth between googlesheets4 and googledrive.

Usage

sheets_find(...)

Arguments

...

Arguments (other than type, which is hard-wired as type = "spreadsheet") that are passed along to googledrive::drive_find().

Value

An object of class dribble, a tibble with one row per item.

Examples

Run this code
# NOT RUN {
if (sheets_has_token()) {
  # see all your Sheets
  sheets_find()

  # see 5 Sheets, prioritized by creation time
  x <- sheets_find(order_by = "createdTime desc", n_max = 5)
  x

  # hoist the creation date, using other packages in the tidyverse
  # x %>%
  #   tidyr::hoist(drive_resource, created_on = "createdTime") %>%
  #   dplyr::mutate(created_on = as.Date(created_on))
}
# }

Run the code above in your browser using DataLab