jeonghin commited on
Commit
f08651d
1 Parent(s): 1ab2fce

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -4
app.py CHANGED
@@ -51,16 +51,27 @@ def create_plot(layers):
51
  # # Set the app to be servable
52
  # app.servable()
53
 
54
- # Main layout
55
- main_layout = pn.Column(
 
56
  "# Data Interactive Visualization (SPARCS)",
57
  subgroup_select,
58
  pn.panel(create_plot, reactive=True),
59
  )
60
 
 
 
 
 
 
 
 
 
 
 
61
  # Create a basic template
62
  template = pn.template.BootstrapTemplate(title='SI649 Project 2')
63
- template.main.append(main_layout)
64
 
65
  # Serve the application
66
- template.servable()
 
51
  # # Set the app to be servable
52
  # app.servable()
53
 
54
+ # Create two instances of the main layout
55
+ # Main layout 1
56
+ main_layout1 = pn.Column(
57
  "# Data Interactive Visualization (SPARCS)",
58
  subgroup_select,
59
  pn.panel(create_plot, reactive=True),
60
  )
61
 
62
+ # Main layout 2
63
+ main_layout2 = pn.Column(
64
+ "# Data Interactive Visualization (SPARCS)",
65
+ subgroup_select.clone(),
66
+ pn.panel(create_plot, reactive=True),
67
+ )
68
+
69
+ # Place layouts side by side using pn.Row
70
+ side_by_side_layout = pn.Row(main_layout1, main_layout2)
71
+
72
  # Create a basic template
73
  template = pn.template.BootstrapTemplate(title='SI649 Project 2')
74
+ template.main.append(side_by_side_layout)
75
 
76
  # Serve the application
77
+ template.servable()