calculateDistances | R Documentation |

Auxiliary function used to calculate the distances between an instance and the ones with a specific active label. Euclidean distance is calculated for numeric attributes, and VDM for non numeric ones.

```
calculateDistances(sample, rest, label, D, tableVDM = NULL)
```

`sample` |
Index of the sample whose distances to other samples we want to know |

`rest` |
Indexes of the samples to which we will calculate the distance |

`label` |
Label that must be active |

`D` |
mld |

`tableVDM` |
Dataframe object containing previous calculations for faster processing. If it is empty, the algorithm will be slower |

A list with the distance to the rest of samples

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.