Commit 7b1a34cc authored by Helmer Belbo's avatar Helmer Belbo
Browse files

Adding KPI table to the playground

parent cff92490
......@@ -149,4 +149,21 @@ no.regiontabell.kmn = function(){
regref_fylke <- no.regiontabell.flk()
regref_kommune <- no.regiontabell.kmn()
usethis::use_data(regref_kommune, regref_fylke, overwrite = T)
## KPI
#metadt <- PxWebApiData::ApiData("http://data.ssb.no/api/v0/no/table/08981", returnMetaData = TRUE)
#metadt <- PxWebApiData::ApiData("http://data.ssb.no/api/v0/no/table/03014", returnMetaData = TRUE)
pxdt_t03014 <- PxWebApiData::ApiData("http://data.ssb.no/api/v0/no/table/03014",
Konsumgrp = "TOTAL",
Tid = T,
ContentsCode = "KpiAar")
kpi_t03014 <-
dplyr::as.tbl(pxdt_t03014[[1]]) %>%
dplyr::select(., -konsumgruppe, -statistikkvariabel) %>%
dplyr::rename(., kpi = value)
usethis::use_data(regref_kommune, regref_fylke, kpi_t03014, overwrite = T)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment