sal_fetch_catalog.Rd
Fetch catalog of available data sets.
sal_fetch_catalog(rss_url = "https://cityofsalinas.opendatasoft.com/api/v2/catalog/exports/rss")
rss_url |
|
---|
tibble::tibble
data frame with columns:
title
character
, data set title.
dataset_id
character
, data set ID to use in API requests.
pub_date
POSIXct
, date-time published.
description
character
, data set description.
link
character
, URL linking to dataset.
https://cityofsalinas.opendatasoft.com/pages/homepage/
library(salinasr) suppressPackageStartupMessages(library(tidyverse)) catalog <- sal_fetch_catalog() catalog#> # A tibble: 100 x 5 #> title dataset_id pub_date description link #> <chr> <chr> <dttm> <chr> <chr> #> 1 Bikeways bikeways 2018-08-06 09:02:02 This layer depict~ http://cit~ #> 2 Sendas para~ bikeways-es 2018-07-27 09:02:02 Esta capa indica ~ http://cit~ #> 3 Salinas Out~ salinas-out~ 2018-07-18 21:24:12 This dataset cont~ http://cit~ #> 4 Eventos de ~ salinas-out~ 2018-07-18 21:24:12 Este conjunto de ~ http://cit~ #> 5 Oficina de ~ bls-smu0641~ 2018-07-05 21:38:36 Este conjunto de ~ http://cit~ #> 6 Bureau of L~ bls-smu0641~ 2018-07-05 21:38:36 This dataset from~ http://cit~ #> 7 Oficina de ~ bls-smu0600~ 2018-07-05 21:28:13 Este conjunto de ~ http://cit~ #> 8 Bureau of L~ bls-smu0600~ 2018-07-05 21:28:13 This dataset from~ http://cit~ #> 9 BETA de hue~ building-fo~ 2018-07-03 18:47:00 Esta es una versi~ http://cit~ #> 10 Building Fo~ building-fo~ 2018-07-03 18:47:00 This is a beta re~ http://cit~ #> # ... with 90 more rowscatalog %>% glimpse()#> Observations: 100 #> Variables: 5 #> $ title <chr> "Bikeways", "Sendas para bicicletas", "Salinas Outreach... #> $ dataset_id <chr> "bikeways", "bikeways-es", "salinas-outreach-events", "... #> $ pub_date <dttm> 2018-08-06 09:02:02, 2018-07-27 09:02:02, 2018-07-18 2... #> $ description <chr> "This layer depicts the different types of bike paths a... #> $ link <chr> "http://cityofsalinas.opendatasoft.com/explore/dataset/...grocery_stores <- catalog %>% filter(grepl("grocery stores", description)) grocery_stores %>% pull(description)#> [1] "This map depicts the half mile walkability to grocery stores in the City of Salinas, Monterey County, California. This data is presented in the Neighborhood Vibrancy-Urban Greening Plan for the City of Salinas. Areas were calculated using a half mile walk distance to the nearest grocery store. All identified grocery stores were used, however, liquor stores, farmers markets, restaurants, and community gardens were not included."grocery_stores %>% pull(dataset_id)#> [1] "walkability-parks"