Back


Goal 4: Quality Education

Children in day care, 3-5 years


FN 4.2.2 Number of children in day care (3-5 years)
# Import
OFXUKN1_raw <-
  statgl_url("OFXUKN1", lang = language) %>% 
  statgl_fetch(
    born_var   = 3:5,
    inst_type2 = 1:5,
    .col_code  = TRUE
    ) %>% 
  as_tibble()

# Transform
OFXUKN1 <-
  OFXUKN1_raw %>% 
  mutate(across(where(is.integer), ~ if_else(is.na(.x), 0, .x))) |> 
  summarise(value = sum(value), .by = c(inst_type2, aar)) |> 
  mutate(
    aar = aar %>% make_date(),
    inst_type2 = inst_type2 %>% fct_inorder(),
    alder = "Børn 3-5 år"
    )

# Plot
OFXUKN1 %>% 
  ggplot(aes(
    x    = aar,
    y    = value,
    fill = inst_type2
  )) +
  geom_col() +
  scale_y_continuous(labels = scales::unit_format(
    suffix       = " ",
    big.mark     = ".",
    decimal.mark = ","
  )) +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = FALSE, nrow = 2)) +
  labs(
    title    = sdg4$figs$fig1$title[language],
    subtitle = OFXUKN1[[4]][1],
    x        = " ",
    y        = sdg4$figs$fig1$y_lab[language],
    fill     = " ",
    caption  = sdg4$figs$fig1$cap[language]
  )

StatBank


# Transform
OFXUKN1 <-
  OFXUKN1_raw %>% 
  #arrange(desc(time)) %>% 
  filter(aar >= year(Sys.time()) - 5) %>% 
  mutate(across(where(is.integer), ~ if_else(is.na(.x), 0, .x))) |> 
  summarise(value = sum(value), .by = c(inst_type2, aar)) |> 
  mutate(
    aar = aar %>% factor(levels = unique(aar)),
    inst_type2 = inst_type2 %>% fct_inorder(),
    alder = "Børn 3-5 år"
    ) %>% 
  spread(aar, value)

# Table
OFXUKN1 %>% 
  select(-2) %>% 
  rename(" " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  pack_rows(index = table(OFXUKN1[[2]])) %>% 
  add_footnote(
    sdg4$figs$fig1$foot[language], 
    notation = "symbol"
    )
2020 2021 2022 2023 2024
Børn 3-5 år
Nursery 52 102 149 189 151
Childcare 1.917 1.943 1.876 1.869 1.895
Intergrated daycare 19 21 27 10 4
Childminding 104 120 114 115 130
Other Daycare 6 9 5 18 3
* Number of children in day care
# Import
OFXUKN1_raw <-
  statgl_url("OFXUKN1", lang = language) %>% 
  statgl_fetch(
    born_var   = 3:5,
    inst_type2 = 1:5,
    bosted     = 1:2,
    .col_code  = TRUE
    ) %>% 
  as_tibble()

# Transform
OFXUKN1 <-
  OFXUKN1_raw %>% 
  mutate(
    inst_type2 = inst_type2 %>% fct_inorder(),
    bosted  = bosted %>% fct_inorder(),
    aar = aar %>% make_date(),
    born_var = "Børn 3-5 år",
    across(where(is.integer), ~ if_else(is.na(.x), 0, .x))
    ) |> 
  summarise(value = sum(value), .by = c(inst_type2, born_var, bosted, aar))

# Plot
OFXUKN1 %>% 
  ggplot(aes(
    x    = aar,
    y    = value,
    fill = inst_type2
    )) +
  geom_col() +
  facet_wrap(~ bosted, scales = "free_y") +
  theme_statgl() +
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = FALSE, nrow = 2)) +
  labs(
    title    = sdg4$figs$fig2$title[language],
    subtitle = OFXUKN1[[2]][1],
    x        = " ",
    y        = sdg4$figs$fig2$y_lab[language],
    fill     = NULL,
    caption  = sdg4$figs$fig2$cap[language]
  )

StatBank

# Transform
OFXUKN1 <- 
  OFXUKN1_raw %>% 
  mutate(born_var = "Børn 3-5 år",
    across(where(is.integer), ~ if_else(is.na(.x), 0, .x))) |> 
  #arrange(desc(time)) %>%
  summarise(value = sum(value), .by = c(inst_type2, born_var, bosted, aar)) |> 
  filter(aar >= year(Sys.time()) - 5) %>% 
  mutate(aar = aar %>% factor(levels = unique(aar))) %>% 
  spread(aar, value) |> 
  arrange(bosted)

# Table
OFXUKN1 %>% 
  select(-c(2, 3)) %>% 
  rename(" " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  pack_rows(index = table(OFXUKN1[[2]])) %>% 
  pack_rows(index = table(OFXUKN1[[3]])) %>% 
  add_footnote(
    sdg4$figs$fig2$foot[language], 
    notation = "symbol"
    )
2020 2021 2022 2023 2024
Børn 3-5 år
Settlement
Childcare 61 58 61 79 62
Childminding 94 109 97 106 123
Intergrated daycare 19 21 27 10 4
Nursery 5 8 16 11 11
Other Daycare 0 0 0 0 0
Town
Childcare 1.856 1.885 1.815 1.790 1.833
Childminding 10 11 17 9 7
Intergrated daycare 0 0 0 0 0
Nursery 47 94 133 178 140
Other Daycare 6 9 5 18 3
* Number of children in day care

Grade test results


FN 4.1.1 Problem-solving proficienty (pct. correct) in grade test results for children in 3rd and 7th grade (lower-secondary school)
# Import
UDXTKB_raw <-
  statgl_url("UDXTKB", lang = language) %>%
  statgl_fetch(
    subject   = px_all(),
    grade     = c(3, 7),
    unit      = "B",
    .col_code = TRUE) %>% 
  as_tibble()

# Transform
UDXTKB <-
  UDXTKB_raw %>% 
  mutate(
    time     = time %>% make_date(),
     subject =  subject %>% fct_inorder()
    )

# Plot
UDXTKB %>% 
  ggplot(aes(
    x     = time,
    y     = value,
    color = subject
    )) +
  geom_line(size = 2) +
  facet_wrap(~ grade) +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 1, 
    accuracy     = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl() + 
  scale_color_statgl() +
  labs(
    title    = sdg4$figs$fig3$title[language],
    subtitle = UDXTKB[[3]][1],
    x        = " ",
    y        = " ",
    color    = sdg4$figs$fig3$color[language],
    caption  = sdg4$figs$fig3$cap[language]
  )

StatBank

Method


# Transform
UDXTKB <- 
  UDXTKB_raw %>% 
  arrange(desc(time)) %>% 
  filter(time >= year(Sys.time()) - 5) %>% 
  mutate(time = time %>% factor(levels = unique(time))) %>% 
  arrange(grade, desc(subject)) %>% 
  unite(combi, 1, 2, sep = ",") %>% 
  mutate(combi = combi %>% factor(levels = unique(combi))) %>% 
  spread(1, ncol(.))

vec      <- UDXTKB %>% select(-(1:2)) %>% colnames() %>% str_split(",") %>% unlist()
head_vec <- table(vec[c(F, T)])
col_vec  <- vec[c(T, F)]

# Table
UDXTKB %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(col.names = c(" ", col_vec)) %>% 
  add_header_above(c(" ", head_vec)) %>% 
  pack_rows(index = table(UDXTKB[[1]]))
3rd grade
7th grade
Mathematics,3rd grade Greenlandic,3rd grade English,3rd grade Danish,3rd grade Mathematics,7th grade Greenlandic,7th grade English,7th grade Danish,7th grade
Problem-solving proficiency (pct. correct)
2024 49 45 NA 41 40 56 84 42
2023 52 48 NA 48 41 59 86 45
2022 48 41 NA 41 41 62 82 51
2021 51 48 NA 47 40 61 73 50
2020 51 41 NA 50 41 61 73 57



# Import
UDXTKB_raw <-
  statgl_url("UDXTKB", lang = language) %>%
  statgl_fetch(
    subject              = px_all(),
    grade                = c(3, 7),
    unit                 = "B",
    "place of residence" = 1:2,
    .col_code            = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXTKB <-
  UDXTKB_raw %>% 
  mutate(
    time = time %>% make_date(),
    `place of residence` = `place of residence` %>% fct_inorder(),
    subject = subject %>% fct_inorder()
    )

# Plot
UDXTKB %>% 
  ggplot(aes(
    x     = time,
    y     = value,
    color = subject
  )) +
  geom_line(size = 2) +
  facet_grid(grade ~ `place of residence`) +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 1, 
    accuracy     = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl() + 
  scale_color_statgl() +
  labs(
    title    = sdg4$figs$figX$title_fig4,
    subtitle = UDXTKB[[4]][1],
    x        = " ",
    y        = " ",
    color    = sdg4$figs$fig4$color[language],
    caption  = sdg4$figs$fig4$cap[language]
  )

StatBank

Method


# Transform
UDXTKB <- 
  UDXTKB_raw %>% 
  arrange(desc(time)) %>% 
  filter(time >= year(Sys.time()) - 5) %>% 
  mutate(time = time %>% fct_inorder()) %>% 
  arrange(grade, subject) %>% 
  unite(combi, 1, 2, 3, sep = ",") %>% 
  mutate(combi = combi %>% factor(levels = unique(combi))) %>% 
  spread(1, 4) 

vec       <- UDXTKB[-(1:2)] %>% colnames() %>% str_split(",") %>% unlist()
head_vec1 <- rep(vec[c(F, T, F)][1:8] %>% table(), 2)
head_vec2 <- vec[c(F, F, T)] %>% table()
col_vec   <- vec[c(T, F, F)]

UDXTKB %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(col.names = c(" ", col_vec)) %>% 
  add_header_above(c(" ", head_vec1)) %>% 
  add_header_above(c(" ", head_vec2)) %>% 
  pack_rows(index = table(UDXTKB[[1]]))
3rd grade
7th grade
Danish
English
Greenlandic
Mathematics
Danish
English
Greenlandic
Mathematics
Town,Danish,3rd grade Settlement,Danish,3rd grade Town,English,3rd grade Settlement,English,3rd grade Town,Greenlandic,3rd grade Settlement,Greenlandic,3rd grade Town,Mathematics,3rd grade Settlement,Mathematics,3rd grade Town,Danish,7th grade Settlement,Danish,7th grade Town,English,7th grade Settlement,English,7th grade Town,Greenlandic,7th grade Settlement,Greenlandic,7th grade Town,Mathematics,7th grade Settlement,Mathematics,7th grade
Problem-solving proficiency (pct. correct)
2024 42 38 NA NA 43 48 48 56 45 34 86 55 55 57 39 40
2023 50 36 NA NA 48 49 53 45 47 40 88 73 57 66 43 40
2022 41 43 NA NA 41 52 47 52 54 40 86 53 62 61 41 39
2021 48 39 NA NA 48 47 52 50 52 45 76 54 59 62 40 41
2020 50 52 NA NA 41 57 50 51 59 43 78 41 61 62 42 37



Final examination - lower secondary education


GS Marks for pupils in lower secondary education
# Import
UDXFKK_raw <-
  statgl_url("UDXFKK", lang = language) %>% 
  statgl_fetch(
    unit             = "andel",
    grade            = "FO",
    subject          = c("01", "02", "03", "04"),
    "type of grades" = 56:58,
    .col_code        = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXFKK <-
  UDXFKK_raw %>% 
  mutate(
    `type of grades` = `type of grades` %>% str_remove_all("Prøvekarakter -") %>% trimws() %>% str_to_title(),
    subject          = subject %>% fct_inorder(),
    time             = time %>% make_date()
    )

# Plot
UDXFKK %>% 
  ggplot(aes(
    x     = time,
    y     = value,
    color = `type of grades`
    )) +
  geom_line(size = 2) +
  facet_wrap( ~ subject, ncol = 2) +
  theme_statgl() + 
  scale_color_statgl(guide = guide_legend(nrow = 3)) +
  labs(
    title   = sdg4$figs$fig5$title[language],
    color   = sdg4$figs$fig5$color[language],
    x       = " ",
    y       = sdg4$figs$fig5$y_lab[language],
    caption = sdg4$figs$fig5$cap[language]
  )

StatBank

Method


# Transform
UDXFKK <-
  UDXFKK_raw %>% 
  mutate(
    `type of grades` = `type of grades` %>% 
      str_remove_all("Prøvekarakter -") %>%
      trimws() %>%
      str_to_title()
    ) %>% 
  #arrange(desc(time)) %>% 
  filter(
    value != "NA",
    time >= year(Sys.time()) - 5
    ) %>% 
  mutate(
    subject = subject %>% fct_inorder(),
    time = time %>% factor(levels = unique(time)),
    ) %>% 
  spread(5, 6) %>% 
  arrange(subject)

# Table
UDXFKK %>% 
  select(-(1:3)) %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  pack_rows(index = table(UDXFKK[[1]] %>% str_to_title())) %>% 
  pack_rows(index = table(UDXFKK[[3]])) %>% 
  add_footnote(UDXFKK[[2]][1], notation = "symbol")
2021 2022 2023 2024
Grade Point Average
Greenlandic
Mark - Oral 5,96 6,81 6,54 6,80
Mark - Proficiency Test 3,56 3,72 3,99 4,86
Mark - Written 5,35 5,48 4,75 5,30
Danish
Mark - Oral 5,36 4,85 6,15 4,63
Mark - Proficiency Test 4,47 4,14 4,05 3,70
Mark - Written 3,36 3,58 3,82 3,18
Mathematics
Mark - Oral 4,88 5,24 5,58 5,60
Mark - Proficiency Test 4,94 4,89 4,82 4,81
Mark - Written 2,17 2,52 2,98 2,48
English
Mark - Oral 6,49 6,52 6,99 7,55
Mark - Proficiency Test 4,90 5,20 5,56 5,63
Mark - Written 4,11 4,51 4,56 5,34
* School leavers - lower secondary education


Due to Covid-19 there has not been held final exams in 2020.



Transition from lower secondary education to further education


GS Transition from lower secondary education to upper secondary education
# Import
UDXTRFA1_raw <-
  statgl_url("UDXTRFA1", lang = language) %>% 
  statgl_fetch(
    aar       = 2,
    status    = px_all(),
    dim_aar   = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXTRFA1 <-
  UDXTRFA1_raw %>%
  filter(dim_aar <= year(Sys.time()) - 3) %>% 
  mutate(dim_aar = dim_aar %>% make_date())

  


# Plot
UDXTRFA1 %>% 
  ggplot(aes(
    x    = dim_aar,
    y    = value,
    fill = status
  )) +
  geom_col(position = "fill") +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 100, 
    accuracy     = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  scale_fill_statgl(reverse = TRUE) +
  theme_statgl() +
  labs(
    title    = sdg4$figs$fig6$title[language],
    subtitle = sdg4$figs$fig6$sub[language],
    x        = sdg4$figs$fig6$x_lab[language],
    y        = " ",
    fill     = sdg4$figs$fig6$fill[language],
    caption  = sdg4$figs$fig6$cap[language]
  )

StatBank

Method


# Transform
UDXTRFA1 <- 
  UDXTRFA1_raw %>% 
  filter(dim_aar <= year(Sys.time()) - 3) %>% 
  #arrange(desc(`graduation year`)) %>% 
  filter(dim_aar >= year(Sys.time()) - 8) %>% 
  mutate(dim_aar = dim_aar %>% factor(levels = unique(dim_aar))) %>% 
  spread(3, 4)

# Table
UDXTRFA1 %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  add_footnote(
    sdg4$figs$fig6$foot[language],
    notation = "symbol"
  )
2017 2018 2019 2020 2021 2022
Dropped out 117 108 82 96 97 116
Graduated 4 7 5 7 3 6
In education 264 243 250 269 252 226
Not enrolled in education 301 340 311 312 357 330
* Number of people - transition from lower secondary education to upper secondary education (2 years after graduation)



# Import
UDXTRFA1_raw <-
  statgl_url("UDXTRFA1", lang = language) %>% 
  statgl_fetch(
    aar       = 2,
    status    = px_all(),
    dim_aar   = px_all(),
    sex       = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXTRFA1 <-
  UDXTRFA1_raw %>% 
  filter(dim_aar <= year(Sys.time()) - 3) %>% 
  mutate(dim_aar = dim_aar %>% make_date())

# Plot
UDXTRFA1 %>% 
  ggplot(aes(
    x    = dim_aar,
    y    = value,
    fill = status
  )) +
  geom_col(position = "fill") +
  facet_wrap(~ sex) +
  scale_y_continuous(labels  = scales::percent_format()) +
  scale_fill_statgl(reverse = TRUE) +
  theme_statgl() +
  labs(
    title    = sdg4$figs$fig7$title[language],
    subtitle = sdg4$figs$fig7$sub[language],
    x        = sdg4$figs$fig7$x_lab[language],
    y        = " ",
    fill     = sdg4$figs$fig7$fill[language],
    caption  = sdg4$figs$fig7$cap[language]
  )

StatBank

Method


# Transform
UDXTRFA1 <- 
  UDXTRFA1_raw %>% 
  filter(dim_aar <= year(Sys.time()) - 3) %>% 
  #arrange(desc(`graduation year`)) %>% 
  filter(dim_aar >= year(Sys.time()) - 8) %>% 
  mutate(dim_aar = dim_aar %>% factor(levels = unique(dim_aar))) %>% 
  spread(4, 5) %>% 
  arrange(status)
  
# Table
UDXTRFA1 %>% 
  select(-1, -3) %>% 
  rename(" " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  pack_rows(index = table(UDXTRFA1[[3]])) %>% 
  add_footnote(
    sdg4$figs$fig7$foot[language],
    notation = "symbol"
  )
2017 2018 2019 2020 2021 2022
Dropped out
Men 53 45 45 45 44 45
Women 64 63 37 51 53 71
Graduated
Men 3 7 3 7 2 6
Women 1 0 2 0 1 0
In education
Men 111 101 102 119 111 94
Women 153 142 148 150 141 132
Not enrolled in education
Men 153 171 174 170 181 169
Women 148 169 137 142 176 161
* Number of people - transition from lower secondary education to upper secondary education (2 years after graduation)



Transition from upper secondary school to further education


GS Transition from upper secondary education to further education
# Import
UDXTRGU2_raw <-
  statgl_url("UDXTRGU2", lang = language) %>% 
  statgl_fetch(
    aar     = 2,
    status  = px_all(),
    dim_aar = px_all(),
    .col_code = TRUE) %>% 
  as_tibble()

# Transform
UDXTRGU2 <-
  UDXTRGU2_raw %>% 
  filter(dim_aar <= year(Sys.time()) - 2) |> 
  mutate(dim_aar = dim_aar %>% make_date())

# Plot
UDXTRGU2 %>% 
  ggplot(aes(
    x    = dim_aar,
    y    = value,
    fill = status
    )) +
  geom_col(position = "fill") +
  scale_y_continuous(labels  = scales::percent_format(
    scale = 100, 
    accuracy = 1, 
    big.mark = ".",
    decimal.mark = ","
    )) +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE) +
  labs(
    title    = sdg4$figs$fig8$title[language],
    subtitle = sdg4$figs$fig8$sub[language],
    x        = sdg4$figs$fig8$x_lab[language],
    y        = " ",
    fill     = sdg4$figs$fig8$fill[language],
    caption  = sdg4$figs$fig8$cap[language]
  )

StatBank

Method


# Transform
UDXTRGU2 <-
  UDXTRGU2_raw %>% 
  filter(dim_aar >= year(Sys.time()) - 9 & dim_aar < year(Sys.time()) - 3) %>% 
  mutate(dim_aar = dim_aar %>% factor(levels = unique(dim_aar))) %>% 
  spread(3, 4)

# Table
UDXTRGU2 %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  add_footnote(
    sdg4$figs$fig8$foot[language],
    notation = "symbol"
    )
2016 2017 2018 2019 2020 2021
Dropped out 69 61 46 50 54 67
Graduated 28 29 32 35 36 26
In education 157 134 137 131 112 124
not enrolled in education 91 104 89 87 93 95
* Number of people - transition from lower secondary education to further education (2 years after graduation)



# Import
UDXTRGU2_raw <-
  statgl_url("UDXTRGU2", lang = language) %>% 
  statgl_fetch(
    aar       = 2,
    status    = px_all(),
    dim_aar   = px_all(),
    sex       = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXTRGU2 <- 
  UDXTRGU2_raw %>% 
  filter(dim_aar <= year(Sys.time()) - 3) |> 
  mutate(dim_aar = dim_aar %>% make_date())

# Plot
UDXTRGU2 %>% 
  ggplot(aes(
    x    = dim_aar,
    y    = value,
    fill = status
  )) +
  geom_col(position = "fill") +
  facet_wrap( ~ sex) +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 100, 
    accuracy     = 1,
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE) +
  labs(
    title    = sdg4$figs$fig9$title[language],
    subtitle = sdg4$figs$fig9$sub[language],
    x        = sdg4$figs$fig9$x_lab[language],
    y        = " ",
    fill     = sdg4$figs$fig9$fill[language],
    caption  = sdg4$figs$fig9$cap[language]
  )

StatBank

Method


# Transform
UDXTRGU2 <-
  UDXTRGU2_raw %>% 
  #arrange(desc(`graduation year`)) %>% 
  filter(dim_aar >= year(Sys.time()) - 8 & dim_aar < year(Sys.time()) - 3) %>% 
  mutate(dim_aar = dim_aar %>% factor(levels = unique(dim_aar))) %>% 
  spread(4, 5) %>% 
  arrange(status)

# Table
UDXTRGU2 %>% 
  select(-c(1, 3)) %>% 
  rename("  " = 1) %>% 
  statgl_table(replace_0s = TRUE) %>% 
  pack_rows(index = UDXTRGU2[[3]] %>% table()) %>% 
  add_footnote(
    sdg4$figs$fig9$foot[language],
    notation = "symbol"
  )
2017 2018 2019 2020 2021
Dropped out
Men 22 13 16 23 21
Women 39 33 34 31 46
Graduated
Men 10 13 9 12 12
Women 19 19 26 24 14
In education
Men 61 52 49 32 33
Women 73 85 82 80 91
not enrolled in education
Men 51 38 49 44 37
Women 53 51 38 49 58
* Number of people - transition from upper secondary education to further education (2 years after graduation)

Number of students


GS Number of students by level of education and country
# Import
UDXISC11B_raw <-
  statgl_url("UDXISC11B", lang = language) %>% 
  statgl_fetch(
    isced = px_all(),
    .col_code            = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXISC11B <-
  UDXISC11B_raw %>% 
  mutate(taar = taar %>% make_date(),
        isced = isced %>%  fct_inorder() %>% fct_rev(),
        value = value * 10^-3)

# Plot
UDXISC11B %>% 
  ggplot(aes(
    x    = taar,
    y    = value,
    fill = isced
  )) +
  geom_col() +
   guides(fill = guide_legend(nrow = 4, byrow = TRUE)) +
  theme_statgl() +
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = FALSE)) +
  labs(
    title   = sdg4$figs$fig10$title[language],
    x       = " ",
    y       = sdg4$figs$fig10$y_lab[language],
    fill    = NULL,
    caption = sdg4$figs$fig10$cap[language]
  )

StatBank


# Transform
UDXISC11B <-
  UDXISC11B_raw %>% 
  #arrange(desc(time)) %>% 
  filter(taar >= year(Sys.time()) - 6) %>% 
  mutate(
         isced = isced %>% factor(levels = unique(isced)),
         taar  = taar %>% factor(levels = unique(taar)),
         ) %>% 
  spread(2, 3)

# Table
UDXISC11B %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  add_footnote(
    sdg4$figs$fig10$foot[language],
    notation = "symbol"
    )
2019 2020 2021 2022 2023 2024
Upper secondary education 1.120 1.170 1.161 1.129 1.064 1.071
Vocational education and training 1.087 1.136 1.025 1.001 921 876
Supplementary examination courses 29 29 14 19 22 26
Short-cycle higher education 186 167 155 162 155 162
Bachelors programme 323 373 359 346 333 353
Professional bachelors programme 561 550 527 528 511 528
Masters programme 182 170 165 155 154 150
* Number of active students



# Import
UDXISC11B_raw <-
  statgl_url("UDXISC11B", lang = language) %>% 
  statgl_fetch(
    skoleomr   = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Translate
UDXISC11B <-
  UDXISC11B_raw %>% 
  mutate(
    taar     = taar %>% make_date(),
    skoleomr = skoleomr %>% fct_reorder(value),
    value    = value * 10^-3
    )

# Plot
UDXISC11B %>% 
  ggplot(aes(
    x    = taar,
    y    = value,
    fill = skoleomr
  )) +
  geom_col() +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = TRUE)) +
  labs(
    title   = sdg4$figs$fig11$title[language],
    x       = " ",
    y       = sdg4$figs$fig11$y_lab[language],
    fill    = " ",
    caption = sdg4$figs$fig11$cap[language] 
  )

StatBank


# Transform
UDXISC11B <-
  UDXISC11B_raw %>% 
  #arrange(desc(time)) %>% 
  filter(taar >= year(Sys.time()) - 6) %>% 
  mutate(
    taar    = taar %>% fct_inorder(),
    skoleomr = skoleomr %>% fct_inorder
    ) %>% 
  spread(2, 3)

# Table
UDXISC11B %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  add_footnote(
    sdg4$figs$fig11$foot[language],
    notation = "symbol"
    )
2019 2020 2021 2022 2023 2024
Schools in Greenland 2.945 3.061 2.922 2.806 2.638 2.580
Schools in Denmark 518 510 464 512 506 569
Schools abroad 25 24 20 22 16 17
* Number of students



FN 4.3.1 Number of students by gender
# Import
UDXISC11B_raw <-
  statgl_url("UDXISC11B", lang = language) %>% 
  statgl_fetch(
    sex       = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXISC11B <-
  UDXISC11B_raw %>% 
  mutate(
    taar  = taar %>% make_date(),
    sex   = sex %>% reorder(value),
    value = value * 10^-3
    )

# Plot
UDXISC11B %>% 
  ggplot(aes(
    x    = taar,
    y    = value,
    fill = sex
  )) +
  geom_col() +
  theme_statgl() + 
  scale_fill_statgl() +
  labs(
    title   = sdg4$figs$fig12$title[language],
    x       = " ",
    y       = sdg4$figs$fig12$y_lab[language],
    fill    = " ",
    caption = sdg4$figs$fig12$cap[language]
  )

StatBank


# Transform
UDXISC11B <-
  UDXISC11B_raw %>% 
  #arrange(desc(time)) %>% 
  filter(taar >= year(Sys.time()) - 6) %>% 
  mutate(taar = taar %>% fct_inorder()) %>% 
  spread(2, 3)

# Table
UDXISC11B %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  add_footnote(
    sdg4$figs$fig12$foot[language],
    notation = "symbol"
    )
2019 2020 2021 2022 2023 2024
Men 1.370 1.363 1.289 1.231 1.150 1.160
Women 2.118 2.232 2.117 2.109 2.010 2.006
* Number of students



Number of Graduates


GS Number of graduates
# Import
UDXISC11D_raw <-
  statgl_url("UDXISC11D", lang = language) %>% 
  statgl_fetch(
    Isced     = px_all(),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXISC11D <-
  UDXISC11D_raw %>%
  mutate(
    slutaar              = slutaar %>% make_date(),
    id                   = row_number(),
    Isced = Isced %>% str_remove("uddannelse"),
    Isced = Isced %>% fct_reorder(id, .fun = min, na.rm = TRUE) %>% fct_rev()
  )

# Plot
UDXISC11D %>% 
  ggplot(aes(
    x    = slutaar,
    y    = value,
    fill = Isced
    )) +
  geom_col() +
  scale_y_continuous(labels = scales::number_format(
    accuracy     = 1,
    big.mark     = ".",
    decimal.mark = ",")) +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = TRUE, nrow = 4)) +
  labs(
    title    = sdg4$figs$fig13$title[language],
    subtitle = sdg4$figs$fig13$sub[language],
    x        = " ",
    y        = sdg4$figs$fig13$y_lab[language],
    fill     = sdg4$figs$fig13$fill[language],
    caption  = sdg4$figs$fig13$cap[language] 
  )

StatBank

Method


# Transform
UDXISC11D <- 
  UDXISC11D_raw %>% 
  #arrange(desc(time)) %>% 
  filter(slutaar >= year(Sys.time()) - 6) %>% 
  mutate(
    Isced    = Isced %>% fct_inorder(),
    slutaar  = slutaar %>% fct_inorder()
    ) %>% 
  spread(2, 3)

# Table
UDXISC11D %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  add_footnote(
    sdg4$figs$fig13$foot[language],
    notation = "symbol"
    )
2019 2020 2021 2022 2023 2024
Upper secondary education 314 310 318 282 333 293
Vocational education and training 399 411 448 376 403 362
Supplementary examination courses 111 125 141 119 99 89
Short-cycle higher education 55 68 66 62 62 62
Bachelors programme 53 47 54 55 56 53
Professional bachelors programme 129 107 119 103 88 95
Masters programme 35 40 35 32 35 28
* Number of people - highest educational attainment



# Import
UDXISC11D_raw <-
  statgl_url("UDXISC11D", lang = language) %>% 
  statgl_fetch(
    Isced     = px_all(),
    sex       = px_all(),
    skoleomr  = c("A_SG", "B_SD"),
    .col_code = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXISC11D <- 
  UDXISC11D_raw %>% 
  mutate(
    Isced    = Isced %>% str_remove("uddannelse") %>% trimws(),
    Isced    = Isced %>% fct_inorder() %>% fct_rev(),
    sex      = sex  %>% fct_inorder(),
    skoleomr = skoleomr %>% fct_inorder,
    slutaar  = slutaar    %>% make_date()
  )

# Plot
UDXISC11D %>% 
  ggplot(aes(
    x = slutaar,
    y = value, 
    fill = Isced
  )) +
  geom_col() +
  facet_grid(skoleomr ~ sex, 
             scales = "free_y") +
  scale_y_continuous(labels = scales::number_format(
    accuracy = 1, 
    big.mark = ".",
    decimal.mark = ","
    )) +
  theme_statgl() +
  scale_fill_statgl(reverse = TRUE, 
                    guide = guide_legend(reverse = TRUE, nrow = 4)) +
  labs(
    title    = sdg4$figs$fig14$title[language],
    subtitle = sdg4$figs$fig14$sub[language],
    x        = " ",
    y        = sdg4$figs$fig14$y_lab[language],
    fill     = sdg4$figs$fig14$fill[language],
    caption  = sdg4$figs$fig14$cap[language]
  )

StatBank

Method


# Transform
UDXISC11D <- 
  UDXISC11D_raw %>% 
  #arrange(desc(time)) %>% 
  filter(slutaar >= year(Sys.time()) - 4) %>% 
  mutate(
    slutaar  = slutaar %>% fct_inorder(),
    Isced    = Isced %>% fct_inorder(),
    skoleomr = skoleomr %>% fct_inorder()
    ) %>% 
  unite(combi, 2, 4, sep = ",") %>%  
  mutate(combi = combi %>% fct_inorder()) %>% 
  spread(2, 4)

vec      <- UDXISC11D[-(1:2)] %>% colnames() %>% str_split(",") %>% unlist()
head_vec <- table(vec[c(F, T)]) %>% rev()
col_vec  <- vec[c(T, F)]

# Table
UDXISC11D %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(col.names = c(" ", col_vec)) %>% 
  pack_rows(index = table(UDXISC11D[[1]])) %>% 
  add_header_above(c(" ", head_vec))
2024
2023
2022
2021
Men,2021 Men,2022 Men,2023 Men,2024 Women,2021 Women,2022 Women,2023 Women,2024
Upper secondary education
Schools in Greenland 96 86 84 107 198 163 214 166
Schools in Denmark 7 17 6 7 14 13 26 11
Vocational education and training
Schools in Greenland 180 164 166 147 249 198 222 197
Schools in Denmark 11 8 6 7 8 5 8 10
Supplementary examination courses
Schools in Greenland 37 41 27 30 95 75 67 59
Schools in Denmark 2 1 2 0 7 2 3 0
Short-cycle higher education
Schools in Greenland 14 17 11 18 34 27 35 29
Schools in Denmark 5 8 5 7 13 10 10 7
Bachelors programme
Schools in Greenland 10 8 15 16 22 24 29 22
Schools in Denmark 5 7 6 3 14 14 5 11
Professional bachelors programme
Schools in Greenland 12 17 15 10 86 75 52 65
Schools in Denmark 6 4 9 6 13 7 12 14
Masters programme
Schools in Greenland 3 2 2 2 10 10 10 9
Schools in Denmark 10 6 8 7 11 13 15 8



Level of education among 35-39 year olds


GS Level of education among 35-39 year olds
# Import
UDXISCPROF_raw <-
  statgl_url("UDXISCPROF", lang = language) %>% 
  statgl_fetch(
    alder_grp     = "35-39",
    ISCED11_level = c(20, 34, 35, 40, 50, 64, 65, 70, 80),
    .col_code     = TRUE
    ) %>% 
  as_tibble()
  
# Transform
UDXISCPROF <-
  UDXISCPROF_raw %>% 
  mutate(
    id = row_number(),
    ISCED11_level = ISCED11_level %>% str_remove("uddannelse") %>% 
    fct_reorder(id, .fun = min, na.rm = T) %>% fct_rev()
    )

# Plot
UDXISCPROF %>% 
  mutate(Aar = Aar %>% make_date()) %>% 
  ggplot(aes(
    x    = Aar, 
    y    = value,
    fill = ISCED11_level
    )) +
  geom_area(position = "fill") +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 100, 
    accuracy     = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl(base_size = 11) +
  guides(fill = guide_legend(nrow = 3, byrow = TRUE)) +
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = TRUE)) +
  labs(
    title    = sdg4$figs$fig15$title[language],
    subtitle = UDXISCPROF[[2]][1],
    x        = " ",
    y        = " ",
    fill     = NULL,
    caption  = sdg4$figs$fig15$cap[language]
  )

StatBank

Method


# Transform
UDXISCPROF <- 
  UDXISCPROF_raw %>% 
  #arrange(desc(time)) %>% 
  filter(Aar >= year(Sys.time()) - 5) %>% 
  mutate(
    Aar           = Aar %>% fct_inorder(),
    ISCED11_level = ISCED11_level %>% fct_inorder()
    ) %>% 
  spread(3, 4)

# Table
UDXISCPROF %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  pack_rows(index = table(UDXISCPROF[[1]])) %>% 
  add_footnote(
    sdg4$figs$fig15$foot[language], 
    notation = "symbol"
    )
2020 2021 2022 2023
35-39 years
Lower secondary education 1.669 1.696 1.781 1.901
Upper secondary education 154 175 183 197
Vocational education and training 1.223 1.247 1.229 1.292
Supplementary examination courses 118 91 80 80
Short-cycle higher education 163 158 159 176
Bachelors programme 48 48 58 56
Professional bachelors programme 394 417 433 442
Masters programme 156 173 179 180
Phd. Programmes 7 9 9 11
* Number of people - highest educational attainment



# Import
UDXISCPROD_raw <-
  statgl_url("UDXISCPROD", lang = language) %>% 
  statgl_fetch(
    alder_grp     = "35-39",
    ISCED11_level = c(20, 34, 35, 40, 50, 64, 65, 70, 80),
    Bsted         = px_all(),
    .col_code     = TRUE
    ) %>% 
  as_tibble()
  
# Transform
UDXISCPROD <-
  UDXISCPROD_raw %>% 
  mutate(
    id                   = row_number(),
    ISCED11_level = ISCED11_level %>% str_remove("uddannelse") %>% 
           fct_reorder(id, .fun = min, na.rm = TRUE) %>% fct_rev(),
    Aar                 = Aar %>% make_date()
    )

# Plot
UDXISCPROD %>% 
  ggplot(aes(
    x    = Aar,
    y    = value,
    fill = ISCED11_level
    )) +
  geom_area(position = "fill") +
  facet_wrap(~ Bsted) +
  scale_y_continuous(labels  = scales::percent_format(
    scale        = 100, 
    accuracy     = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl(base_size = 11) +
  guides(fill = guide_legend(nrow = 3, byrow = TRUE)) +
  scale_fill_statgl(reverse = TRUE, guide = guide_legend(reverse = TRUE)) +
  labs(
    title    = sdg4$figs$fig16$title[language],
    subtitle = UDXISCPROD[[3]][1],
    x        = " ",
    y        = " ",
    fill     = NULL,
    caption  = sdg4$figs$fig16$cap[language]
  )

StatBank

Method


UDXISCPROD <-
  UDXISCPROD_raw %>% 
  #arrange(desc(time)) %>% 
  filter(Aar >= year(Sys.time()) - 5) %>% 
  mutate(
    Aar = Aar %>% fct_inorder(),
    ISCED11_level = ISCED11_level %>% fct_inorder()
  ) %>% 
  arrange(ISCED11_level) %>% 
  unite(combi, 2, 4, sep = ",") %>% 
  mutate(combi = combi %>% fct_inorder()) %>% 
  spread(2, ncol(.))

vec      <- colnames(UDXISCPROD[-(1:2)]) %>% str_split(",") %>% unlist()
head_vec <- table(vec[c(F, T)]) %>% rev()
col_vec  <- vec[c(T, F)]

UDXISCPROD %>% 
  select(-1) %>% 
  rename(" " = 1) %>% 
  statgl_table(col.names = c(" ", col_vec), replace_0s = TRUE) %>% 
  add_header_above(c(" ", head_vec)) %>% 
  add_footnote(
    sdg4$figs$fig16$foot[language], 
    notation = "symbol"
    )
2023
2022
2021
2020
Town,2020 Town,2021 Town,2022 Town,2023 Settlements,2020 Settlements,2021 Settlements,2022 Settlements,2023
Lower secondary education 1.360 1.389 1.506 1.618 309 307 275 283
Upper secondary education 148 162 171 183 6 13 12 14
Vocational education and training 1.120 1.140 1.125 1.180 103 107 104 112
Supplementary examination courses 112 86 76 77 6 5 4 3
Short-cycle higher education 161 157 155 171 2 1 4 5
Bachelors programme 48 48 58 55 0 0 0 1
Professional bachelors programme 383 403 411 427 11 14 22 15
Masters programme 155 173 179 180 1 0 0 0
Phd. Programmes 7 9 9 11 0 0 0 0
* Number of people - highest educational attainment



Information and communation technology


FN 4.4.1 Proportions of 16-74 year olds with education in information and communication technology
# Import
UDXISCPROE_raw1 <-
  statgl_url("UDXISCPROE", lang = language) %>% 
  statgl_fetch(
    ISCED11_level  = c(35, 50, 64, 65, 70),
    ISCED11_sektor = c("06"),
    .col_code      = TRUE
    ) %>% 
  as_tibble()

UDXISCPROE_raw2 <-
  statgl_url("UDXISCPROE", lang = language) %>% 
  statgl_fetch(
    ISCED11_level = "00",
    .col_code     = TRUE
    ) %>% 
  as_tibble()

# Transform
UDXISCPROE <-
  UDXISCPROE_raw1 %>% 
  rename(tæller = value) %>% 
  left_join(UDXISCPROE_raw2 %>% rename(nævner = value) %>% select(-1)) %>% 
  mutate(
    procent       = tæller / nævner * 100,
    ISCED11_level = ISCED11_level %>% str_remove("uddannelse"),
    Aar           = Aar %>% make_date()
    )

# Plot
UDXISCPROE %>% 
  ggplot(aes(
    x    = Aar,
    y    = procent,
    fill = ISCED11_level
  )) +
  geom_col() +
  scale_y_continuous(labels = scales::percent_format(
    scale        = 1, 
    big.mark     = ".",
    decimal.mark = ","
    )) +
  theme_statgl() + 
  scale_fill_statgl(reverse = TRUE, palette  = "spring") +
  guides(fill = guide_legend(nrow = 2, byrow = TRUE)) +
  labs(
    title    = sdg4$figs$fig17$title[language],
    subtitle = sdg4$figs$fig17$sub[language],
    x        = " ",
    y        = " ",
    fill     = NULL,
    caption  = sdg4$figs$fig17$cap[language]
  )

StatBank

# Transform
UDXISCPROE <-
  UDXISCPROE_raw1 %>% 
  rename(tæller = value) %>% 
  left_join(UDXISCPROE_raw2 %>% rename(nævner = value) %>% select(-1)) %>% 
  mutate(
    procent              = tæller / nævner * 100,
    procent              = procent %>% round(1),
    ISCED11_level = ISCED11_level %>% str_remove("uddannelse")
    ) %>% 
  #arrange(desc(time)) %>% 
  filter(Aar >= year(Sys.time()) - 5) %>% 
  mutate(
    ISCED11_level = ISCED11_level %>% fct_inorder(),
    Aar           = Aar %>% fct_inorder()
  ) %>% 
  select(-c(2, 4:5)) %>% 
  spread(2, 3)
  
# Table
UDXISCPROE %>% 
  rename(" " = 1) %>% 
  statgl_table() %>% 
  add_footnote(
    sdg4$figs$fig17$foot[language],
    notation = "symbol")
2020 2021 2022 2023
Vocational education and training 0,2 0,2 0,2 0,2
Short-cycle higher education 0,2 0,2 0,2 0,2
Bachelors programme 0,0 0,0 0,0 0,0
Professional bachelors programme 0,0 0,0 0,0 0,0
Masters programme 0,0 0,0 0,0 0,0
* Percentage of young people and adults with professional qualifications in information and communication technology