Skip to content

Commit

Permalink
Update x00_aemet_stations.Rmd
Browse files Browse the repository at this point in the history
  • Loading branch information
dieghernan authored Mar 18, 2024
1 parent 8fc26d3 commit 777e6bf
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions vignettes/articles/x00_aemet_stations.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ df_init <- aemet_stations()
labs <- esp_codelist %>%
select(cpro, ccaa.shortname.es, prov.shortname.es) %>%
distinct() %>%
select(cpro, ccaa = ccaa.shortname.es, provincia = prov.shortname.es)
select(cpro, provincia = prov.shortname.es)
# Data frame for labels
Expand All @@ -40,7 +40,8 @@ df <- df_init %>%
select(-provincia) %>%
left_join(labs) %>%
select(-cpro) %>%
relocate(ccaa, provincia, .before = 1)
relocate(provincia, .before = 1) %>%
arrange(provincia, nombre)
statns_data <- df %>%
mutate(
Expand Down Expand Up @@ -85,7 +86,7 @@ tbl <- reactable(
searchable = TRUE,
showPageSizeOptions = TRUE,
striped = TRUE,
groupBy = c("ccaa", "provincia"),
groupBy = "provincia",
defaultColDef = colDef(vAlign = "center"),
paginationType = "jump",
elementId = "station-table",
Expand Down

0 comments on commit 777e6bf

Please sign in to comment.