adapt transport data to multiyear setup with new swiss data
This commit is contained in:
parent
2eb159af7c
commit
5b5d308bf7
45
data/gr-e-11.03.02.01.01-cc.csv
Normal file
45
data/gr-e-11.03.02.01.01-cc.csv
Normal file
@ -0,0 +1,45 @@
|
||||
year,passenger cars,passenger vehicles,goods vehicles,agricultural vehicles,industrial vehicles,motorcycles,mopeds (incl. fast e-bikes)¹
|
||||
1980,2246752,11087,169402,137685,0,137340,671473
|
||||
1981,2394455,11122,167846,151238,0,152508,687517
|
||||
1982,2473318,11341,178313,156631,0,178398,656102
|
||||
1983,2520610,11255,189920,165332,0,187090,674710
|
||||
1984,2552132,10853,192708,164078,0,199302,647391
|
||||
1985,2617164,10771,200537,175161,0,217974,644175
|
||||
1986,2678911,10800,207014,183689,0,225676,627523
|
||||
1987,2732720,11027,217750,189984,0,240102,613093
|
||||
1988,2819548,26869,236649,152693,43519,219987,581270
|
||||
1989,2895842,29270,241488,157867,44326,261715,551808
|
||||
1990,2985397,31180,252136,162932,45920,299264,464609
|
||||
1991,3057798,32968,257646,165571,46938,319779,418251
|
||||
1992,3091228,34136,256611,169277,47281,336448,381236
|
||||
1993,3109523,34852,253461,171414,47229,348159,358732
|
||||
1994,3165042,35676,256285,172300,47373,357252,336367
|
||||
1995,3229176,36517,262352,174026,47693,370700,317783
|
||||
1996,3268093,37662,263020,174247,47622,381986,301009
|
||||
1997,3323455,38508,264200,175689,47743,410750,280467
|
||||
1998,3383307,39012,267380,176712,47754,435042,265422
|
||||
1999,3467311,39692,273954,177148,48265,464357,246018
|
||||
2000,3545247,40260,278518,177963,48949,493781,218932
|
||||
2001,3629713,41342,285246,179321,49549,521390,199033
|
||||
2002,3700951,42401,290142,180063,50227,545132,186811
|
||||
2003,3753890,43629,292329,180295,50795,567358,173486
|
||||
2004,3811351,44784,298193,180898,50957,583010,165000
|
||||
2005,3863807,45785,307264,182093,51860,592194,156095
|
||||
2006,3899917,46445,314020,185450,53437,608648,150563
|
||||
2007,3955787,48026,324153,184062,55149,619166,144704
|
||||
2008,3989811,48536,326232,188218,55808,636540,141549
|
||||
2009,4009602,50675,327808,185902,56533,642777,139220
|
||||
2010,4075825,52751,335200,186485,58492,651202,139548
|
||||
2011,4163003,55422,348553,187130,60324,665870,142834
|
||||
2012,4254725,58278,361926,188358,62219,679822,145984
|
||||
2013,4320885,60151,371361,189305,63950,687990,147247
|
||||
2014,4384490,62436,382281,190095,65563,699219,152962
|
||||
2015,4458069,65720,393598,191132,67101,710022,161292
|
||||
2016,4524029,69676,405566,192139,68721,720381,176030
|
||||
2017,4570823,73814,416501,192858,70113,729149,188053
|
||||
2018,4602688,77985,428808,193283,71683,739344,201423
|
||||
2019,4623952,83054,440795,193834,74085,744542,211480
|
||||
2020,4658335,88293,452186,195082,75659,771586,229421
|
||||
2021,4709366,97805,466857,196530,77672,791323,244572
|
||||
2022,4721280,105158,475714,196942,79691,789794,257753
|
||||
2023,4760948,114299,485303,197678,81241,805653,
|
|
@ -289,6 +289,7 @@ rule build_energy_totals:
|
||||
nuts3_shapes=resources("nuts3_shapes.geojson"),
|
||||
co2="data/bundle-sector/eea/UNFCCC_v23.csv",
|
||||
swiss="data/switzerland-new_format-all_years.csv",
|
||||
swiss_transport="data/gr-e-11.03.02.01.01-cc.csv",
|
||||
idees="data/bundle-sector/jrc-idees-2015",
|
||||
district_heat_share="data/district_heat_share.csv",
|
||||
eurostat="data/eurostat/eurostat-energy_balances-april_2023_edition",
|
||||
|
@ -712,15 +712,25 @@ def build_co2_totals(countries, eea_co2, eurostat_co2):
|
||||
|
||||
|
||||
def build_transport_data(countries, population, idees):
|
||||
transport_data = pd.DataFrame(index=countries)
|
||||
# first collect number of cars
|
||||
|
||||
# collect number of cars
|
||||
transport_data = pd.DataFrame(idees["passenger cars"])
|
||||
|
||||
transport_data["number cars"] = idees["passenger cars"]
|
||||
|
||||
# CH from http://ec.europa.eu/eurostat/statistics-explained/index.php/Passenger_cars_in_the_EU#Luxembourg_has_the_highest_number_of_passenger_cars_per_inhabitant
|
||||
# https://www.bfs.admin.ch/bfs/en/home/statistics/mobility-transport/transport-infrastructure-vehicles/vehicles/road-vehicles-stock-level-motorisation.html
|
||||
if "CH" in countries:
|
||||
transport_data.at["CH", "number cars"] = 4.136e6
|
||||
fn = snakemake.input.swiss_transport
|
||||
swiss_cars = pd.read_csv(fn, index_col=0).loc[1990:2021, ["passenger cars"]]
|
||||
|
||||
swiss_cars.index = pd.MultiIndex.from_product(
|
||||
[["CH"], swiss_cars.index],
|
||||
names=["country", "year"]
|
||||
)
|
||||
|
||||
transport_data = pd.concat([transport_data, swiss_cars]).sort_index()
|
||||
|
||||
transport_data.rename(
|
||||
columns={"passenger cars": "number cars"}, inplace=True
|
||||
)
|
||||
|
||||
missing = transport_data.index[transport_data["number cars"].isna()]
|
||||
if not missing.empty:
|
||||
|
Loading…
Reference in New Issue
Block a user