View source: R/protDistanceCompute.R
nearestProts | R Documentation |
Uses a distance matrix to identify proteins with profiles nearest to that of a specified protein; can be used to identify proteins with similar subcellular locations.
nearestProts(protName, n.nearest = 5, distProts, protNames, profile)
protName |
name of protein to which distances are to be computed |
n.nearest |
number of nearest proteins to list |
distProts |
distance matrix created by, for example, using the 'dist' function in R |
protNames |
list of all proteins in a dataset |
profile |
data frame of profiles for proteins |
List of the proteins in data set with profiles closest to that of specified protein (protName)
data(protNSA_test)
distUse <- dist(protNSA_test[,seq_len(9)], method='euclidean')
protsUse <- names(protNSA_test)
nearestProts(protName='CTSD', n.nearest=10, distProts=distUse,
protNames=protsUse, profile=protNSA_test[,seq_len(9)])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.