sal_get_metadata: Get a dataset's 'metadata'.

Description Usage Arguments Value Methods (by class) Author(s) References Examples

View source: R/metadata.R

Description

The metadata class is a thin wrapper around a nested list object. It provides a consistent start point to explore information about datasets and safely import them into R.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
sal_get_metadata(x, prioritize_cache = TRUE,
  cache_dir = "~/salinasr-cache")

## S3 method for class 'tbl_df'
sal_get_metadata(x, prioritize_cache = TRUE,
  cache_dir = "~/salinasr-cache")

## S3 method for class 'character'
sal_get_metadata(dataset_id, prioritize_cache = TRUE,
  cache_dir = "~/salinasr-cache")

## S3 method for class 'metadata'
print(x, cache_dir = "~/salinasr-cache")

Arguments

x

character representing a dataset_id or tibble obtained via sal_get_dataset().

prioritize_cache

logical, whether to cache data locally to prevent redundant API calls.

cache_dir

character, path to read/write data.

dataset_id

character, ID used to identify dataset.

Value

metadata object

Methods (by class)

Author(s)

Brendan Knapp brendan.g.knapp@gmail.com

References

https://cityofsalinas.opendatasoft.com/explore/

Examples

1
2
3
4
5
6
7
library(salinasr)

meta <- sal_get_metadata("bikeways")

meta

meta$description

knapply/salinasr documentation built on May 27, 2019, 2:09 p.m.