View source: R/noegletal_tidy.R
noegletal_tidy | R Documentation |
noegletal_tidy
takes as input a csv-file downloaded from noegletal.dk and
parses it into a tidy tibble::tibble()
. This tibble::tibble()
has one row
for each municipality-year, a muni_code
column, a year
column and a
column for each variable
(as selected on noegletal.dk).
As per the noegletal.dk documentation, cells with a dash -
as a value is
converted to a 0, while cells with a value of M
or U
is converted to
NA
, since these represent missing values.
noegletal_tidy(file)
file |
Path to a csv file downloaded from noegletal.dk. |
A tidy tibble::tibble()
with one row for each municipality-year,
and one column for each included variable (nøgletal).
path_to_file <- system.file("extdata",
"nwRap-10Sep2024-101803.csv",
package = "noegletalR",
mustWork = TRUE)
noegletal_tidy(file = path_to_file)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.