QuantumLearner commited on
Commit
43415d2
·
verified ·
1 Parent(s): 38f2bbe

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -1
app.py CHANGED
@@ -235,7 +235,18 @@ if run_button or "data" in st.session_state:
235
  # Equity Curve
236
  fig.add_trace(go.Scatter(x=updated_data.index, y=updated_data['Equity_Curve'], mode='lines', name='Equity Curve', line=dict(color='white')), row=3, col=1)
237
 
238
- fig.update_layout(title=f'{ticker} Bollinger Bands and RSI Strategy', xaxis_title='Date', height=800)
 
 
 
 
 
 
 
 
 
 
 
239
 
240
  st.plotly_chart(fig, use_container_width=True)
241
 
 
235
  # Equity Curve
236
  fig.add_trace(go.Scatter(x=updated_data.index, y=updated_data['Equity_Curve'], mode='lines', name='Equity Curve', line=dict(color='white')), row=3, col=1)
237
 
238
+ fig.update_layout(
239
+ title=f'{ticker} Bollinger Bands and RSI Strategy',
240
+ xaxis_title='Date',
241
+ height=800,
242
+ legend=dict(
243
+ orientation="h", # Horizontal legend
244
+ yanchor="bottom", # Align the legend to the bottom
245
+ y=1.15, # Place it slightly above the plot
246
+ xanchor="center", # Center the legend horizontally
247
+ x=0.5 # Center the legend on the x-axis
248
+ )
249
+ )
250
 
251
  st.plotly_chart(fig, use_container_width=True)
252