Lirsen Myrtaj Yim-Koi commited on
Commit
b39cfe3
1 Parent(s): f2ae133

Update app.py (#12)

Browse files

- Update app.py (e65d55058bb796229f7e4a6c93055af20d674b2f)


Co-authored-by: Vi Koi Nguyen <Yim-Koi@users.noreply.huggingface.co>

Files changed (1) hide show
  1. app.py +13 -2
app.py CHANGED
@@ -120,11 +120,22 @@ With this initial analysis, beta was calculated to determine the stock’s risk
120
  price changes to the benchmark. By using CAPM model, annual expected return and portfolio
121
  return is calculated. The model results can be found in Appendix A.
122
  """
 
 
 
123
  ##### EDIT HERE ##### koi
 
 
 
 
 
 
 
 
 
 
124
  ef_viz(choices['data'],choices['choices'])
125
  ##### #####
126
- beta(choices['data'], choices['choices'])
127
- ER(choices['data'], choices['choices'])
128
  basic_portfolio(choices['combined_df'])
129
  display_heat_map(choices['data'],choices['choices'])
130
  #display_portfolio_return(choices['combined_df'], choices['choices'])
 
120
  price changes to the benchmark. By using CAPM model, annual expected return and portfolio
121
  return is calculated. The model results can be found in Appendix A.
122
  """
123
+
124
+ beta(choices['data'], choices['choices'])
125
+ ER(choices['data'], choices['choices'])
126
  ##### EDIT HERE ##### koi
127
+ st.header('CAPM Model and the Efficient Frontier')
128
+ """
129
+ CAPM model measures systematic risks, however many of it's functions has unrealistic assumptions and relies heavily on a linear interpretation
130
+ of the risks vs. returns relationship. It is better to use CAPM model in conjunction with the Efficient Frontier to better
131
+ graphically depict volatility (a measure of investment risk) for the defined rate of return. \n
132
+ Below we map the linear Utility function from the CAPM economic model along with the Efficient Frontier
133
+ Each circle depicted above is a variation of the portfolio with the same input assest, only different weights.
134
+ Portfolios with higher volatilities has a yellower shade of hue, while portfolios with a higher return has a bigger radius. \n
135
+ As you input different porfolio assets, take note of how diversification can improve a portfolio's risk versus reward profile.
136
+ """
137
  ef_viz(choices['data'],choices['choices'])
138
  ##### #####
 
 
139
  basic_portfolio(choices['combined_df'])
140
  display_heat_map(choices['data'],choices['choices'])
141
  #display_portfolio_return(choices['combined_df'], choices['choices'])