awacke1 commited on
Commit
9fccd90
·
1 Parent(s): dab3650

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -4,9 +4,9 @@ import plotly.express as px
4
 
5
  # Function to plot the map
6
  def plot_map(data):
7
- fig = px.choropleth(locations=data['State'], locationmode="USA-states", color=data['Revenue'],
8
  scope="usa", title="Top Corporations by State in the United States",
9
- hover_name=data['Corporation'], hover_data=['Revenue'])
10
  return fig
11
 
12
  # Streamlit app
 
4
 
5
  # Function to plot the map
6
  def plot_map(data):
7
+ fig = px.choropleth(data, locations='State', locationmode="USA-states", color='Revenue',
8
  scope="usa", title="Top Corporations by State in the United States",
9
+ hover_name='Corporation', hover_data=['Revenue'])
10
  return fig
11
 
12
  # Streamlit app