[Gogarch-commits] r21 - in pkg: . R data man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Tue Feb 10 19:42:18 CET 2009
Author: bpfaff
Date: 2009-02-10 19:42:18 +0100 (Tue, 10 Feb 2009)
New Revision: 21
Added:
pkg/R/Goestica-ccor.R
pkg/R/Goestica-ccov.R
pkg/R/Goestica-coef.R
pkg/R/Goestica-converged.R
pkg/R/Goestica-cvar.R
pkg/R/Goestica-formula.R
pkg/R/Goestica-goest.R
pkg/R/Goestica-predict.R
pkg/R/Goestica-residuals.R
pkg/R/Goestica-show.R
pkg/R/Goestica-summary.R
pkg/R/Goestica-update.R
pkg/R/Goestmm-ccor.R
pkg/R/Goestmm-ccov.R
pkg/R/Goestmm-coef.R
pkg/R/Goestmm-converged.R
pkg/R/Goestmm-cvar.R
pkg/R/Goestmm-formula.R
pkg/R/Goestmm-predict.R
pkg/R/Goestmm-residuals.R
pkg/R/Goestmm-summary.R
pkg/R/Goestmm-update.R
pkg/data/BVDWAIR.rda
pkg/data/BVDWSTOXX.rda
pkg/man/BVDWAIR.Rd
pkg/man/BVDWSTOXX.Rd
pkg/man/Goestica-class.Rd
Modified:
pkg/DESCRIPTION
pkg/R/All-classes.R
pkg/R/GoGARCH-show.R
pkg/R/Goestmm-goest.R
pkg/R/Umatch.R
pkg/R/cora.R
pkg/R/gogarch.R
pkg/man/Goestmm-class.Rd
pkg/man/cora.Rd
pkg/man/gogarch.Rd
Log:
Classes, methods, functions and data sets added.
Modified: pkg/DESCRIPTION
===================================================================
--- pkg/DESCRIPTION 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/DESCRIPTION 2009-02-10 18:42:18 UTC (rev 21)
@@ -1,11 +1,11 @@
Package: gogarch
-Version: 0.4-8
+Version: 0.5-9
Type: Package
Title: Generalized Orthogonal GARCH (GO-GARCH) models
-Date: 2009-02-06
+Date: 2009-02-10
Author: Bernhard Pfaff
Maintainer: Bernhard Pfaff <bernhard at pfaffikus.de>
-Depends: R (>= 2.7.0), methods, stats, fGarch
+Depends: R (>= 2.7.0), methods, stats, fGarch, fastICA
Suggests: vars
Description: Implementation of the GO-GARCH model class
License: GPL (>= 2)
Modified: pkg/R/All-classes.R
===================================================================
--- pkg/R/All-classes.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/All-classes.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -11,6 +11,10 @@
##
setClass(Class = "GoGARCH", representation(Z = "matrix", U = "matrix", Y = "matrix", H = "list", models = "list", estby = "character", CALL = "call"), contains = "Goinit")
##
+## Class definition of GO-GARCH objects, estimated by ICA
+##
+setClass(Class = "Goestica", representation(ica = "list"), contains = "GoGARCH")
+##
## Class definition of GO-GARCH objects, estimated by Maximum-Likelihood
##
setClass(Class = "Goestml", representation(opt = "list"), contains = "GoGARCH")
Modified: pkg/R/GoGARCH-show.R
===================================================================
--- pkg/R/GoGARCH-show.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/GoGARCH-show.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -13,7 +13,7 @@
cat(paste("Formula for component GARCH models:", paste(as.character(object at garchf), collapse = " "), "\n"))
cat("\n")
if(length(object at U) != 0){
- cat("Orthonormal Matrix U:\n")
+ cat("Orthogonal Matrix U:\n")
print(object at U)
cat("\n")
cat("Linar Map Z:\n")
Added: pkg/R/Goestica-ccor.R
===================================================================
--- pkg/R/Goestica-ccor.R (rev 0)
+++ pkg/R/Goestica-ccor.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "ccor", signature(object = "Goestica"), definition = function(object){
+ ccor(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestica-ccov.R
===================================================================
--- pkg/R/Goestica-ccov.R (rev 0)
+++ pkg/R/Goestica-ccov.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "ccov", signature(object = "Goestica"), definition = function(object){
+ ccov(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestica-coef.R
===================================================================
--- pkg/R/Goestica-coef.R (rev 0)
+++ pkg/R/Goestica-coef.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,4 @@
+setMethod(f = "coef", signature(object = "Goestica"), definition = function(object){
+ callNextMethod()
+})
+
Added: pkg/R/Goestica-converged.R
===================================================================
--- pkg/R/Goestica-converged.R (rev 0)
+++ pkg/R/Goestica-converged.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "converged", signature(object = "Goestica"), definition = function(object){
+ converged(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestica-cvar.R
===================================================================
--- pkg/R/Goestica-cvar.R (rev 0)
+++ pkg/R/Goestica-cvar.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "cvar", signature(object = "Goestica"), definition = function(object){
+ cvar(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestica-formula.R
===================================================================
--- pkg/R/Goestica-formula.R (rev 0)
+++ pkg/R/Goestica-formula.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod("formula", signature(x = "Goestica"), function(x, ...)
+ x at garchf
+)
Added: pkg/R/Goestica-goest.R
===================================================================
--- pkg/R/Goestica-goest.R (rev 0)
+++ pkg/R/Goestica-goest.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,20 @@
+setMethod(f = "goest", signature(object = "Goestica"), definition = function(object, initial, garchlist, ...){
+ X <- object at X
+ m <- ncol(X)
+ n <- nrow(X)
+ P <- object at P
+ Id <- diag(m)
+ Dsqr <- object at Dsqr
+ ica <- fastICA(X, n.comp = m, ...)
+ W <- ica$W
+ Z <- P %*% Dsqr %*% t(P) %*% W
+ Zinv <- solve(Z)
+ Y <- X %*% Zinv
+ fitted <- apply(Y, 2, function(x) do.call("garchFit", c(list(formula = object at garchf, data = quote(x)), garchlist)))
+ H <- matrix(unlist(lapply(fitted, function(x) x at h.t)), ncol = m, nrow = n)
+ Hdf <- data.frame(t(H))
+ Ht <- lapply(Hdf, function(x) Z %*% diag(x) %*% t(Z))
+ names(Ht) <- rownames(object at X)
+ result <- new("Goestica", ica = ica, estby = "fast ICA", U = W, Z = Z, Y = Y, H = Ht, models = fitted, X = object at X, P = object at P, Dsqr = object at Dsqr, V = object at V, garchf = object at garchf, name = object at name)
+ return(result)
+})
Added: pkg/R/Goestica-predict.R
===================================================================
--- pkg/R/Goestica-predict.R (rev 0)
+++ pkg/R/Goestica-predict.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "predict", signature(object = "Goestica"), definition = function(object, n.ahead = 10, ...){
+ callNextMethod()
+})
Added: pkg/R/Goestica-residuals.R
===================================================================
--- pkg/R/Goestica-residuals.R (rev 0)
+++ pkg/R/Goestica-residuals.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,5 @@
+setMethod(f = "residuals", signature(object = "Goestica"), definition = function(object, standardize = FALSE){
+ callNextMethod(object = object, standardize = standardize)
+})
+
+
Added: pkg/R/Goestica-show.R
===================================================================
--- pkg/R/Goestica-show.R (rev 0)
+++ pkg/R/Goestica-show.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "show", signature(object = "Goestica"), definition = function(object){
+ callNextMethod()
+})
Added: pkg/R/Goestica-summary.R
===================================================================
--- pkg/R/Goestica-summary.R (rev 0)
+++ pkg/R/Goestica-summary.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "summary", signature(object = "Goestica"), definition = function(object){
+ callNextMethod()
+})
Added: pkg/R/Goestica-update.R
===================================================================
--- pkg/R/Goestica-update.R (rev 0)
+++ pkg/R/Goestica-update.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,17 @@
+setMethod("update", signature(object = "Goestica"), function(object, formula., ..., evaluate = TRUE){
+ call <- object at CALL
+ extras <- match.call(expand.dots = FALSE)$...
+ if (!missing(formula.))
+ call$formula <- update.formula(formula(object), formula.)
+ if (length(extras) > 0) {
+ existing <- !is.na(match(names(extras), names(call)))
+ for (a in names(extras)[existing]) call[[a]] <- extras[[a]]
+ if (any(!existing)) {
+ call <- c(as.list(call), extras[!existing])
+ call <- as.call(call)
+ }
+ }
+ if (evaluate)
+ eval(call, parent.frame())
+ else call
+})
Added: pkg/R/Goestmm-ccor.R
===================================================================
--- pkg/R/Goestmm-ccor.R (rev 0)
+++ pkg/R/Goestmm-ccor.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "ccor", signature(object = "Goestmm"), definition = function(object){
+ ccor(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestmm-ccov.R
===================================================================
--- pkg/R/Goestmm-ccov.R (rev 0)
+++ pkg/R/Goestmm-ccov.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "ccov", signature(object = "Goestmm"), definition = function(object){
+ ccov(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestmm-coef.R
===================================================================
--- pkg/R/Goestmm-coef.R (rev 0)
+++ pkg/R/Goestmm-coef.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,4 @@
+setMethod(f = "coef", signature(object = "Goestmm"), definition = function(object){
+ callNextMethod()
+})
+
Added: pkg/R/Goestmm-converged.R
===================================================================
--- pkg/R/Goestmm-converged.R (rev 0)
+++ pkg/R/Goestmm-converged.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "converged", signature(object = "Goestmm"), definition = function(object){
+ converged(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestmm-cvar.R
===================================================================
--- pkg/R/Goestmm-cvar.R (rev 0)
+++ pkg/R/Goestmm-cvar.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "cvar", signature(object = "Goestmm"), definition = function(object){
+ cvar(as(object, "GoGARCH"))
+})
Added: pkg/R/Goestmm-formula.R
===================================================================
--- pkg/R/Goestmm-formula.R (rev 0)
+++ pkg/R/Goestmm-formula.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod("formula", signature(x = "Goestmm"), function(x, ...)
+ x at garchf
+)
Modified: pkg/R/Goestmm-goest.R
===================================================================
--- pkg/R/Goestmm-goest.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/Goestmm-goest.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -6,8 +6,8 @@
P <- object at P
Id <- diag(m)
Dsqr <- object at Dsqr
- Dsqri <- diag(1 / diag(Dsqr))
- Sinv <- P %*% Dsqri %*% t(P)
+ S <- P %*% Dsqr %*% t(P)
+ Sinv <- solve(S)
S <- X %*% Sinv
if(lag.max < 1){
U <- Id
@@ -19,32 +19,24 @@
SSI[, , i] <- S[i, ] %*% t(S[i, ]) - diag(m)
}
Phil <- lapply(1:lag.max, function(x) cora(SSI, lag = x))
- svd <- lapply(Phil, function(x) svd(x))
+ svd <- lapply(Phil, function(x) eigen(x, symmetric = TRUE))
evmin <- unlist(lapply(svd, function(x){
sel <- combn(1:m, 2)
- diffs2 <- (x$d[sel[1, ]] - x$d[sel[2, ]])^2
+ diffs2 <- (x$values[sel[1, ]] - x$values[sel[2, ]])^2
min(diffs2)
}))
denom <- sum(evmin)
weights <- evmin / denom
- Ul <- lapply(svd, function(x) x$u)
+ Ul <- lapply(svd, function(x) x$vectors)
Ul[[1]] <- Umatch(Id, Ul[[1]])
Sm <- matrix(0, nrow = m, ncol = m)
for(i in 1:lag.max){
Ul[[i]] <- Umatch(Ul[[1]], Ul[[i]])
- mp <- Id + Ul[[i]]
- mpsvd <- svd(mp)
- mpinv <- mpsvd$u %*% diag(1/mpsvd$d) %*% t(mpsvd$u)
- mm <- Id - Ul[[i]]
- mmprod <- weights[i] * mm %*% mpinv
+ mmprod <- weights[i] * (Id - Ul[[i]]) %*% solve(Id + Ul[[i]])
Sm <- Sm + mmprod
}
Umatched <- Ul
- mp <- Id + Sm
- mpsvd <- svd(mp)
- mpinv <- mpsvd$u %*% diag(1/mpsvd$d) %*% t(mpsvd$u)
- mm <- Id - Sm
- U <- mm %*% mpinv
+ U <- (Id - Sm) %*% solve(Id + Sm)
}
Y <- S %*% U
Z <- P %*% Dsqr %*% t(P) %*% t(U)
Added: pkg/R/Goestmm-predict.R
===================================================================
--- pkg/R/Goestmm-predict.R (rev 0)
+++ pkg/R/Goestmm-predict.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "predict", signature(object = "Goestmm"), definition = function(object, n.ahead = 10, ...){
+ callNextMethod()
+})
Added: pkg/R/Goestmm-residuals.R
===================================================================
--- pkg/R/Goestmm-residuals.R (rev 0)
+++ pkg/R/Goestmm-residuals.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,5 @@
+setMethod(f = "residuals", signature(object = "Goestmm"), definition = function(object, standardize = FALSE){
+ callNextMethod(object = object, standardize = standardize)
+})
+
+
Added: pkg/R/Goestmm-summary.R
===================================================================
--- pkg/R/Goestmm-summary.R (rev 0)
+++ pkg/R/Goestmm-summary.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,3 @@
+setMethod(f = "summary", signature(object = "Goestmm"), definition = function(object){
+ callNextMethod()
+})
Added: pkg/R/Goestmm-update.R
===================================================================
--- pkg/R/Goestmm-update.R (rev 0)
+++ pkg/R/Goestmm-update.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,17 @@
+setMethod("update", signature(object = "Goestmm"), function(object, formula., ..., evaluate = TRUE){
+ call <- object at CALL
+ extras <- match.call(expand.dots = FALSE)$...
+ if (!missing(formula.))
+ call$formula <- update.formula(formula(object), formula.)
+ if (length(extras) > 0) {
+ existing <- !is.na(match(names(extras), names(call)))
+ for (a in names(extras)[existing]) call[[a]] <- extras[[a]]
+ if (any(!existing)) {
+ call <- c(as.list(call), extras[!existing])
+ call <- as.call(call)
+ }
+ }
+ if (evaluate)
+ eval(call, parent.frame())
+ else call
+})
Modified: pkg/R/Umatch.R
===================================================================
--- pkg/R/Umatch.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/Umatch.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -1,20 +1,16 @@
Umatch <- function(from, to){
cols <- ncol(from)
mat <- matrix(0, nrow = cols, ncol = cols)
- inner <- abs(colSums(from[, 1] * to))
- maxcol <- which.max(inner)
- mat[, 1] <- to[, maxcol]
- to <- as.matrix(to[, -maxcol])
- for(i in 2:cols){
+ for(i in 1:cols){
inner <- abs(colSums(from[, i] * to))
maxcol <- which.max(inner)
mat[, i] <- to[, maxcol]
- to <- as.matrix(to[, -maxcol])
+ to <- as.matrix(to[, -c(maxcol)])
}
signs <- matrix(sign(diag(mat)), nrow = cols, ncol = cols, byrow = TRUE)
- mat <- mat * signs
- if(det(mat) < 1.0){
- colminus <- which.min(abs(colSums(mat * from)))
+ mat <- signs * mat
+ if(det(mat) < 0.0){
+ colminus <- which.min(abs(colSums(from * mat)))
mat[, colminus] <- -1.0 * mat[, colminus]
}
return(mat)
Modified: pkg/R/cora.R
===================================================================
--- pkg/R/cora.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/cora.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -1,4 +1,4 @@
-cora <- function(SSI, lag = 1){
+cora <- function(SSI, lag = 1, standardize = TRUE){
lag <- abs(as.integer(lag))
dims <- dim(SSI)
Gamma <- matrix(0, nrow = dims[1], ncol = dims[2])
@@ -26,7 +26,11 @@
Gamma <- Gamma + SSIc[, , i]
}
Gamma <- Gamma / nl
- cora <- Gsqrtinv %*% Gamma %*% Gsqrtinv
+ if(standardize){
+ cora <- Gsqrtinv %*% Gamma %*% Gsqrtinv
+ } else {
+ cora <- Gamma
+ }
cora <- (cora + t(cora)) / 2
return(cora)
}
Modified: pkg/R/gogarch.R
===================================================================
--- pkg/R/gogarch.R 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/R/gogarch.R 2009-02-10 18:42:18 UTC (rev 21)
@@ -1,4 +1,4 @@
-gogarch <- function(data, formula, scale = FALSE, method = c("mm", "ml", "nls"), lag.max = 1, initial = NULL, garchlist = list(init.rec = "mci", delta = 2, skew = 1, shape = 4, cond.dist = "norm", include.mean = FALSE, include.delta = NULL, include.skew = NULL, include.shape = NULL, leverage = NULL, trace = FALSE, algorithm = "nlminb", hessian = "ropt", control = list(), title = NULL, description = NULL), ...){
+gogarch <- function(data, formula, scale = FALSE, method = c("ica", "mm", "ml", "nls"), lag.max = 1, initial = NULL, garchlist = list(init.rec = "mci", delta = 2, skew = 1, shape = 4, cond.dist = "norm", include.mean = FALSE, include.delta = NULL, include.skew = NULL, include.shape = NULL, leverage = NULL, trace = FALSE, algorithm = "nlminb", hessian = "ropt", control = list(), title = NULL, description = NULL), ...){
method <- match.arg(method)
Call <- match.call()
gini <- goinit(X = data, garchf = formula, scale = scale)
@@ -15,6 +15,10 @@
goestmm <- new("Goestmm", gomod)
gogarch <- goest(object = goestmm, lag.max = lag.max, garchlist = garchlist, ...)
}
+ if(method == "ica"){
+ goestica <- new("Goestica", gomod)
+ gogarch <- goest(object = goestica, initial = initial, garchlist = garchlist, ...)
+ }
gogarch at CALL <- Call
gogarch at name <- deparse(substitute(data))
return(gogarch)
Added: pkg/data/BVDWAIR.rda
===================================================================
(Binary files differ)
Property changes on: pkg/data/BVDWAIR.rda
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: pkg/data/BVDWSTOXX.rda
===================================================================
(Binary files differ)
Property changes on: pkg/data/BVDWSTOXX.rda
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: pkg/man/BVDWAIR.Rd
===================================================================
--- pkg/man/BVDWAIR.Rd (rev 0)
+++ pkg/man/BVDWAIR.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,56 @@
+\name{BVDWAIR}
+
+\alias{BVDWAIR}
+
+\encoding{latin1}
+
+\docType{data}
+
+\title{
+ Stock prices transportation sector, oil and kerosene prices
+}
+\description{
+ This data frame contains the stock prices from American Airlines,
+ South-West Airlines, Boeing and FedEx. In addition the spot prices for
+ crude oil and kerosene are included. This data set was used in the
+ article by Boswijk and van der Weide (2009). The data range is from
+ July, 19 1993 until August, 12 2008.
+}
+
+\usage{data(BVDWAIR)}
+\format{
+ A data frame with 3791 observations on the following 7 variables.
+
+ \describe{
+ \item{\code{Date}}{POSIXt: The dates of observations.}
+ \item{\code{CrudeOil}}{Crude oil price.}
+ \item{\code{Kerosene}}{Kerosene price.}
+ \item{\code{AmericanAir}}{Stock prices of American Airlines.}
+ \item{\code{SouthWest}}{Stock prices of South-West Airlines.}
+ \item{\code{Boeing}}{Stock prices of Boeing.}
+ \item{\code{FedEx}}{Stock prices of Boeing.}
+ }
+}
+
+\details{
+ The stock price data was downloaded from Yahoo Finance and the price
+ series for crude oil and kerosene were obtained from the U.S. Energy
+ Information Administration (EIA).
+}
+
+\source{
+ \url{http://finance.yahoo.com} and \url{http://www.econstats.com}
+}
+
+\references{
+ Boswijk, H. Peter and van der Weide, Roy (2009), Method of Moments
+ Estimation of GO-GARCH Models, \emph{Working Paper}, University of
+ Amsterdam, Tinbergen Institute and World Bank.
+}
+
+\examples{
+data(BVDWAIR)
+str(BVDWAIR)
+}
+
+\keyword{datasets}
Added: pkg/man/BVDWSTOXX.Rd
===================================================================
--- pkg/man/BVDWSTOXX.Rd (rev 0)
+++ pkg/man/BVDWSTOXX.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,59 @@
+\name{BVDWSTOXX}
+
+\encoding{latin1}
+
+\alias{BVDWSTOXX}
+
+\docType{data}
+
+\title{
+ Sector indices of the EURO STOXX 600
+}
+\description{
+ The data frame contains the following sector indices of the EURO STOXX
+ 600 index: Automobiles \& Parts, Banks, Basic Resources, Chemicals,
+ Construction and Materials, Financial Services, Food \& Beverages,
+ Health Care, Industrial Goods \& Services, Insurance, Media, Oil \&
+ Gas, Technology, Telecommunications and Utilities. The data range is
+ from 31th December 1986 until 21st November 2008.
+}
+
+\usage{data(BVDWSTOXX)}
+\format{
+ A data frame with 5652 observations on the following 16 variables.
+ \describe{
+ \item{\code{Date}}{POSIXt: The dates of observations.}
+ \item{\code{AutoParts}}{Sector index Automobiles \& Parts}
+ \item{\code{Banks}}{Sector index Banks}
+ \item{\code{BasicRes}}{Sector index Basic Resources}
+ \item{\code{Chemicals}}{Sector index Chemicals}
+ \item{\code{ConstrMat}}{Sector index Construction and Materials}
+ \item{\code{FoodBeverage}}{Sector index Food \& Beverages}
+ \item{\code{FinService}}{Sector index Financial Services}
+ \item{\code{HealthCare}}{Sector index Health Care}
+ \item{\code{IndustrialGoods}}{Sector index Industrial Goods \& Services}
+ \item{\code{Insurance}}{Sector index Insurance}
+ \item{\code{Media}}{Sector index Media}
+ \item{\code{OilGas}}{Sector index Oil \& Gas}
+ \item{\code{Technology}}{Sector index Technology}
+ \item{\code{Telecom}}{Sector index Telecommunications}
+ \item{\code{Utilities}}{Sector index Utilities}
+ }
+}
+
+\source{
+ \url{http://www.stoxx.com}
+}
+
+\references{
+ Boswijk, H. Peter and van der Weide, Roy (2009), Method of Moments
+ Estimation of GO-GARCH Models, \emph{Working Paper}, University of
+ Amsterdam, Tinbergen Institute and World Bank.
+}
+
+\examples{
+data(BVDWSTOXX)
+str(BVDWSTOXX)
+}
+
+\keyword{datasets}
Added: pkg/man/Goestica-class.Rd
===================================================================
--- pkg/man/Goestica-class.Rd (rev 0)
+++ pkg/man/Goestica-class.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -0,0 +1,102 @@
+\name{Goestica-class}
+
+\encoding{latin1}
+
+\docType{class}
+
+\alias{Goestica-class}
+\alias{cvar,Goestica-method}
+\alias{ccor,Goestica-method}
+\alias{ccov,Goestica-method}
+\alias{coef,Goestica-method}
+\alias{converged,Goestica-method}
+\alias{formula,Goestica-method}
+\alias{goest,Goestica-method}
+\alias{predict,Goestica-method}
+\alias{residuals,Goestica-method}
+\alias{show,Goestica-method}
+\alias{summary,Goestica-method}
+\alias{update,Goestica-method}
+
+\title{Class "Goestica": GO-GARCH models estimated by fast ICA}
+
+\description{
+ This class contains the \code{GoGARCH} class and has the mixing matrix
+ \eqn{A} as additional slot.
+}
+
+\section{Objects from the Class}{
+ Objects can be created by calls of the form \code{new("Goestmm", ...)},
+ or with the function \code{gogarch}.
+}
+
+\section{Slots}{
+ \describe{
+ \item{\code{ica}:}{Object of class \code{"list"}: List object
+ returned by \code{fastICA}.}
+ \item{\code{Z}:}{Object of class \code{"matrix"}: Transformation matrix.}
+ \item{\code{U}:}{Object of class \code{"matrix"}: Orthogonal matrix.}
+ \item{\code{Y}:}{Object of class \code{"matrix"}: Extracted
+ component matrix.}
+ \item{\code{H}:}{Object of class \code{"list"}: List of conditional
+ variance/covariance matrices.}
+ \item{\code{models}:}{Object of class \code{"list"}: List of
+ univariate GARCH model fits.}
+ \item{\code{estby}:}{Object of class \code{"character"}: Estimation method.}
+ \item{\code{X}:}{Object of class \code{"matrix"}: The data matrix.}
+ \item{\code{V}:}{Object of class \code{"matrix"}: Covariance matrix
+ of \code{X}.}
+ \item{\code{P}:}{Object of class \code{"matrix"}: Left singular
+ values of Var/Cov matrix of \code{X}.}
+ \item{\code{Dsqr}:}{Object of class \code{"matrix"}: Square roots of
+ eigenvalues on diagonal, else zero.}
+ \item{\code{garchf}:}{Object of class \code{"formula"}: Garch
+ formula used for uncorrelated component GARCH models.}
+ \item{\code{name}:}{Object of class \code{"character"}: The name of
+ the original data object.}
+ }
+}
+
+\section{Extends}{
+Class \code{"\linkS4class{GoGARCH}"}, directly.
+Class \code{"\linkS4class{Goinit}"}, by class "GoGARCH", distance 2.
+}
+
+\section{Methods}{
+ \describe{
+ \item{cvar}{Returns the conditional variances.}
+ \item{ccor}{Returns the conditional correlations.}
+ \item{ccov}{Returns the conditional covariances.}
+ \item{coef}{Returns the coeffiecients of the component GARCH models.}
+ \item{converged}{Returns the convergence codes of the component
+ GARCH models.}
+ \item{formula}{Returns the formula for the component GARCH models.}
+ \item{goest}{Fast ICA estimation of Go-GARCH models.}
+ \item{predict}{Returns the conditional covariances and mean
+ forecasts and the forecasts of the component GARCH models, object is
+ of class \code{Gopredict}.}
+ \item{residuals}{Returns the residuals of the component GARCH models.}
+ \item{show}{show-method for objects of class \code{Goestmm}.}
+ \item{summary}{summary-method for objects of class \code{Goestml},
+ object is of class \code{Gosum}.}
+ \item{update}{Updates an object of class \code{Goestml}.}
+ }
+}
+
+\references{
+ Broda, S.A. and Paolella, M.S. (2008): CHICAGO: A Fast and Accurate
+ Method for Portfolio Risk Calculation, \emph{Swiss Finance Institute},
+ Research Paper Series No. 08-08, Zuerich.
+}
+
+\author{
+ Bernhard Pfaff
+}
+
+\seealso{
+ \code{\linkS4class{GoGARCH}}, \code{\linkS4class{Goinit}},
+ \code{\linkS4class{Gosum}}, \code{\linkS4class{Gopredict}},
+ \code{\link{goest-methods}} and \code{\link{gogarch}}
+}
+
+\keyword{classes}
Modified: pkg/man/Goestmm-class.Rd
===================================================================
--- pkg/man/Goestmm-class.Rd 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/man/Goestmm-class.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -5,8 +5,18 @@
\docType{class}
\alias{Goestmm-class}
+\alias{cvar,Goestmm-method}
+\alias{ccor,Goestmm-method}
+\alias{ccov,Goestmm-method}
+\alias{coef,Goestmm-method}
+\alias{converged,Goestmm-method}
+\alias{formula,Goestmm-method}
+\alias{goest,Goestmm-method}
+\alias{predict,Goestmm-method}
+\alias{residuals,Goestmm-method}
\alias{show,Goestmm-method}
-\alias{goest,Goestmm-method}
+\alias{summary,Goestmm-method}
+\alias{update,Goestmm-method}
\title{Class "Goestmm": Go-GARCH models estimated by Methods of Moments}
@@ -57,8 +67,22 @@
\section{Methods}{
\describe{
+ \item{cvar}{Returns the conditional variances.}
+ \item{ccor}{Returns the conditional correlations.}
+ \item{ccov}{Returns the conditional covariances.}
+ \item{coef}{Returns the coeffiecients of the component GARCH models.}
+ \item{converged}{Returns the convergence codes of the component
+ GARCH models.}
+ \item{formula}{Returns the formula for the component GARCH models.}
\item{goest}{Methods of moments estimation of Go-GARCH models.}
- \item{show}{show-method for objects of class \code{Goestnls}.}
+ \item{predict}{Returns the conditional covariances and mean
+ forecasts and the forecasts of the component GARCH models, object is
+ of class \code{Gopredict}.}
+ \item{residuals}{Returns the residuals of the component GARCH models.}
+ \item{show}{show-method for objects of class \code{Goestmm}.}
+ \item{summary}{summary-method for objects of class \code{Goestml},
+ object is of class \code{Gosum}.}
+ \item{update}{Updates an object of class \code{Goestml}.}
}
}
Modified: pkg/man/cora.Rd
===================================================================
--- pkg/man/cora.Rd 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/man/cora.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -15,11 +15,15 @@
}
\usage{
-cora(SSI, lag = 1)
+cora(SSI, lag = 1, standardize = TRUE)
}
\arguments{
\item{SSI}{Array with dimension \code{dim = c(m, m, n)}}
- \item{lag}{Integer, the lag for which the autocorrelation is computed.}
+ \item{lag}{Integer, the lag for which the autocorrelation is
+ computed.}
+ \item{standardize}{Logical, if \code{TRUE} (the default), the
+ autocorrelation matrix is computed, otherwise the autocovariance
+ matrix.}
}
\details{
Modified: pkg/man/gogarch.Rd
===================================================================
--- pkg/man/gogarch.Rd 2009-02-07 14:02:30 UTC (rev 20)
+++ pkg/man/gogarch.Rd 2009-02-10 18:42:18 UTC (rev 21)
@@ -13,7 +13,7 @@
models.
}
\usage{
-gogarch(data, formula, scale = FALSE, method = c("mm", "ml", "nls"),
+gogarch(data, formula, scale = FALSE, method = c("ica", "mm", "ml", "nls"),
lag.max = 1, initial = NULL, garchlist = list(init.rec = "mci", delta
= 2, skew = 1, shape = 4, cond.dist = "norm", include.mean = FALSE,
include.delta = NULL, include.skew = NULL, include.shape = NULL,
@@ -26,9 +26,10 @@
\item{formula}{Formula: valid formula for univariate GARCH models.}
\item{scale}{Logical, if \code{TRUE} the data is scaled. The default
is \code{scale = FALSE}.}
- \item{method}{Character: by Methods of Moments \code{method = "mm"}
- (the default) or by Maximum-Likelihood \code{method = "ml"} or by
- non-linear Least-Squares \code{method = "nls"}.}
+ \item{method}{Character: by fast ICA \code{method = "ica"} (the
+ default), by Methods of Moments \code{method = "mm"} or by
+ Maximum-Likelihood \code{method = "ml"} or by non-linear Least-Squares
+ \code{method = "nls"}.}
\item{initial}{Numeric: starting values for optimization (used if
\code{method = "ml"} or \code{method = "nls"} has been chosen (see
Details).}
@@ -68,6 +69,10 @@
Boswijk, H. Peter and van der Weide, Roy (2009), Method of Moments
Estimation of GO-GARCH Models, \emph{Working Paper}, University of
Amsterdam, Tinbergen Institute and World Bank.
+
+ Broda, S.A. and Paolella, M.S. (2008): CHICAGO: A Fast and Accurate
+ Method for Portfolio Risk Calculation, \emph{Swiss Finance Institute},
+ Research Paper Series No. 08-08, Zuerich.
}
\author{
More information about the Gogarch-commits
mailing list