[Uwgarp-commits] r52 - pkg/GARPFRM/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Jan 24 21:12:50 CET 2014
Author: tfillebeen
Date: 2014-01-24 21:12:49 +0100 (Fri, 24 Jan 2014)
New Revision: 52
Modified:
pkg/GARPFRM/R/capm.R
Log:
df respecified
Modified: pkg/GARPFRM/R/capm.R
===================================================================
--- pkg/GARPFRM/R/capm.R 2014-01-24 18:50:12 UTC (rev 51)
+++ pkg/GARPFRM/R/capm.R 2014-01-24 20:12:49 UTC (rev 52)
@@ -191,7 +191,7 @@
tmp_A = tmp_sm[1,3] < CI
tstat = (tmp_sm[2,2] - 1 )/tmp_sm[2,3]
#' Two sided t-test
- tmp_B = (2*(1 - pt(abs(tstat),df=nrow(object$x_data)-2))) < CI
+ tmp_B = (2*(1 - pt(abs(tstat),df=nrow(object$x_data)-ncol(object$y_data)))) < CI
result = c(tmp_A, tmp_B)
result = as.matrix(result)
rownames(result) = cbind(c(paste("alpha.", colnames(object$y_data))),c(paste("beta. ", colnames(object$y_data))))
@@ -206,7 +206,7 @@
tmp_A = tmp_sm[seq(1,nrow(tmp_sm),2),4] < CI
tstat = (tmp_sm[seq(2,nrow(tmp_sm),2),1] - 1 )/tmp_sm[seq(2,nrow(tmp_sm),2),2]
#' Two sided t-test
- tmp_B = (2*(1 - pt(abs(tstat),df=nrow(object$x_data)-2))) < CI
+ tmp_B = (2*(1 - pt(abs(tstat),df=nrow(object$x_data)-ncol(object$y_data)))) < CI
result = c(tmp_A, tmp_B)
return(result)
}
\ No newline at end of file
More information about the Uwgarp-commits
mailing list