Positively constrained least squares with a multivariate response | R Documentation |
Positively constrained least squares with a multivariate response.
mvpls(y, x)
y |
The response variables, a numerical matrix with observations. |
x |
A matrix with independent variables, the design matrix. |
The constraint is that all beta coefficients (including the constant) are positive, i.e.
min \sum_{i=1}^n(\bm{y}_i-\bm{x}_i\bm{\beta})^\top(\bm{y}_i-\bm{x}_i\bm{\beta})
such that \beta_{jk}\geq 0
.
A list including:
be |
The positively constrained beta coefficients. |
mse |
The mean squared error. |
Michail Tsagris.
R implementation and documentation: Michail Tsagris mtsagris@uoc.gr.
cls
y <- as.matrix( iris[, 1:2] )
x <- as.matrix( iris[, 3:4] )
mvpls(y, x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.