Files changed (1) hide show
  1. plots.py +3 -6
plots.py CHANGED
@@ -134,8 +134,8 @@ def ER(stock_df, choices):
134
  Bar_output['Assets'].append('Portfolio')
135
  Bar_output['Expected Annual Return'].append(ER_portfolio)
136
  fig = px.bar(Bar_output, x='Assets', y="Expected Annual Return",color='Assets')
137
- fig.update_layout(title_text = 'Annual Expected Return of the Assets and Portfolio',
138
- title_x=0.458)
139
  st.plotly_chart(fig, use_container_width=True)
140
 
141
  return beta, cash_value_stocks
@@ -167,10 +167,7 @@ def display_heat_map(stock_df,choices):
167
  fig = px.imshow(price_correlation,text_auto=True, aspect="auto")
168
  # Displays the heatmap on streamlit
169
  st.write(fig)
170
- # Creates a header for the correlation data
171
- #st.subheader('Correlation Data')
172
- # Displays the correlation data on streamlit
173
- #st.dataframe(price_correlation)
174
 
175
  #def display_portfolio_return(stock_df, choices):
176
  """Uses the stock dataframe and the chosen weights from choices to calculate and graph the historical cumulative portfolio return.
 
134
  Bar_output['Assets'].append('Portfolio')
135
  Bar_output['Expected Annual Return'].append(ER_portfolio)
136
  fig = px.bar(Bar_output, x='Assets', y="Expected Annual Return",color='Assets')
137
+ #fig.update_layout(title_text = 'Annual Expected Return of the Assets and Portfolio',title_x=0.458)
138
+ st.subheader('Annual Expected Return of the Assets and Portfolio')
139
  st.plotly_chart(fig, use_container_width=True)
140
 
141
  return beta, cash_value_stocks
 
167
  fig = px.imshow(price_correlation,text_auto=True, aspect="auto")
168
  # Displays the heatmap on streamlit
169
  st.write(fig)
170
+
 
 
 
171
 
172
  #def display_portfolio_return(stock_df, choices):
173
  """Uses the stock dataframe and the chosen weights from choices to calculate and graph the historical cumulative portfolio return.