ods_get_csv
returns a dataset from statistics.gov.scot
The dataset
parameter must be passed a valid dataset name (a full list can be obtained by calling ods_all_datasets()
.
Arguments
- dataset
string
. The identifying final part of a URI for a dataset on statistics.gov.scot.
Examples
ods_get_csv("average-household-size")
#> Rows: 693 Columns: 7
#> ── Column specification ────────────────────────────────────────────────────────
#> Delimiter: ","
#> chr (5): FeatureCode, FeatureName, FeatureType, Measurement, Units
#> dbl (2): DateCode, Value
#>
#> ℹ Use `spec()` to retrieve the full column specification for this data.
#> ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
#> # A tibble: 693 × 7
#> FeatureCode FeatureName FeatureType DateCode Measurement Units Value
#> <chr> <chr> <chr> <dbl> <chr> <chr> <dbl>
#> 1 S12000039 West Dunbartonshire Council Area 2019 Ratio Peop… 2.05
#> 2 S12000039 West Dunbartonshire Council Area 2005 Ratio Peop… 2.21
#> 3 S12000039 West Dunbartonshire Council Area 2014 Ratio Peop… 2.1
#> 4 S12000039 West Dunbartonshire Council Area 2004 Ratio Peop… 2.24
#> 5 S12000039 West Dunbartonshire Council Area 2007 Ratio Peop… 2.18
#> 6 S12000039 West Dunbartonshire Council Area 2013 Ratio Peop… 2.12
#> 7 S12000039 West Dunbartonshire Council Area 2006 Ratio Peop… 2.19
#> 8 S12000039 West Dunbartonshire Council Area 2001 Ratio Peop… 2.27
#> 9 S12000039 West Dunbartonshire Council Area 2002 Ratio Peop… 2.27
#> 10 S12000039 West Dunbartonshire Council Area 2017 Ratio Peop… 2.08
#> # ℹ 683 more rows