Functional partial least squares regression
Fits a functional partial least squares (PLSR) model using nonlinear partial least squares (NIPALS) algorithm or simple partial least squares (SIMPLS) algorithm.
fplsr(data, order = 6, type = c("simpls", "nipals"), unit.weights = TRUE, weight = FALSE, beta = 0.1, interval = FALSE, method = c("delta", "boota"), alpha = 0.05, B = 100, adjust = FALSE, backh = 10)
data |
An object of class |
order |
Number of principal components to fit. |
type |
When |
unit.weights |
Constrains predictor loading weights to have unit norm. |
weight |
When |
beta |
When |
interval |
When |
method |
Method used for computing prediction intervals. |
alpha |
|
B |
Number of replications. |
adjust |
When |
backh |
When |
Point forecasts:
The NIPALS function implements the orthogonal scores algorithm, as described in Martens and Naes (1989). This is one of the two classical PLSR algorthms, the other is the simple partial least squares regression in DeJong (1993). The difference between these two approaches is that the NIPALS deflates the original predictors and responses, while the SIMPLS deflates the covariance matrix of original predictors and responses. Thus, SIMPLS is more computationally efficient than NIPALS.
In a functional data set, the functional PLSR can be performed by setting the functional responses to be 1 lag ahead of the functional predictors. This idea has been adopted from the Autoregressive Hilbertian processes of order 1 (ARH(1)) of Bosq (2000).
Distributional forecasts:
Parametric method:
Influenced by the works of Denham (1997) and Phatak et al. (1993), one way of constructing prediction intervals in the PLSR is via a local linearization method (also known as the Delta method). It can be easily understood as the first two terms in a Taylor series expansion. The variance of coefficient estimators can be approximated, from which an analytic-formula based prediction intervals are constructed.
Nonparametric method:
After discretizing and decentralizing functional data f_t(x) and g_s(y), a PLSR model with K latent components is built. Then, the fit residuals o_s(y_i) between g_s(y_i) and hat(g)_s(y_i) are calculated as
o_s(y_i)=[g_s(y_i)-hat(g)_s(y_i)], i=1,...,p.
The next step is to generate B bootstrap samples o_s^b(y_i) by randomly sampling with replacement from [o_1(y_i),...,o_n(y_i)]. Adding bootstrapped residuals to the original response variables in order to generate new bootstrap responses,
g_s^b(y_i)=g_s(y_i)+o_s^b(y_i).
Then, the PLSR models are constructed using the centered and discretized predictors and bootstrapped responses
to obtain the boostrapped regression coefficients and point forecasts, from which the empirical prediction intervals and kernel density plots are constructed.
A list containing the following components is returned.
B |
(p x m) matrix containing the regression coefficients. p is the number of variables in the predictors and m is the number of variables in the responses. |
P |
(p x order) matrix containing the predictor loadings. |
Q |
(m x order) matrix containing the response loadings. |
T |
|
R |
(p x order) matrix containing the weights used to construct the latent components of predictors. |
Yscores |
|
projection |
(p x order) projection matrix used to convert predictors to predictor scores. |
meanX |
An object of class |
meanY |
An object of class |
Ypred |
An object of class |
fitted |
An object of class |
residuals |
An object of class |
Xvar |
A vector with the amount of predictor variance explained by each number of component. |
Xtotvar |
Total variance in predictors. |
weight |
When |
x1 |
Time period of a |
y1 |
Variables of a |
ypred |
Returns the original functional predictors. |
y |
Returns the original functional responses. |
bootsamp |
Bootstrapped point forecasts. |
lb |
Lower bound of prediction intervals. |
ub |
Upper bound of prediction intervals. |
lbadj |
Adjusted lower bound of prediction intervals. |
ubadj |
Adjusted upper bound of prediction intervals. |
lbadjfactor |
Adjusted lower bound factor, which lies generally between 0.9 and 1.1. |
ubadjfactor |
Adjusted upper bound factor, which lies generally between 0.9 and 1.1. |
Han Lin Shang
S. Wold and A. Ruhe and H. Wold and W. J. Dunn (1984) "The collinearity problem in linear regression. The partial least squares (PLS) approach to generalized inverses", SIAM Journal of Scientific and Statistical Computing, 5(3), 735-743.
S. de Jong (1993) "SIMPLS: an alternative approach to partial least square regression", Chemometrics and Intelligent Laboratory Systems, 18(3), 251-263.
C J. F. Ter Braak and S. de Jong (1993) "The objective function of partial least squares regression", Journal of Chemometrics, 12(1), 41-54.
B. Dayal and J. MacGregor (1997) "Recursive exponentially weighted PLS and its applications to adaptive control and prediction", Journal of Process Control, 7(3), 169-179.
B. D. Marx (1996) "Iteratively reweighted partial least squares estimation for generalized linear regression", Technometrics, 38(4), 374-381.
L. Xu and J-H. Jiang and W-Q. Lin and Y-P. Zhou and H-L. Wu and G-L. Shen and R-Q. Yu (2007) "Optimized sample-weighted partial least squares", Talanta, 71(2), 561-566.
A. Phatak and P. Reilly and A. Penlidis (1993) "An approach to interval estimation in partial least squares regression", Analytica Chimica Acta, 277(2), 495-501.
M. Denham (1997) "Prediction intervals in partial least squares", Journal of Chemometrics, 11(1), 39-52.
D. Bosq (2000) Linear Processes in Function Spaces, New York: Springer.
N. Faber (2002) "Uncertainty estimation for multivariate regression coefficients", Chemometrics and Intelligent Laboratory Systems, 64(2), 169-179.
J. A. Fernandez Pierna and L. Jin and F. Wahl and N. M. Faber and D. L. Massart (2003) "Estimation of partial least squares regression prediction uncertainty when the reference values carry a sizeable measurement error", Chemometrics and Intelligent Laboratory Systems, 65(2), 281-291.
P. T. Reiss and R. T. Ogden (2007), "Functional principal component regression and functional partial least squares", Journal of the American Statistical Association, 102(479), 984-996.
C. Preda, G. Saporta (2005) "PLS regression on a stochastic process", Computational Statistics and Data Analysis, 48(1), 149-158.
C. Preda, G. Saporta, C. Leveder (2007) "PLS classification of functional data", Computational Statistics, 22, 223-235.
A. Delaigle and P. Hall (2012), "Methodology and theory for partial least squares applied to functional data", Annals of Statistics, 40(1), 322-352.
M. Febrero-Bande, P. Galeano, W. Gonz\'alez-Manteiga (2017), "Functional principal component regression and functional partial least-squares regression: An overview and a comparative study", International Statistical Review, 85(1), 61-83.
# When weight = FALSE, all observations are assigned equally. # When weight = TRUE, all observations are assigned geometrically decaying weights. fplsr(data = ElNino_ERSST_region_1and2, order = 6, type = "nipals") fplsr(data = ElNino_ERSST_region_1and2, order = 6) fplsr(data = ElNino_ERSST_region_1and2, weight = TRUE) fplsr(data = ElNino_ERSST_region_1and2, unit.weights = FALSE) fplsr(data = ElNino_ERSST_region_1and2, unit.weights = FALSE, weight = TRUE) # The prediction intervals are calculated numerically. fplsr(data = ElNino_ERSST_region_1and2, interval = TRUE, method = "delta") # The prediction intervals are calculated by bootstrap method. fplsr(data = ElNino_ERSST_region_1and2, interval = TRUE, method = "boota")
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.