awacke1 commited on
Commit
1cb0f1d
·
1 Parent(s): 6b1e507

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +28 -0
app.py CHANGED
@@ -30,6 +30,11 @@ with g.subgraph(name='cluster_MN') as c:
30
  # Render the graph using streamlit
31
  st.graphviz_chart(g)
32
 
 
 
 
 
 
33
  def render_hospital_graph(hospital):
34
  g = gv.Graph(format='svg')
35
  g.graph_attr['bgcolor'] = '#FFFFFF'
@@ -53,3 +58,26 @@ def render_hospital_graph(hospital):
53
 
54
  svg_output = g.pipe(format='svg')
55
  st.image(svg_output, output_format='SVG')
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
30
  # Render the graph using streamlit
31
  st.graphviz_chart(g)
32
 
33
+
34
+
35
+ import streamlit as st
36
+ import graphviz as gv
37
+
38
  def render_hospital_graph(hospital):
39
  g = gv.Graph(format='svg')
40
  g.graph_attr['bgcolor'] = '#FFFFFF'
 
58
 
59
  svg_output = g.pipe(format='svg')
60
  st.image(svg_output, output_format='SVG')
61
+
62
+ # Define hospitals data
63
+ hospitals = [('Allina Health', 'Abbott Northwestern Hospital', 'Beds: 627', 'Specialties: Cardiovascular care, neurosciences, cancer care'),
64
+ ('Fairview Health Services', 'University of Minnesota Medical Center', 'Beds: 914', 'Specialties: Cancer care, transplant services, orthopedics'),
65
+ ('HealthPartners', 'Regions Hospital', 'Beds: 454', 'Specialties: Level I Trauma Center, heart care, cancer care'),
66
+ ('Mayo Clinic', 'Saint Marys Hospital', 'Beds: 1,265', 'Specialties: Cardiology, neurology, gastroenterology'),
67
+ ('CentraCare', 'St. Cloud Hospital', 'Beds: 489', 'Specialties: Cancer care, heart care, neuroscience'),
68
+ ('Essentia Health', 'St. Mary’s Medical Center', 'Beds: 330', 'Specialties: Cancer care, heart care, orthopedics'),
69
+ ('Hennepin Healthcare', 'HCMC', 'Beds: 497', 'Specialties: Level I Trauma Center, burn center, cancer care'),
70
+ ("Children's Minnesota", "Children's Hospitals and Clinics of Minnesota", 'Beds: 381', 'Specialties: Pediatrics, heart care, neonatology'),
71
+ ('Sanford Health', 'Sanford Bemidji Medical Center', 'Beds: 161', 'Specialties: Cancer care, heart care, orthopedics'),
72
+ ("St. Luke's Hospital", "St. Luke's Hospital", 'Beds: 267', 'Specialties: Cancer care, heart care, orthopedics')]
73
+
74
+ # Render a separate graph for each hospital
75
+ for hospital in hospitals:
76
+ render_hospital_graph(hospital)
77
+
78
+
79
+
80
+
81
+
82
+
83
+