简体   繁体   中英

Regress portfolio excess return

My data:

dput(head(mydata))
structure(list(DATE = structure(c(-315619200, -312940800, -310435200, 
-307756800, -305164800, -302486400), tzone = "UTC", class = c("POSIXct", 
"POSIXt")), RF = c(0.33, 0.29, 0.35, 0.19, 0.27, 0.24), RMRF = c(-6.99, 
0.99, -1.46, -1.7, 3.08, 2.09), SMB = c(2.13, 0.71, -0.65, 0.32, 
1.42, -0.24), UMD = c(-3.28, 3.59, 1.85, 2.6, 4.77, 1.03), HML = c(2.65, 
-2.15, -2.69, -2.22, -3.83, -0.3), JANDUM = c(1, 0, 0, 0, 0, 
0), R4 = c(-4.57, 1.5, -2.83, -1.98, 3.54, 2.15)), row.names = c(NA, 
-6L), class = c("tbl_df", "tbl", "data.frame"))

So, my data contain:

R4 is the percentage return of a portfolio, RF is the return of a good without risk (risk free rate), RMRF is the excess return of portfolio Market Portfolio, SMB, UMD, and HML are 3 factors, and JANDUM is a dummy variable for January (January Dummy).

The data is on a monthly frequency from 1/1960 to 12/2003 (there are 528 observations totaly).

Thats im trying to build and i am struggling is to Regress portfolio excess return (R4-RF) to one constant and all other variables (RMRF, SMB, UMD, HML, and JANDUM).

How can i achieve that?

Perhaps this will get you started?

mydata$PER <-mydata$R4 - mydata$RF 
mydata$JANDUM <- as.factor(mydata$JANDUM)
model <- lm(PER ~ DATE + RMRF + SMB + UMD + HML + JANDUM, data = mydata)
summary(model)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM