Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Description Write a program that calculates the CAPM Beta for a portfolio of at least 1 0 stocks. For the purposes of this assignment assume
Description
Write a program that calculates the CAPM Beta for a portfolio of at least stocks. For the purposes of
this assignment assume the stocks are equally weighted in the portfolio Calculate Beta
Read in remote stock data for a single stock
Get the market factor and risk free rate from Ken Frenchs data library and merge it onto the
stock information
Calculate the CAPM Beta using the data from the previous steps
A CAPM Function
Take the code from the first requirement and create a function that accepts a ticker, a beginning date, and an end date as inputs
The function should return the beta for the stock using the time interval specified
Portfolio Beta
Create a list of at least ten stocks that you will hold in a hypothetical portfolio
Use a loop and the CAPM function you wrote to calculate the beta of each of the stocks in
your hypothetical portfolio
Calculate the portfolio beta by combining the betas of the individual stocks using equal weights
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started