jaccard: Jaccard Index

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

Description

Calculates jaccard index between two vectors of features. In brief, the closer to 1 the more similar the vectors. The two vectors may have an arbitrary cardinality (i.e. don't need same length). Also known as the Tanimoto distance metric. Defined as the size of the vectors' intersection divided by the size of the union of the vectors.

Usage

1
jaccard(x, y)

Arguments

x

vector of feature names

y

vector of feature names

Value

Returns the jaccard index for the two vectors. It takes values in [0,1], with 0 meaning no overlap between two sets and 1 meaning two sets are identical.

Author(s)

Charles E. Determan Jr.

References

Jaccard P. (1908) Nouvelles recherches sur la distribution florale. Bull. Soc. Vaudoise Sci. Nat. 44: 223-270.

Real R. & Vargas J.M. (1996) The Probabilistic Basis of Jaccard's Index of Similarity Systematic Biology 45(3): 380-385.

He. Z. & Weichuan Y. (2010) Stable feature selection for biomarker discovery. Computational Biology and Chemistry 34 215-225.

See Also

kuncheva, sorensen, ochiai, pof, pairwise.stability, pairwise.model.stability

Examples

1
2
3
4
# Jaccard demo
v1 <- paste("Metabolite", seq(10), sep="_")
v2 <- sample(v1, 10)
jaccard(v1, v2)

cdeterman/OmicsMarkeR documentation built on May 13, 2019, 2:35 p.m.