calculateSimilarity {maDB}R Documentation

Calculate similarities (distances) between a vector and the rows (columns) of a matrix

Description

calculateSimilarity calculates the similarity (distance) between the submitted numeric vector and all rows respectively columns of a numerical matrix using the specified similarity (distance) measurement method.

Usage

calculateSimilarity(vector,matrix,orientation="h",distance.fun=distance.euclidian,include.values=FALSE)

Arguments

vector The numerical vector for which the similarities should be calculated.
matrix Numerical matrix with wichs columns (rows) the vector submitted with the vector attribute should be compared.
orientation If the vector should be compared with the rows ("h") or columns ("v") of the matrix.
distance.fun The function that should be used to calculate the similarity.
include.values If the input values should be included in the result. If false only a vector with the distances will be returned.

Details

This function is a simple and quick way to calculate the similarity of a vector and the columns or rows of a matrix. This function can be used if one has for example a gene with known gene expression or regulation pattern and want to search for other genes that show a similar pattern under the same conditions.

Author(s)

Johannes Rainer

References

See Also

distance.pearson distance.euclidian distance.spearman dbSearchSimilarPattern

Examples






[Package maDB version 1.2.0 Index]