betaf {FinAna} | R Documentation |
Calculating beta for a company or a select of companies
Description
Calculating beta using common method or linear regression(OLS)
Usage
betaf(x,y,method)
Arguments
x |
:a vector or a data.frame of rate of return of companies |
y |
:name of the independent variable |
method |
:method of calculation; method = 1 for a common expression of beta(see detail); method = 2 using linear regression to estimate the beta |
Examples
#betaf(appl,sp500)
[Package FinAna version 0.1.2 Index]