Questions tagged [r-googlesheets]

Use this tag for questions related to the R googlesheets-package.

Access and manage Google spreadsheets from R with googlesheets.

References

65 questions
26
votes
5 answers

How to export a csv from Google Sheet API?

I can't find any reference to an API that enables Rest API clients to export an existing Google Sheet to a csv file. https://developers.google.com/sheets/ I believe there should be a way to export them.
user1447414
  • 1,306
  • 2
  • 12
  • 25
10
votes
1 answer

R Peer certificate cannot be authenticated with given CA certificates, Windows

When trying to import a google sheet using the gs_read() function, I get the following error message: Error in curl::curl_fetch_memory(url, handle = handle) : Peer certificate cannot be authenticated with given CA certificates I am following…
Malan Kriel
  • 301
  • 1
  • 2
  • 17
8
votes
1 answer

How to authenticate users of Shiny apps on shinyapps.io for Google Sheets (googlesheets)

I have a Shiny app making use of the googlesheets package which requires the user to authenticate for writing to Google Sheets (despite the Sheet being public and "published to the web"). This is done graphically in a browser, and works when the…
adatum
  • 655
  • 9
  • 23
7
votes
2 answers

R: googlesheets/gs_upload: Upload to a specific folder

Using the googlesheets package, I am trying to upload a csv to a specific folder in GDrive. Example: ## Not run: write.csv(head(iris, 5), "iris.csv", row.names = FALSE) gs_upload("iris.csv") The above will upload the file to my home directory…
7
votes
1 answer

How to use require(googlesheets) properly?

I recently downloaded googlesheets via devtools::install_github("jennybc/googlesheets") and experience some difficulties. When running the script as mentioned in https://github.com/jennybc/googlesheets I get always: Error: could not…
Mamba
  • 1,183
  • 2
  • 13
  • 33
6
votes
2 answers

How to append new data in googlesheet

I have a below mentioned dataframe in R which I'm fetching from database using RMySQL on interval of 3 hours. Query: Select Form_No, Date, Name, Age from Test where Date(Date)>='2020-12-01'; DF: Form_No Date Name …
Sophia Wilson
  • 581
  • 3
  • 16
5
votes
1 answer

How can I handle the error "Error: all(lengths == 1L | lengths == n) is not TRUE"?

I have been trying to solve this problem, but with no success. Imagine I have a google worksheet called "database". In this worksheet I have a sheet called "Sheet1". And in this sheet I have a table (that starts from A1) with column names "a1",…
Rodrigo Guinea
  • 328
  • 4
  • 16
5
votes
2 answers

Overwrite worksheet using googlesheets in R

I have 2 questions. How do you overwrite a worksheet in an existing spreadsheet using the googlesheets package in R? How do you create a new worksheet in an existing spreadsheet using the googlesheets package in R? I could not find anything in…
Simon
  • 621
  • 4
  • 21
5
votes
0 answers

R Googlesheets package and gs_auth() function - Non interactive auto-refresh stale Token issue

I am running an R script that reads google sheet for every one hour. I am using googlesheets package and gs_auth() function for this. Initially I am storing the token from running gs_auth() with interactive authentication. From next time, the code…
R Bud
  • 261
  • 1
  • 4
  • 16
4
votes
0 answers

Get last update time of a gsheet in R without registering

I am working on a shiny app that creates a live report based on the data of a google spreadsheet. I only want to read the whole gsheet again if there are new values in it. For this, it would be best if I could get the last update time of the gsheet…
4
votes
1 answer

Googlesheets R Error: inherits(ss, "googlesheet") is not TRUE

I am attempting to automatically update a Google Sheets with R. When I run the gs_edit_cells() command I get the error: Error: inherits(ss, "googlesheet") is not TRUE I am not really understanding the error, or at least I might be misunderstanding…
Mike G
  • 533
  • 4
  • 12
4
votes
1 answer

Replace all contents of a googlesheet using R googlesheets package?

Just discovered the googlesheets package and find it very helpful thus far. I would now like to be able to replace all or a subset of the contents in an existing sheet. Example: > library(googlesheets) > set.seed(10) > test1 <-…
msoderstrom
  • 537
  • 1
  • 7
  • 14
4
votes
3 answers

Send information to Google Spreadsheets/Google Form

I want to use Google google spreadsheet or form + spreadsheet to collect a response from an R user and sent it to a speadsheet. Here is a minimal Google form: https://docs.google.com/forms/d/1tz2RPftOLRCQrGSvgJTRELrd9sdIrSZ_kxfoFdHiqD4/viewform And…
Tyler Rinker
  • 108,132
  • 65
  • 322
  • 519
3
votes
1 answer

Googlesheets4 does not read my Spreadsheets

I am using googlesheets4 to store Shiny data. I could reach my googleDrive but I am not able to read any sheet. I also tried "sheet_examples" but I got the same error message, see below. Here is a piece of code that gives the error: I…
3
votes
2 answers

How can I read a Google spreadsheet in a Team Drive in R?

this is probably a really simple question, but I can't seem to figure it out. We recently moved a project from a shared folder on Google Drive to a Team Drive. I used to directly access the spreadsheet from R with this…
user3388408
  • 131
  • 8
1
2 3 4 5