Youssouf Traore commited on
Commit
12cb411
·
1 Parent(s): c88d6f0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -8,7 +8,7 @@ def get_covid_data(country):
8
  data = covid.get_status_by_country_name(country)
9
  return data
10
 
11
- # Fonction pour afficher les données sous forme de tableau
12
  def display_table(data):
13
  df = pd.DataFrame.from_dict(data, orient='index')
14
  df = df.rename(columns={
@@ -23,7 +23,7 @@ def display_table(data):
23
  # Interface Gradio avec une liste déroulante
24
  iface = gr.Interface(fn=get_covid_data,
25
  inputs="text",
26
- outputs=gr.outputs.Table(header=["Confirmed Cases", "Active Cases", "Deaths", "Recovered Cases"]),
27
  title="COVID-19 Data by Country",
28
  description="Enter the name of a country to get COVID-19 data.",
29
  example="France")
 
8
  data = covid.get_status_by_country_name(country)
9
  return data
10
 
11
+ # Fonction pour afficher les données sous forme de tableau HTML
12
  def display_table(data):
13
  df = pd.DataFrame.from_dict(data, orient='index')
14
  df = df.rename(columns={
 
23
  # Interface Gradio avec une liste déroulante
24
  iface = gr.Interface(fn=get_covid_data,
25
  inputs="text",
26
+ outputs=gr.outputs.HTML(),
27
  title="COVID-19 Data by Country",
28
  description="Enter the name of a country to get COVID-19 data.",
29
  example="France")