::: {.cell hash='03_Data_preprocessing_cache/revealjs/unnamed-chunk-71_e3ea27252bdd73e029a76b09ce0a4a86'}

```{.r .cell-code}
# This is the same dataset we used in the assignment
url_education <- "https://ec.europa.eu/eurostat/api/dissemination/sdmx/2.1/data/educ_uoe_grad05?format=tsv" 
# We load it from the file, dealing with the NA encodings we already know of
education_raw <- read_tsv(url_education,na=c(":",": z",": d"))  %>%
  mutate(across(everything(), as.character))
education_raw %>% 
  # Then we pivot the columns for more convenient processing
  pivot_longer(`2022`:`2013`, names_to="year", values_to="value") %>%
  # Once you find the problematic parts of the strings, you can uncomment the 
  # following line to remove the problematic characters
  #   mutate(value = str_remove(value, "d")) %>%
  # Here we keep only the values whose parsing results in a NA
  filter(is.na(as.double(value))) %>%
  # With distinct you remove the duplicates, getting an overview of the problematic values
  distinct(value)
```

::: {.cell-output .cell-output-stdout}
```
# A tibble: 147 × 1
   value 
   <chr> 
 1 <NA>  
 2 3.8 d 
 3 2.0 d 
 4 8.6 d 
 5 7.7 d 
 6 9.3 d 
 7 8.0 d 
 8 21.9 d
 9 27.1 d
10 22.8 d
# ℹ 137 more rows
```
:::
:::