Description Usage Arguments Details Value Author(s) References Examples

Robust PLS by partial robust M-regression.

1 |

`formula` |
an object of class formula |

`data` |
a data frame which contains the variables given in formula |

`a` |
number of PLS components |

`wfunX` |
weight function to downweight leverage points; predefined weight funcktions "Fair", "Huber", "Tukey" and "Hampel" with respective tuning constants are passed via a list object, e.g. list("Fair",0.95) |

`wfunY` |
weight function to downweight residuals; predefined weight funcktions "Fair", "Huber", "Tukey" and "Hampel" with respective tuning constants are passed via a list object, e.g. list("Fair",0.95) |

`center.type` |
type of centering of the data in form of a string that matches an R function, e.g. "median" |

`scale.type` |
type of scaling for the data in form of a string that matches an R function, e.g. "qn" or alternatively "no" for no scaling |

`numit` |
the number of maximal iterations for the convergence of the coefficient estimates |

`prec` |
a value for the precision of estimation of the coefficients |

`usesvd` |
if TRUE singular value decomposition is performed; logical, default is FALSE |

M regression is used to robustify PLS. Employment of seperate weight functions for leverage points and residuals.

`coef` |
vector with regression coefficients |

`intercept` |
coefficient for intercept |

`wy` |
vector of length(y) with residual weights |

`wt` |
vector of length(y) with weights for leverage |

`w` |
overall weights |

`scores` |
matrix with PLS X-scores |

`loadings` |
matrix with PLS X-loadings |

`fitted.values` |
vector with fitted y-values |

Peter Filzmoser <peter.filzmoser@tuwien.ac.at>

S. Serneels, C. Croux, P. Filzmoser, and P.J. Van Espen. Partial robust M-regression. Chemometrics and Intelligent Laboratory System, Vol. 79(1-2), pp. 55-64, 2005.

1 2 3 4 5 6 7 8 9 10 11 12 | ```
U <- c(rep(2,20), rep(5,30))
X <- replicate(6, U+rnorm(50))
beta <- c(rep(1, 3), rep(-1,3))
e <- c(rnorm(45,0,1.5),rnorm(5,-20,1))
y <- X%*%beta + e
d <- as.data.frame(X)
d$y <- y
res <- PRM(y~., data=d, 3, wfunX=list("Fair",0.95),
wfunY=list("Fair",0.95), center.type = "median",
scale.type = "no",usesvd = FALSE,
numit = 100, prec = 0.01)
res$coef
``` |

```
[1] 1.0310097 0.8927724 1.0044301 -1.1344546 -0.6339380 -1.4058849
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.