hhalim commited on
Commit
60911a3
1 Parent(s): 272d0e3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -1,10 +1,14 @@
1
-
2
  import streamlit as st
3
  import pandas as pd
4
  import plotly.express as px
5
 
6
  st.title('Random Population Dataset and Treemap')
7
 
 
 
 
 
 
8
  # Generate random population dataset
9
  data = pd.DataFrame({
10
  'Country': ['USA', 'China', 'India', 'Japan', 'Germany'],
 
 
1
  import streamlit as st
2
  import pandas as pd
3
  import plotly.express as px
4
 
5
  st.title('Random Population Dataset and Treemap')
6
 
7
+ # Upload CSV
8
+ uploaded_file = st.file_uploader("Upload CSV file here", type="csv")
9
+ if uploaded_file is not None:
10
+ data = pd.read_csv(uploaded_file)
11
+
12
  # Generate random population dataset
13
  data = pd.DataFrame({
14
  'Country': ['USA', 'China', 'India', 'Japan', 'Germany'],