# distances.details: To calculate distances applying weights. In LearnClust: Learning Hierarchical Clustering Algorithms

## Description

To explain how to calculate distances between two clusters applying weights depending on the distance type.

## Usage

 `1` ```distances.details(cluster1, cluster2, distance, weight) ```

## Arguments

 `cluster1` is a matrix. `cluster2` is a matrix. `distance` is a string. The distance type to apply. `weight` is a numeric vector.

## Details

This function calculates distance applying `distance` type and applying each weight to its characteristic.

Distance type could be `EUC`, `MAN`, `CAN`, `CHE` or `OCT`.

## Value

Distance value applying weights. Explanation.

## Author(s)

Roberto Alcántara roberto.alcantara@edu.uah.es

 ```1 2 3 4 5 6 7 8 9``` ```cluster1 <- matrix(c(2,3)) cluster2 <- matrix(c(4,5)) weight1 <- c(0.6,0.4) weight2 <- c(2,4) distances.details(cluster1, cluster2, 'MAN', weight1) distances.details(cluster1, cluster2, 'CHE', weight2) ```