-
-
Save abubelinha/55d7b604390526ce4f887e14dae5b228 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(tidyverse) | |
| # 2017 monthly | |
| x <- tempfile("col") | |
| dir.create(x) | |
| download.file("https://download.catalogueoflife.org/col/monthly/2017-02-27_dwca.zip", file.path(x, "dwca.zip")) | |
| unzip(file.path(x, "dwca.zip"), exdir = x) | |
| fs::dir_ls(x) | |
| taxa <- readr::read_tsv(file.path(x, "taxa.txt"), guess_max=1e6, quote="", col_types = readr::cols(.default = "c")) | |
| taxa %>% filter(specificEpithet == "sapiens", taxonomicStatus == "accepted name", genus=="Homo") | |
| taxa %>% filter(taxonID == 3048432) | |
| taxa %>% filter(taxonID == 27703827) | |
| ## 2013 annual | |
| x <- tempfile("col") | |
| dir.create(x) | |
| download.file("https://download.catalogueoflife.org/col/annual/2013_dwca.zip", file.path(x, "dwca.zip")) | |
| unzip(file.path(x, "dwca.zip"), exdir = x) | |
| fs::dir_ls(x) | |
| taxa <- readr::read_tsv(file.path(x, "taxa.txt"), guess_max=1e6, quote="", col_types = readr::cols(.default = "c")) | |
| taxa %>% filter(specificEpithet == "sapiens", taxonomicStatus == "accepted name", genus=="Homo") | |
| taxa %>% filter(taxonID == 3048432) # 2020 | |
| taxa %>% filter(taxonID == 27703827) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment