[Returnanalytics-commits] r3417 - pkg/FactorAnalytics/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Jun 13 01:31:38 CEST 2014
Author: gyollin
Date: 2014-06-13 01:31:38 +0200 (Fri, 13 Jun 2014)
New Revision: 3417
Modified:
pkg/FactorAnalytics/R/factorModelMonteCarlo.R
Log:
Edits to support new function signature of the rst function from the sn package
Modified: pkg/FactorAnalytics/R/factorModelMonteCarlo.R
===================================================================
--- pkg/FactorAnalytics/R/factorModelMonteCarlo.R 2014-06-11 20:19:10 UTC (rev 3416)
+++ pkg/FactorAnalytics/R/factorModelMonteCarlo.R 2014-06-12 23:31:38 UTC (rev 3417)
@@ -77,7 +77,7 @@
#' # skew-t distribution
#' # build residualData matrix
#' residualData <- cbind(rnorm(6),c(1,2,1,3,0.1,0.5),rnorm(6),c(2,3,1,6,10,100))
-#' colnames(residualData) <- c("location","scale","shape","df")
+#' colnames(residualData) <- c("xi","omega","alpha","nu")
#' rownames(residualData) <- colnames(managers.df[,(1:6)])
#' bootData <- factorModelMonteCarlo(n.boot, factorData,Beta.mat, residual.dist="skew-t",
#' residualData, Alpha.mat=NULL, boot.method="random",
@@ -133,10 +133,10 @@
"ekurt"])
}
else if (residual.dist == "skew-t") {
- residualsSim[, i] = rst(n.boot, location = residualData[i,
- "location"], scale = residualData[i, "scale"],
- shape = residualData[i, "shape"], df = residualData[i,
- "df"])
+ residualsSim[, i] = rst(n.boot, xi = residualData[i,
+ "xi"], omega = residualData[i, "omega"],
+ alpha = residualData[i, "alpha"], nu = residualData[i,
+ "nu"])
}
else {
stop("Invalid residual distribution")
More information about the Returnanalytics-commits
mailing list