fschwartzer commited on
Commit
68c0e55
·
1 Parent(s): efb0d40

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -252,14 +252,15 @@ predicted_target = knn_predict(filtered_data, 'target_column', ['latitude', 'lon
252
  # Add predicted target values to filtered_data
253
  filtered_data['Predicted_target'] = predicted_target
254
 
255
- if st.button("Download Filtered Data as XLSX"):
256
- with st.spinner('Downloading...'):
257
- filtered_data.to_excel("filtered_data.xlsx", index=False)
258
- st.success('Download Complete!')
259
 
260
  with st.container():
261
  st.map(filtered_data, zoom=zoom_level, use_container_width=True)
262
  st.write("Dados:", filtered_data) # Debug: Print filtered_data
 
 
 
 
 
263
 
264
  folium_layermap = folium.Map(location=[custom_lat, custom_lon], zoom_start=zoom_level, control_scale=True)
265
 
 
252
  # Add predicted target values to filtered_data
253
  filtered_data['Predicted_target'] = predicted_target
254
 
 
 
 
 
255
 
256
  with st.container():
257
  st.map(filtered_data, zoom=zoom_level, use_container_width=True)
258
  st.write("Dados:", filtered_data) # Debug: Print filtered_data
259
+
260
+ if st.button("Baixar arquivo do Excel"):
261
+ with st.spinner('Downloading...'):
262
+ filtered_data.to_excel("filtered_data.xlsx", index=False)
263
+ st.success('Download completo!')
264
 
265
  folium_layermap = folium.Map(location=[custom_lat, custom_lon], zoom_start=zoom_level, control_scale=True)
266