Hi again.!
As mentioned, i'm back with some beginner-half-stupid-questions.
For writing my paper I do have a problem with getting one csv into the right format.
I use a specific statistics from the german "pks"
Normally it looks like this (year 2018):
But for some reason the year 2020 looks like this:
I tried some fancy stuff like:
header_row <- readLines(file(csv_file, "r", encoding = "latin1"), n = 1)
header_row <- iconv(header_row, to = "UTF-8")
column_names <- strsplit(header_row, ",", fixed = TRUE)[[1]]
data <- read.csv(csv_file, header = FALSE, encoding = "latin1")
data_split <- separate(data, V1, into = column_names, sep = ",")
It kinda works...but not really. So the current best result is:
--
I would love to hear your feedback