NSRR All Dataset files

nsrr_all_dataset_files(dataset, token = nsrr_token(), max_files = Inf)

Arguments

dataset

a dataset "slug", one from nsrr_datasets

token

Token for NSRR resources. Found at https://sleepdata.org/token

max_files

maximum files to return if not wanting to go through all folders recursively.

Value

A data.frame of the data sets and their endpoints

Examples

dataset = "shhs"
df = nsrr_all_dataset_files(dataset, max_files = 10)
#> [1] "biostatistics-with-r"
#> [1] "datasets"
testthat::expect_lte(nrow(df), 20)
# keep as donttest - takes a long time
# \donttest{
df = nsrr_all_dataset_files(dataset)
#> [1] "biostatistics-with-r"
#> [1] "datasets"
#> [1] "documentation"
#> [1] "forms"
#> [1] "polysomnography"
#> [1] "datasets/archive"
#> [1] "datasets/hrv-analysis"
#> [1] "forms/shhs1"
#> [1] "forms/shhs2"
#> [1] "polysomnography/annotations-events-nsrr"
#> [1] "polysomnography/annotations-events-profusion"
#> [1] "polysomnography/annotations-rpoints"
#> [1] "polysomnography/edfs"
#> [1] "datasets/archive/0.10.0"
#> [1] "datasets/archive/0.10.1"
#> [1] "datasets/archive/0.11.0"
#> [1] "datasets/archive/0.11.1"
#> [1] "datasets/archive/0.12.0"
#> [1] "datasets/archive/0.13.0"
#> [1] "datasets/archive/0.13.1"
#> [1] "datasets/archive/0.13.2"
#> [1] "datasets/archive/0.14.0"
#> [1] "datasets/archive/0.15.0"
#> [1] "datasets/archive/0.2.0"
#> [1] "datasets/archive/0.2.1"
#> [1] "datasets/archive/0.4.0"
#> [1] "datasets/archive/0.4.5"
#> [1] "datasets/archive/0.5.0"
#> [1] "datasets/archive/0.5.1"
#> [1] "datasets/archive/0.6.0"
#> [1] "datasets/archive/0.6.1"
#> [1] "datasets/archive/0.7.0"
#> [1] "datasets/archive/0.7.1"
#> [1] "datasets/archive/0.8.0"
#> [1] "datasets/archive/0.8.1"
#> [1] "datasets/archive/0.8.2"
#> [1] "datasets/archive/0.9.0"
#> [1] "polysomnography/annotations-events-nsrr/shhs1"
#> [1] "polysomnography/annotations-events-nsrr/shhs2"
#> [1] "polysomnography/annotations-events-profusion/shhs1"
#> [1] "polysomnography/annotations-events-profusion/shhs2"
#> [1] "polysomnography/annotations-rpoints/shhs1"
#> [1] "polysomnography/annotations-rpoints/shhs2"
#> [1] "polysomnography/edfs/shhs1"
#> [1] "polysomnography/edfs/shhs2"
#> [1] "datasets/archive/0.10.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.10.0/hrv-analysis"
#> [1] "datasets/archive/0.10.1/eeg-spectral-analysis"
#> [1] "datasets/archive/0.10.1/hrv-analysis"
#> [1] "datasets/archive/0.11.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.11.0/hrv-analysis"
#> [1] "datasets/archive/0.11.1/eeg-spectral-analysis"
#> [1] "datasets/archive/0.11.1/hrv-analysis"
#> [1] "datasets/archive/0.12.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.12.0/hrv-analysis"
#> [1] "datasets/archive/0.13.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.13.0/hrv-analysis"
#> [1] "datasets/archive/0.13.1/eeg-spectral-analysis"
#> [1] "datasets/archive/0.13.1/hrv-analysis"
#> [1] "datasets/archive/0.13.2/eeg-spectral-analysis"
#> [1] "datasets/archive/0.13.2/hrv-analysis"
#> [1] "datasets/archive/0.14.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.14.0/hrv-analysis"
#> [1] "datasets/archive/0.15.0/hrv-analysis"
#> [1] "datasets/archive/0.7.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.7.1/eeg-spectral-analysis"
#> [1] "datasets/archive/0.8.0/eeg-spectral-analysis"
#> [1] "datasets/archive/0.8.1/eeg-spectral-analysis"
#> [1] "datasets/archive/0.8.2/eeg-spectral-analysis"
#> [1] "datasets/archive/0.9.0/eeg-spectral-analysis"
# }