[Returnanalytics-commits] r2253 - in pkg/PerformanceAnalytics/sandbox/Meucci: . R man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Aug 20 00:16:28 CEST 2012


Author: mkshah
Date: 2012-08-20 00:16:28 +0200 (Mon, 20 Aug 2012)
New Revision: 2253

Added:
   pkg/PerformanceAnalytics/sandbox/Meucci/man/FitOU.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/GenFirstEigVect.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/GenPCBasis.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/MaxEntropy.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/MeanTCEntropyFrontier.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstep.Rd
   pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstepEuler.Rd
Removed:
   pkg/PerformanceAnalytics/sandbox/Meucci/R/EmpiricalMultivariateOUnCointegration.R
   pkg/PerformanceAnalytics/sandbox/Meucci/R/TheoryMultivariateOUnCointegration.R
Modified:
   pkg/PerformanceAnalytics/sandbox/Meucci/00index
   pkg/PerformanceAnalytics/sandbox/Meucci/DESCRIPTION
   pkg/PerformanceAnalytics/sandbox/Meucci/R/MeanDiversificationFrontier.R
   pkg/PerformanceAnalytics/sandbox/Meucci/R/MultivariateOUnCointegration.R
Log:
Updating documentation

Modified: pkg/PerformanceAnalytics/sandbox/Meucci/00index
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/00index	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/00index	2012-08-19 22:16:28 UTC (rev 2253)
@@ -15,9 +15,13 @@
 efficientFrontier                   Construct the mean-variance efficient frontier using a quadratic solver
 EntropyProg                         Entropy pooling program for blending views on scenarios with a prior
                                     scenario-probability distribution
+FitOU                               Fit the Ornstein-uhlenbeck process to model the behavior for different
+                                    values of the timestep.
 gaussHermiteMesh                    Generates grid reprensentation of a distribution according to the
                                     method suggested by Meucci and inspired from Gauss-Hermite quadratures.
 GenerateLogNormalDistribution       Generate arbitrary distribution of a shifted-lognormal invariant
+GenFirstEigVect                     This function generates the first eigen vector
+GenPCBasis                          This function computes the conditional principal portfolios
 hermitePolynomial                   Generate a Hermite Polynomial of order n
 integrateSubIntervals               Integrate the subinterval for the given cumulative distribution
                                     function to get the equivalent probability
@@ -29,11 +33,17 @@
 kernelpdf                           Evaluates probability distribution function for the input numeric value
 linreturn                           Generate arithmetric returns and arithmetric covariance matrix given a
                                     distribution of log returns
+MaxEntropy                          This function computes the extreme frontier
+MeanTCEntropyFrontier               This function computes the mean diversification efficient frontier
 MvnRnd                              Generates normal simulations whose sample moments match the population
                                     moments
 NoisyObservations                   Generate observations from a two asset covariance matrix and add
                                     outliers
 normalizeProb                       Generates the normalized probability for an input probability value
+OUstep                              Generate the next element based on Ornstein-Uhlenbeck Process
+OUstepEuler                         Generate the next element based on Ornstein-Uhlenbeck process using
+                                    antithetic concept and assuming that the Brownian motion has Euler
+                                    discretization
 PanicCopula                         Copula-Marginal Algorithm (CMA)
 PartialConfidencePosterior          Constructs the partial confidence posterior based on a prior, sample
                                     mu/covariance, and relative confidence in the prior

Modified: pkg/PerformanceAnalytics/sandbox/Meucci/DESCRIPTION
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/DESCRIPTION	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/DESCRIPTION	2012-08-19 22:16:28 UTC (rev 2253)
@@ -1,35 +1,37 @@
-Package: Meucci
-Type: Package
-Title: Econometric tools for performance and risk analysis.
-Version: 0.1
-Date: $Date: 2012-06-06 15:18:48 -0500 (Wed, 06 Jun 2012) $
-Author: Ram Ahluwalia, Manan Shah
-Maintainer: Brian G. Peterson <brian at braverock.com>
-Description: stub for Meucci
-Depends:
-    R (>= 2.14.0),
-    zoo,
-    xts (>= 0.8),
-    matlab,
-    ggplot2,
-    MASS,
-    pracma,
-    Hmisc,
-    Matrix,
-    nloptr,
-    limSolve,moments,
-    quadprog
-License: GPL
-URL: http://r-forge.r-project.org/projects/returnanalytics/
-Copyright: (c) 2004-2012
-Collate:
-    'CmaCopula.R'
-    'DetectOutliersviaMVE.R'
-    'EntropyProg.R'
-    'FullyFlexibleBayesNets.R'
-    'HermiteGrid.R'
-    'InvariantProjection.R'
-    'logToArithmeticCovariance.R'
-    'Prior2Posterior.R'
-    'RankingInformation.R'
-    'RobustBayesianAllocation.R'
+Package: Meucci
+Type: Package
+Title: Econometric tools for performance and risk analysis.
+Version: 0.1
+Date: $Date: 2012-06-06 15:18:48 -0500 (Wed, 06 Jun 2012) $
+Author: Ram Ahluwalia, Manan Shah
+Maintainer: Brian G. Peterson <brian at braverock.com>
+Description: stub for Meucci
+Depends:
+    R (>= 2.14.0),
+    zoo,
+    xts (>= 0.8),
+    matlab,
+    ggplot2,
+    MASS,
+    pracma,
+    Hmisc,
+    Matrix,
+    nloptr,
+    limSolve,moments,
+    quadprog
+License: GPL
+URL: http://r-forge.r-project.org/projects/returnanalytics/
+Copyright: (c) 2004-2012
+Collate:
+    'CmaCopula.R'
+    'DetectOutliersviaMVE.R'
+    'EntropyProg.R'
+    'FullyFlexibleBayesNets.R'
+    'HermiteGrid.R'
+    'InvariantProjection.R'
+    'logToArithmeticCovariance.R'
+    'Prior2Posterior.R'
+    'RankingInformation.R'
+    'RobustBayesianAllocation.R'
+    'MeanDiversificationFrontier.R'
+    'MultivariateOUnCointegration.R'
\ No newline at end of file

Deleted: pkg/PerformanceAnalytics/sandbox/Meucci/R/EmpiricalMultivariateOUnCointegration.R
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/R/EmpiricalMultivariateOUnCointegration.R	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/R/EmpiricalMultivariateOUnCointegration.R	2012-08-19 22:16:28 UTC (rev 2253)
@@ -1,78 +0,0 @@
-FitOU = function ( Y, tau )
-{
-  library(expm)
-  T = nrow( Y )
-  N = ncol( Y )
-
-  X = Y[ -1 , ]
-  F = cbind( rep( 1, T-1 ), Y [ 1:T-1 ,] )
-  E_XF = t( X ) %*% F / T
-  E_FF = t( F ) %*% F / T
-  B = E_XF %*% solve( E_FF )
-
-  Th = -logm ( B [ , -1 ] ) / tau
-  Mu = solve( diag( N ) - B[ , -1 ] ) %*% B[ , 1 ]
-
-  U = F %*% t( B ) - X
-  Sig_tau = cov( U )
-
-  N = length( Mu )
-  TsT = kronecker( Th , diag( N ) ) + kronecker( diag( N ) , Th )
-
-  VecSig_tau = Sig_tau
-  dim( VecSig_tau ) = c( N^2 , 1 )
-  VecSig = solve( diag( N^2 ) - expm( as.matrix( -TsT * tau ) ) ) %*% TsT %*% VecSig_tau
-  Sig = VecSig
-  dim( Sig ) = c( N , N )
-  
-  return( list( Mu = Mu, Th = Th, Sig = Sig ) )
-}
-
-OUstep = function( X_0 , t , Mu , Th , Sig )
-{
-  NumSimul = nrow( X_0 )
-  N = ncol( X_0 )
-
-  # location
-  ExpM = expm( as.matrix ( -Th * t ) )
-  
-  # repmat = function(X,m,n) - R equivalent of repmat (matlab)
-  X = t( Mu - ExpM %*% Mu )
-  mx = dim( X )[1]
-  nx = dim( X )[2]
-  Mu_t = matrix( t ( matrix( X , mx , nx*1 ) ), mx * NumSimul, nx * 1, byrow = T ) + X_0 %*% ExpM
-              
-  # scatter
-  TsT = kronecker( Th , diag( N ) ) + kronecker( diag( N ) , Th )
-              
-  VecSig = Sig
-  dim( VecSig ) = c( N^2 , 1 )
-  VecSig_t = solve( TsT ) %*% ( diag( N^2 ) - expm( as.matrix( -TsT * t ) ) ) %*% VecSig
-  Sig_t = VecSig_t
-  dim( Sig_t ) = c( N , N )
-  Sig_t = ( Sig_t + t( Sig_t ) ) / 2
-
-  Eps = mvrnorm( NumSimul, rep( 0 , N ), Sig_t )
-                     
-  X_t = Mu_t + Eps
-  Mu_t = t( colMeans( Mu_t ) )
-  
-  return( list( X_t = X_t, Mu_t = Mu_t, Sig_t = Sig_t ) )
-}
-
-ProjectOU = function( x_0 , t , Mu , Th , Sig )
-{
-  N = length( x_0 )
-
-  # location
-  Mu_t = Mu + expm( as.matrix( -Th * t ) ) %*% ( x_0 - Mu )
-
-  # scatter
-  TsT = kronecker( Th , diag( N ) ) + kronecker( diag( N ) , Th )
-
-  VecSig = Sig
-  dim( VecSig ) = c( N^2 , 1 )
-  VecSig_t = solve( TsT ) %*% ( diag( N^2 ) - expm( as.matrix( -TsT * t ) ) ) %*% VecSig
-  Sig_t = VecSig_t
-  dim( Sig_t ) = c( N , N )
-}
\ No newline at end of file

Modified: pkg/PerformanceAnalytics/sandbox/Meucci/R/MeanDiversificationFrontier.R
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/R/MeanDiversificationFrontier.R	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/R/MeanDiversificationFrontier.R	2012-08-19 22:16:28 UTC (rev 2253)
@@ -38,6 +38,7 @@
 #' @return E    a matrix containing conditional principal portfolios composition
 #' @return L    a matrix containing conditional principal portfolios variances
 #' @return G    map weights -> conditional diversification distribution (square root of, not normalized)
+#'
 #' \deqn{ e_{n}  \equiv   argmax_{ e'e  \equiv 1 }  \big\{ e' \Sigma e \big\} s.t.  e' \Sigma  e_{j}  \equiv 0 }
 #' @references 
 #' A. Meucci - "Managing Diversification", Risk Magazine, June 2009 - Formula (12)
@@ -104,6 +105,7 @@
 #' @param Constr  a list containing the equality and inequality constraints
 #'
 #' @return x      a numeric containing the maximum entropy
+#'
 #' \deqn{  N_{ent}  \equiv exp \big(-\sum_{n=k+1}^N  p_{n} ln p_{n}  \big),
 #'  w_{  \varphi }  \equiv  argmax_{w \in C,   \mu'w  \geq  \varphi  }  N_{ent}   \big(w\big) }
 #' @references 

Modified: pkg/PerformanceAnalytics/sandbox/Meucci/R/MultivariateOUnCointegration.R
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/R/MultivariateOUnCointegration.R	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/R/MultivariateOUnCointegration.R	2012-08-19 22:16:28 UTC (rev 2253)
@@ -53,7 +53,7 @@
 #' Brownian motion has Euler discretization
 #' 
 #' @param X_0   a matrix containing the starting value of each process
-#' @param t     a numeric containing the timestep   
+#' @param Dt     a numeric containing the timestep   
 #' @param Mu    a vector containing the unconditional expectation of the process
 #' @param Th    a transition matrix, i.e., a fully generic square matrix that steers the deterministic portion
 #'              of the evolution of the process

Deleted: pkg/PerformanceAnalytics/sandbox/Meucci/R/TheoryMultivariateOUnCointegration.R
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/R/TheoryMultivariateOUnCointegration.R	2012-08-19 21:49:52 UTC (rev 2252)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/R/TheoryMultivariateOUnCointegration.R	2012-08-19 22:16:28 UTC (rev 2253)
@@ -1,54 +0,0 @@
-OUstep = function( X_0 , t , Mu , Th , Sig )
-{
-  NumSimul = nrow( X_0 )
-  N = ncol( X_0 )
-  
-  # location
-  ExpM = expm( -Th * t )
-  
-  # repmat = function(X,m,n) - R equivalent of repmat (matlab)
-  X = t( Mu - ExpM %*% Mu )
-  mx = dim( X )[1]
-  nx = dim( X )[2]
-  Mu_t = matrix( t ( matrix( X , mx , nx*1 ) ), mx * NumSimul, nx * 1, byrow = T ) + X_0 %*% ExpM
-  
-  # scatter
-  TsT = kronecker( Th , diag( N ) ) + kronecker( diag( N ) , Th )
-  
-  VecSig = Sig
-  dim( VecSig ) = c( N^2 , 1 )
-  VecSig_t = solve( TsT ) %*% ( diag( N^2 ) - expm( -TsT * t ) ) %*% VecSig
-  Sig_t = VecSig_t
-  dim( Sig_t ) = c( N , N )
-  Sig_t = ( Sig_t + t( Sig_t ) ) / 2
-  
-  Eps = mvrnorm( NumSimul, rep( 0 , N ), Sig_t )
-  
-  X_t = Mu_t + Eps
-  Mu_t = t( colMeans( Mu_t ) )
-  
-  return( list( X_t = X_t, Mu_t = Mu_t, Sig_t = Sig_t ) )
-}
-
-OUstepEuler = function( X_0 , Dt , Mu , Th , Sig )
-{
-  NumSimul = nrow( X_0 )
-  N = ncol( X_0 )
-
-  # location
-  ExpM = expm( as.matrix( -Th %*% Dt ) )
-
-  # repmat = function(X,m,n) - R equivalent of repmat (matlab)
-  X = t( Mu - ExpM %*% Mu )
-  mx = dim( X )[1]
-  nx = dim( X )[2]
-  Mu_t = matrix( t ( matrix( X , mx , nx*1 ) ), mx * NumSimul, nx * 1, byrow = T ) + X_0 %*% ExpM
-              
-  # scatter
-  Sig_t = Sig %*% Dt
-  Eps = mvrnorm( NumSimul / 2, rep( 0 , N ) , Sig_t )
-  Eps = rbind( Eps, -Eps)
-              
-  X_t = Mu_t + Eps
-  Mu_t = t( colMeans( X_t ) )
-}
\ No newline at end of file

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/FitOU.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/FitOU.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/FitOU.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,42 @@
+\name{FitOU}
+\alias{FitOU}
+\title{Fit the Ornstein-uhlenbeck process to model the behavior for different values of the timestep.}
+\usage{
+  FitOU(Y, tau)
+}
+\arguments{
+  \item{Y}{a matrix containing the value of a process at
+  various time steps.}
+
+  \item{tau}{a numeric containing the timestep}
+}
+\value{
+  a list containing
+
+  Mu a vector containing the expectation of the process
+
+  Sig a matrix containing the covariance of the resulting
+  fitted OU process
+
+  Th a transition matrix required for defining the fitted
+  OU process
+
+  \deqn{ x_{t+ \tau } = \big(I- e^{- \theta \tau } \big)
+  \mu + e^{- \theta \tau } x_{t}, vec \big( \Sigma _{ \tau
+  } \big) \equiv \big( \Theta \oplus \Theta \big) ^{-1}
+  \big(I- e^{( \Theta \oplus \Theta ) \tau } \big) vec
+  \big( \Sigma \big) }
+}
+\description{
+  Fit the Ornstein-uhlenbeck process to model the behavior
+  for different values of the timestep.
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Review of Statistical Arbitrage,
+  Cointegration, and Multivariate Ornstein-Uhlenbeck" -
+  Formula (8),(9) \url{http://ssrn.com/abstract=1404905}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/GenFirstEigVect.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/GenFirstEigVect.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/GenFirstEigVect.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,25 @@
+\name{GenFirstEigVect}
+\alias{GenFirstEigVect}
+\title{This function generates the first eigen vector}
+\usage{
+  GenFirstEigVect(S, A)
+}
+\arguments{
+  \item{S}{Covariance Matrix}
+
+  \item{A}{Conditioning Matrix}
+}
+\value{
+  e First Eigen Vector
+}
+\description{
+  This function generates the first eigen vector
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Managing Diversification", Risk Magazine,
+  June 2009 \url{http://ssrn.com/abstract=1358533}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/GenPCBasis.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/GenPCBasis.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/GenPCBasis.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,39 @@
+\name{GenPCBasis}
+\alias{GenPCBasis}
+\title{This function computes the conditional principal portfolios}
+\usage{
+  GenPCBasis(S, A)
+}
+\arguments{
+  \item{S}{Covariance Matrix}
+
+  \item{A}{Conditioning Matrix}
+}
+\value{
+  a list containing
+
+  E a matrix containing conditional principal portfolios
+  composition
+
+  L a matrix containing conditional principal portfolios
+  variances
+
+  G map weights -> conditional diversification distribution
+  (square root of, not normalized)
+
+  \deqn{ e_{n} \equiv argmax_{ e'e \equiv 1 } \big\{ e'
+  \Sigma e \big\} s.t.  e' \Sigma e_{j} \equiv 0 }
+}
+\description{
+  This function computes the conditional principal
+  portfolios
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Managing Diversification", Risk Magazine,
+  June 2009 - Formula (12)
+  \url{http://ssrn.com/abstract=1358533}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/MaxEntropy.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/MaxEntropy.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/MaxEntropy.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,37 @@
+\name{MaxEntropy}
+\alias{MaxEntropy}
+\title{This function computes the extreme frontier}
+\usage{
+  MaxEntropy(G, w_b, w_0, Constr)
+}
+\arguments{
+  \item{G}{map weights -> conditional diversification
+  distribution (square root of, not normalized)}
+
+  \item{w_b}{a matrix containing the benchmark weights}
+
+  \item{w_0}{a matrix containing the initial portfolio
+  weights}
+
+  \item{Constr}{a list containing the equality and
+  inequality constraints}
+}
+\value{
+  x a numeric containing the maximum entropy
+
+  \deqn{ N_{ent} \equiv exp \big(-\sum_{n=k+1}^N p_{n} ln
+  p_{n} \big), w_{ \varphi } \equiv argmax_{w \in C, \mu'w
+  \geq \varphi } N_{ent} \big(w\big) }
+}
+\description{
+  This function computes the extreme frontier
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Managing Diversification", Risk Magazine,
+  June 2009 - Formula (18,19)
+  \url{http://ssrn.com/abstract=1358533}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/MeanTCEntropyFrontier.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/MeanTCEntropyFrontier.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/MeanTCEntropyFrontier.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,44 @@
+\name{MeanTCEntropyFrontier}
+\alias{MeanTCEntropyFrontier}
+\title{This function computes the mean diversification efficient frontier}
+\usage{
+  MeanTCEntropyFrontier(S, Mu, w_b, w_0, Constr)
+}
+\arguments{
+  \item{S}{Covariance Matrix}
+
+  \item{Mu}{a matrix containing the expectations}
+
+  \item{w_b}{a matrix containing the benchmark weights}
+
+  \item{w_0}{a matrix containing the initial portfolio
+  weights}
+
+  \item{Constr}{a list containing the equality and
+  inequality constraints}
+}
+\value{
+  a list containing
+
+  Weights
+
+  Ne_s
+
+  R_2_s
+
+  m_s
+
+  s_S
+}
+\description{
+  This function computes the mean diversification efficient
+  frontier
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Managing Diversification", Risk Magazine,
+  June 2009 \url{http://ssrn.com/abstract=1358533}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstep.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstep.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstep.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,50 @@
+\name{OUstep}
+\alias{OUstep}
+\title{Generate the next element based on Ornstein-Uhlenbeck Process}
+\usage{
+  OUstep(X_0, t, Mu, Th, Sig)
+}
+\arguments{
+  \item{X_0}{a matrix containing the starting value of each
+  process}
+
+  \item{t}{a numeric containing the timestep}
+
+  \item{Mu}{a vector containing the unconditional
+  expectation of the process}
+
+  \item{Th}{a transition matrix, i.e., a fully generic
+  square matrix that steers the deterministic portion of
+  the evolution of the process}
+
+  \item{Sig}{a square matrix that drives the dispersion of
+  the process}
+}
+\value{
+  a list containing
+
+  X_t a vector containing the value of the process after
+  the given timestep
+
+  Mu_t a vector containing the conditional expectation of
+  the process
+
+  Sig_t a matrix containing the covariance after the time
+  step
+
+  \deqn{ X_{t+ \tau } = \big(I- e^{- \theta \tau } \big)
+  \mu + e^{- \theta \tau } X_{t} + \epsilon _{t, \tau } }
+}
+\description{
+  Generate the next element based on Ornstein-Uhlenbeck
+  Process
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Review of Statistical Arbitrage,
+  Cointegration, and Multivariate Ornstein-Uhlenbeck" -
+  Formula (2) \url{http://ssrn.com/abstract=1404905}
+}
+

Added: pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstepEuler.Rd
===================================================================
--- pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstepEuler.Rd	                        (rev 0)
+++ pkg/PerformanceAnalytics/sandbox/Meucci/man/OUstepEuler.Rd	2012-08-19 22:16:28 UTC (rev 2253)
@@ -0,0 +1,52 @@
+\name{OUstepEuler}
+\alias{OUstepEuler}
+\title{Generate the next element based on Ornstein-Uhlenbeck process using antithetic concept and assuming that the
+Brownian motion has Euler discretization}
+\usage{
+  OUstepEuler(X_0, Dt, Mu, Th, Sig)
+}
+\arguments{
+  \item{X_0}{a matrix containing the starting value of each
+  process}
+
+  \item{Dt}{a numeric containing the timestep}
+
+  \item{Mu}{a vector containing the unconditional
+  expectation of the process}
+
+  \item{Th}{a transition matrix, i.e., a fully generic
+  square matrix that steers the deterministic portion of
+  the evolution of the process}
+
+  \item{Sig}{a square matrix that drives the dispersion of
+  the process}
+}
+\value{
+  a list containing
+
+  X_t a vector containing the value of the process after
+  the given timestep
+
+  Mu_t a vector containing the conditional expectation of
+  the process
+
+  Sig_t a matrix containing the covariance after the time
+  step
+
+  \deqn{ X_{t+ \tau } = \big(I- e^{- \theta \tau } \big)
+  \mu + e^{- \theta \tau } X_{t} + \epsilon _{t, \tau } }
+}
+\description{
+  Generate the next element based on Ornstein-Uhlenbeck
+  process using antithetic concept and assuming that the
+  Brownian motion has Euler discretization
+}
+\author{
+  Manan Shah \email{mkshah at cmu.edu}
+}
+\references{
+  A. Meucci - "Review of Statistical Arbitrage,
+  Cointegration, and Multivariate Ornstein-Uhlenbeck" -
+  Formula (2) \url{http://ssrn.com/abstract=1404905}
+}
+



More information about the Returnanalytics-commits mailing list