Description Usage Arguments Details Value Author(s) References See Also Examples

The four functions `nnr`

(nearest neighbor rule),
`dlda`

(diagonal linear discriminant analysis), `logreg`

(logistic regression) and `aggtrees`

(aggregated trees) are used
for binary classification with the cluster representatives of Wilma's
output.

1 2 3 4 |

`xlearn` |
Numeric matrix of explanatory variables ( |

`xtest` |
A numeric matrix of explanatory variables ( |

`ylearn` |
Numeric vector of length |

`nnr`

implements the 1-nearest-neighbor-rule with
Euclidean distance function. `dlda`

is linear discriminant
analysis, using the restriction that the covariance matrix is diagonal
with equal variance for all predictors. `logreg`

is default
logistic regression. `aggtrees`

fits a default stump (a
classification tree with two terminal nodes) by `rpart`

for every
predictor variable and uses majority voting to determine the final
classifier.

Numeric vector of length *m*, containing the predicted class
labels for the test observations. The class labels are coded by 0 and
1.

Marcel Dettling, [email protected]

Marcel Dettling (2002)
*Supervised Clustering of Genes*, see
http://stat.ethz.ch/~dettling/supercluster.html

Marcel Dettling and Peter B<c3><bc>hlmann (2002).
Supervised Clustering of Genes.
*Genome Biology*, **3**(12): research0069.1-0069.15.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ```
## Generating random learning data: 20 observations and 10 variables (clusters)
set.seed(342)
xlearn <- matrix(rnorm(200), nrow = 20, ncol = 10)
## Generating random test data: 8 observations and 10 variables(clusters)
xtest <- matrix(rnorm(80), nrow = 8, ncol = 10)
## Generating random class labels for the learning data
ylearn <- as.numeric(runif(20)>0.5)
## Predicting the class labels for the test data
nnr(xlearn, xtest, ylearn)
dlda(xlearn, xtest, ylearn)
logreg(xlearn, xtest, ylearn)
aggtrees(xlearn, xtest, ylearn)
``` |

```
[1] 0 0 0 0 0 1 0 0
[1] 0 0 0 0 1 1 1 0
[1] 1 0 0 0 1 1 1 0
[1] 1 0 0 0 1 1 1 1
```

supclust documentation built on May 29, 2017, 9:19 a.m.

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.