diff --git a/dev/articles/fun-with-googledrive-and-readxl.html b/dev/articles/fun-with-googledrive-and-readxl.html index de7390b57..882aaf5be 100644 --- a/dev/articles/fun-with-googledrive-and-readxl.html +++ b/dev/articles/fun-with-googledrive-and-readxl.html @@ -146,29 +146,29 @@
Put the iris data into a csv file.
(iris_tempfile <- tempfile(pattern = "iris-", fileext = ".csv"))
-#> [1] "/tmp/RtmpR9h3e0/iris-211e1cbf61cd.csv"
+#> [1] "/tmp/RtmpeqVM0r/iris-20d52c61f30b.csv"
write.csv(iris, iris_tempfile, row.names = FALSE)
Use googledrive::drive_upload()
to upload the csv and
simultaneously convert to a Sheet.
(iris_ss <- drive_upload(iris_tempfile, type = "spreadsheet"))
#> Local file:
-#> • /tmp/RtmpR9h3e0/iris-211e1cbf61cd.csv
+#> • /tmp/RtmpeqVM0r/iris-20d52c61f30b.csv
#> Uploaded into Drive file:
-#> • iris-211e1cbf61cd <id: 1A0tNpoDheyQeh4cR0yyZCQaMqSDzTzhmaqlntxaXyK8>
+#> • iris-20d52c61f30b <id: 1hswoBKYtXpIKd-7h4uuOsNoYGlfrAptvcPOP1T9fh8U>
#> With MIME type:
#> • application/vnd.google-apps.spreadsheet
#> # A dribble: 1 × 3
#> name id drive_resource
#> <chr> <drv_id> <list>
-#> 1 iris-211e1cbf61cd 1A0tNpo… <named list [35]>
+#> 1 iris-20d52c61f30b 1hswoBK… <named list [35]>
# visit the new Sheet in the browser, in an interactive session!
drive_browse(iris_ss)
Read data from the private Sheet into R.
read_sheet(iris_ss, range = "B1:D6")
-#> ✔ Reading from iris-211e1cbf61cd.
+#> ✔ Reading from iris-20d52c61f30b.csv.
#> ✔ Range B1:D6.
#> # A tibble: 5 × 3
#> Sepal.Width Petal.Length Petal.Width
@@ -185,12 +185,12 @@ Create a local xlsx
Download the Sheet as an Excel workbook.
(iris_xlsxfile <- sub("[.]csv", ".xlsx", iris_tempfile))
-#> [1] "/tmp/RtmpR9h3e0/iris-211e1cbf61cd.xlsx"
+#> [1] "/tmp/RtmpeqVM0r/iris-20d52c61f30b.xlsx"
drive_download(iris_ss, path = iris_xlsxfile, overwrite = TRUE)
#> File downloaded:
-#> • iris-211e1cbf61cd <id: 1A0tNpoDheyQeh4cR0yyZCQaMqSDzTzhmaqlntxaXyK8>
+#> • iris-20d52c61f30b <id: 1hswoBKYtXpIKd-7h4uuOsNoYGlfrAptvcPOP1T9fh8U>
#> Saved locally as:
-#> • /tmp/RtmpR9h3e0/iris-211e1cbf61cd.xlsx
+#> • /tmp/RtmpeqVM0r/iris-20d52c61f30b.xlsx
googledrive::drive_trash(ss)
#> File trashed:
-#> • unfearing-guineafowl <id: 1MByFbW0vtmpXh8b78BLFuYS81Ax_nFvdSZ-6Ps7V6Nc>
+#> • unfearing-guineafowl <id: 1R8ACw6FTsVQ7oqhB0q6-nYDjnTJ5rJqRLsYHHHEhPd8>
ss <- gs4_create("testy-hedgehog", sheets = df)
#> ✔ Creating new Sheet: testy-hedgehog.
@@ -314,7 +314,7 @@ Writing Sheets#>
#> ── <googlesheets4_spreadsheet> ───────────────────────────────────────────
#> Spreadsheet name: testy-hedgehog
-#> ID: 1sWSntIYPAAphYgAHbv8PQV_Z8AMnjnDUVHScI8RiUhs
+#> ID: 1vdy1nal4E0AOHKi9Ls0cNSS3Q1VR5NvnLUVbLBbCtIU
#> Locale: en_US
#> Time zone: Etc/GMT
#> # of sheets: 1
@@ -333,7 +333,7 @@ Writing Sheets#>
#> ── <googlesheets4_spreadsheet> ───────────────────────────────────────────
#> Spreadsheet name: testy-hedgehog
-#> ID: 1sWSntIYPAAphYgAHbv8PQV_Z8AMnjnDUVHScI8RiUhs
+#> ID: 1vdy1nal4E0AOHKi9Ls0cNSS3Q1VR5NvnLUVbLBbCtIU
#> Locale: en_US
#> Time zone: Etc/GMT
#> # of sheets: 2
@@ -394,12 +394,12 @@ Writing Sheets#> # A tibble: 2 × 8
#> name index id type visible grid_rows grid_columns data
#> <chr> <int> <int> <chr> <lgl> <int> <int> <list>
-#> 1 df 0 320665393 GRID TRUE 9 2 <NULL>
-#> 2 chickwts 1 2056489015 GRID TRUE 72 2 <NULL>
+#> 1 df 0 1907645848 GRID TRUE 9 2 <NULL>
+#> 2 chickwts 1 1182564790 GRID TRUE 72 2 <NULL>
googledrive::drive_trash(ss)
#> File trashed:
-#> • testy-hedgehog <id: 1sWSntIYPAAphYgAHbv8PQV_Z8AMnjnDUVHScI8RiUhs>
+#> • testy-hedgehog <id: 1vdy1nal4E0AOHKi9Ls0cNSS3Q1VR5NvnLUVbLBbCtIU>
The article Write Sheets has even more detail.
diff --git a/dev/articles/read-sheets.html b/dev/articles/read-sheets.html index 62801872c..7dd3b87c5 100644 --- a/dev/articles/read-sheets.html +++ b/dev/articles/read-sheets.html @@ -439,14 +439,14 @@The modest difference above shows that the speed difference is unlikely to be a gamechanger in many settings.
Summary of how to think about range_speedread()
vs
diff --git a/dev/articles/write-sheets.html b/dev/articles/write-sheets.html
index 71e2a15fa..106159274 100644
--- a/dev/articles/write-sheets.html
+++ b/dev/articles/write-sheets.html
@@ -188,7 +188,7 @@
googledrive::drive_trash(random_ss)
#> File trashed:
-#> • unfearing-guineafowl <id: 18l_Pp_URJbZQxVpTQYOTLCx5oJ5eDoqAj7cCMiqFaOI>
+#> • unfearing-guineafowl <id: 14mw8ELrtGQld2vpkPbuwKW4HBa_QaD5-zSSjhiZg8gs>
ss1 <- gs4_create(
"write-sheets-demo-1",
@@ -387,7 +387,7 @@
#>
#> ── <googlesheets4_spreadsheet> ───────────────────────────────────────────
#> Spreadsheet name: write-sheets-demo-1
-#> ID: 1eo7swPHh4YtgAgFnXHtVyNQd0QNyl9N6N2qnbuxXwu4
+#> ID: 1dw0VMl_Avs0cgbFbafWilPeoEw3xz3a1sAG1Wfc3iuE
#> Locale: en_US
#> Time zone: Etc/GMT
#> # of sheets: 1
@@ -405,7 +405,7 @@
#>
#> ── <googlesheets4_spreadsheet> ───────────────────────────────────────────
#> Spreadsheet name: write-sheets-demo-1
-#> ID: 1eo7swPHh4YtgAgFnXHtVyNQd0QNyl9N6N2qnbuxXwu4
+#> ID: 1dw0VMl_Avs0cgbFbafWilPeoEw3xz3a1sAG1Wfc3iuE
#> Locale: en_US
#> Time zone: Etc/GMT
#> # of sheets: 1
@@ -437,7 +437,7 @@
#>
#> ── <googlesheets4_spreadsheet> ───────────────────────────────────────────
#> Spreadsheet name: write-sheets-demo-1
-#> ID: 1eo7swPHh4YtgAgFnXHtVyNQd0QNyl9N6N2qnbuxXwu4
+#> ID: 1dw0VMl_Avs0cgbFbafWilPeoEw3xz3a1sAG1Wfc3iuE
#> Locale: en_US
#> Time zone: Etc/GMT
#> # of sheets: 4
@@ -455,7 +455,7 @@ Clean upgs4_find("write-sheets-demo") %>%
googledrive::drive_trash()
#> File trashed:
-#> • write-sheets-demo-1 <id: 1eo7swPHh4YtgAgFnXHtVyNQd0QNyl9N6N2qnbuxXwu4>