Description Usage Arguments Value

This function predicts the class label of instances or its probability of pertaining to each class based on the distance matrix.

1 2 |

`object` |
A model of class OneNN built with |

`dists` |
A matrix of distances between the instances to classify (by rows) and the instances used to train the model (by column) |

`type` |
A string that can take two values: |

`...` |
Currently not used. |

If `type`

is equal to `"class"`

a vector of length equal to the rows number
of matrix `dists`

, containing the predicted labels. If `type`

is equal
to `"prob"`

it returns a matrix which has `nrow(dists)`

rows and a column for every
class, where each cell represents the probability that the instance belongs to the class,
according to 1NN.

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.