GtoD2 {dbstats} | R Documentation |
Distance conversion: dist to D2
Description
Converts Gram
class object into D2
class object
Usage
GtoD2(G)
Arguments
G |
|
Value
An object of class D2
containing the squared distances matrix
between individuals.
Author(s)
Boj, Eva <evaboj@ub.edu>, Caballe, Adria <adria.caballe@upc.edu>, Delicado, Pedro <pedro.delicado@upc.edu> and Fortiana, Josep <fortiana@ub.edu>
See Also
Examples
X <- matrix(rnorm(100*3),nrow=100)
D2 <- as.matrix(dist(X)^2)
class(D2) <- "D2"
G <- D2toG(D2,weights=NULL)
class(G) <- "Gram"
D22 <- GtoD2(G)
[Package dbstats version 2.0.2 Index]