MVR {clim.pact} | R Documentation

## Multivariate regression analysis

### Description

Applies a multivariate regression (MVR) analysis to two data sets. The MVR here is based on the projection to obtain a least squares approximation and uses the formula of Strang (1988) "Linear Algebra and its applications", Harcourt Brace and Company, p. 156. The method is also documented in Benestad (1999) "MVR applied to Statistical Downscaling for prediction of Monthly Mean Land Surface Temperatures: Model Documentation", DNMI KLIMA Report 02/99 at http://met.no/english/r_and_d_activities/publications/1999.html.

For the expression

Ax=b

, then the projection of b onto the columns space of A through

p= A * inv[t(A) * A] * t(B) * b

.

### Usage

    MVR(x,y,plot=TRUE,main="Multivariate regression",sub="",test=FALSE,i.eofs=1:8,LINPACK=TRUE, SVD=TRUE)

### Arguments

`x` | A field or an eof object.
`y` | A field or an eof object.
`plot` | Flag: plot the diagnostics.
`test` | Flag: test by reconstructing one series (leading EOF or a grid-box series).
`i.eofs` | Which EOFs to include (only when the input is given as eof objects).
`LINPACK` | 'TRUE': svd; 'FALSE':La.svd
`main` | main title (see `link{plot}`).
`sub` | subtitle (see `link{plot}`).
`SVD` | Flag: determine which approach to use: SVD or eigenfunction-based alogithm.

### Value

A MVR object that is similar to a field or EOF object (inherits the object type, with an additional "MVR" label) with the projection (dat), but with additional fields such as the weights (psi, which is a map object) [dat represents p and psi represents x.hat in Strang (1988)].

### Author(s)

R.E. Benestad

### Examples

    ## Not run:
    data(DNMI.t2m)
    data(DNMI.slp)
    eof.1 <- EOF(DNMI.t2m,mon=1)
    eof.2 <- EOF(DNMI.slp,mon=1)
    mvr <- MVR(eof.1,eof.2)
    ## End(Not run)

[Package clim.pact version 2.2-1 Index]