AlexanderSvarfdal commited on
Commit
0224557
·
1 Parent(s): 094fc7e

First draft of data preprocessing

Browse files
data_processing/aggregate_data.py ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ # Small area id: id of the small area
2
+ # Density: current density of the small area
3
+ # Income distribution: the distribution of income
4
+ # Age distribution:
5
+ columns = ["smallAreaId", "density", "income_distribution", "age_distribution", "geometry", "projected_dwellings"]
given_data/.DS_Store CHANGED
Binary files a/given_data/.DS_Store and b/given_data/.DS_Store differ
 
given_data/borgarlina3_leaflet.py CHANGED
@@ -73,10 +73,10 @@ def create_map(lina1_wgs84, all_dwellings_smallarea):
73
  display(m)
74
 
75
  def main():
76
- geojson_file = "cityline_2025.geojson"
77
- pop_file = "ibuafjoldi.csv"
78
- smallarea_file = "smasvaedi_2021.json"
79
- dwellings_file = "ibudir.csv"
80
 
81
  lina1_wgs84, pop2024_smallarea, all_dwellings_smallarea = load_and_preprocess_data(geojson_file, pop_file, smallarea_file, dwellings_file)
82
  create_map(lina1_wgs84, all_dwellings_smallarea) # Call the function to create the map
 
73
  display(m)
74
 
75
  def main():
76
+ geojson_file = "given_data/cityline_geojson/cityline_2025.geojson"
77
+ pop_file = "given_data/ibuafjoldi.csv"
78
+ smallarea_file = "given_data/smasvaedi_2021.json"
79
+ dwellings_file = "given_data/ibudir.csv"
80
 
81
  lina1_wgs84, pop2024_smallarea, all_dwellings_smallarea = load_and_preprocess_data(geojson_file, pop_file, smallarea_file, dwellings_file)
82
  create_map(lina1_wgs84, all_dwellings_smallarea) # Call the function to create the map
requirements.txt CHANGED
@@ -2,4 +2,7 @@ pyproj
2
  geopandas
3
  pandas
4
  matplotlib
5
- seaborn
 
 
 
 
2
  geopandas
3
  pandas
4
  matplotlib
5
+ seaborn
6
+ Ipython
7
+ ipyleaflet
8
+ folium