Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -34,17 +34,12 @@ def plot_taraf_map(yaxis,min_year = 0, max_year = 400, heat=False):
|
|
34 |
fig = px.density_mapbox(data_frame = filtered, lat = filtered.geometry.y, lon = filtered.geometry.x,z = yaxis, title = f'Map of {yaxis}', opacity = .5, hover_data = 'City',center=dict(lat=21.4241, lon=39.826168), radius=17, zoom=2)
|
35 |
else:
|
36 |
fig = px.scatter_mapbox(data_frame = filtered, lat = filtered.geometry.y, lon = filtered.geometry.x,size = f'{yaxis}_CubeRoot',color = yaxis, title = f'Map of {yaxis}', opacity = .5, hover_data = 'City',center=dict(lat=21.4241, lon=39.826168), zoom=2 )
|
37 |
-
fig.update_layout(title_font_color = 'red',margin=dict(l=0, r=0, b=0), title_x = .5, mapbox_style="white-bg",
|
38 |
mapbox_layers=[
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
"source": [
|
44 |
-
"https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryOnly/MapServer/tile/{z}/{y}/{x}"
|
45 |
-
]
|
46 |
-
}
|
47 |
-
])
|
48 |
return fig
|
49 |
|
50 |
|
|
|
34 |
fig = px.density_mapbox(data_frame = filtered, lat = filtered.geometry.y, lon = filtered.geometry.x,z = yaxis, title = f'Map of {yaxis}', opacity = .5, hover_data = 'City',center=dict(lat=21.4241, lon=39.826168), radius=17, zoom=2)
|
35 |
else:
|
36 |
fig = px.scatter_mapbox(data_frame = filtered, lat = filtered.geometry.y, lon = filtered.geometry.x,size = f'{yaxis}_CubeRoot',color = yaxis, title = f'Map of {yaxis}', opacity = .5, hover_data = 'City',center=dict(lat=21.4241, lon=39.826168), zoom=2 )
|
37 |
+
fig.update_layout(title_font_color = 'red',margin=dict(l=0, r=0, b=0), title_x = .5, mapbox_style="white-bg",
|
38 |
mapbox_layers=[
|
39 |
+
{"below": 'traces',
|
40 |
+
"sourcetype": "raster",
|
41 |
+
"sourceattribution": "United States Geological Survey",
|
42 |
+
"source": ["https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryOnly/MapServer/tile/{z}/{y}/{x}"] }])
|
|
|
|
|
|
|
|
|
|
|
43 |
return fig
|
44 |
|
45 |
|