Energy


Energy
url <- paste0("https://bank.stat.gl/api/v1/", language, "/Greenland/EN/EN20/ENX1ACT.px")

ENX1ACT_raw <- 
  url |> 
  statgl_fetch(
    type      = 0,
    product   = px_all(),
    use       = 0,
    time      = px_top(5),
    .col_code = T
  ) |> 
  as_tibble()

ENX1ACT <- 
  ENX1ACT_raw |> 
  unite(combi, use, type, sep = " ") |> 
  mutate(product = product |> fct_inorder()) |> 
  spread(time, value)

ENX1ACT |> 
  select(-1) |> 
  rename(" " = 1) |> 
  statgl_table() |> 
  row_spec(1, bold = T) |> 
  add_footnote(ENX1ACT_raw[[1]][1], notation = "symbol")
2018 2019 2020 2021 2022
Total 8.885 8.998 8.827 9.258 10.002
Gas oil 5.266 5.086 5.463 6.035 6.494
Gasoline 730 820 815 856 843
Kerosene / Jet Fuel 817 850 468 561 764
Diesel Fuel Arctic 189 170 170 170 162
LPG 3 3 3 3 3
Aviation Gasoline 1 1 0 0 1
Fueloil 302 515 282 1 0
Wasteoil 9 9 9 9 9
Waste heat 98 110 103 102 88
Hydropower 1.469 1.434 1.513 1.521 1.639
* Actual energy consumption


See the table in our Statbank: ENX1ACT

url <- paste0("https://bank.stat.gl/api/v1/", language, "/Greenland/EN/EN20/ENX2CO2.px")

ENX2CO2_raw <- 
  url |> 
  statgl_fetch(
    type      = 0,
    gas       = px_all(),
    time      = px_top(5),
    .col_code = T
  ) |> 
  as_tibble()

ENX2CO2 <- 
  ENX2CO2_raw |> 
  spread(gas, value)

ENX2CO2 |> 
  select(-1) |> 
  rename(" " = 1) |> 
  statgl_table() |> 
  add_footnote(ENX2CO2[[1]][1], notation = "symbol")
Carbon dioxide (CO2) Methane (CH4) Nitrous oxide (N2O)
2018 540.255 50,9 8,68
2019 550.961 52,1 9,15
2020 532.904 52,0 8,39
2021 562.527 53,5 8,90
2022 609.204 56,1 10,00
* Actual emission


See the table in our Statbank: ENX2CO2

Climate
url <- paste0("https://bank.stat.gl/api/v1/", language, "/Greenland/EN/EN30/ENX1MID.px")

ENX1MID_raw <- 
  url |> 
  statgl_fetch(
    measuring         = px_all(),
    time              = px_top(),
    "weather station" = 5,
    month             = px_all(),
    .col_code         = T
  ) |> 
  as_tibble()

ENX1MID <- 
  ENX1MID_raw |> 
  mutate(month = month |> fct_inorder(),
         measuring = measuring |> fct_inorder()) |> 
  spread(measuring, value) |> 
  unite(combi, `weather station`, time, sep = " ")
  
ENX1MID |> 
  select(-1) |> 
  rename(" " = 1) |> 
  statgl_table() |> 
  add_footnote(ENX1MID[[1]][1], notation = "symbol")
Average Maximum temperature Minimum temperature
January -4,0 2,6 -9,8
February -7,6 3,9 -14,8
March -6,2 7,3 -22,2
April -1,4 7,6 -11,8
May 1,6 12,3 -3,8
June 4,9 14,9 0,0
July 7,9 18,1 0,5
August 7,9 16,6 2,8
September 2,8 12,2 -2,3
October 0,8 7,8 -6,1
November -3,2 6,6 -11,2
December -1,9 12,2 -9,0
* Nuuk 2021


See the table in our Statbank: ENX1MID

Motor vehicles
url <- paste0("https://bank.stat.gl/api/v1/", language, "/Greenland/EN/EN40/ENXMO1HI.px")

ENXMO1HI_raw <- 
  url |> 
  statgl_fetch(
    ownership = 1:2,
    category  = px_all(),
    time      = px_top(),
    .col_code = T
  ) |> 
  as_tibble()

ENXMO1HI <- 
  ENXMO1HI_raw |> 
  mutate_all(~replace(., is.na(.), 0)) |> 
  mutate(category = category |> fct_inorder()) |> 
  spread(ownership, value)

ENXMO1HI |> 
  select(-time) |> 
  rename(" " = 1) |> 
  statgl_table() |> 
  row_spec(1, bold = T) |> 
  add_footnote(ENXMO1HI[[2]][1], notation = "symbol")
Businesses Private households
Motor vehicles total 6.763 7.748
Taxis 175 0
Rental cars 0 0
Cars 2.250 4.299
Buser 108 0
Emergency vehicles total 216 0
  • Of which Fire-engines
216 0
  • Of which Ambulances
0 0
Vans and Trucks total 1.609 90
  • Of which Vans
1.161 90
  • Of which Trucks
448 0
Motorcycles 0 4
Construction machineries 1.186 0
Trailers 338 121
Snowmobiles 459 2.848
AT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