grs: Guided Random Search

Description Usage Arguments Details Value References Examples

View source: R/grs.R

Description

grs performs Euclidean Distance Matrix Completion using the guided random search algorithm of Rahman & Oldford. Using this method will preserve the minimum spanning tree in the partial distance matrix.

Usage

1
grs(D, d)

Arguments

D

An nxn partial-distance matrix to be completed. D must satisfy a list of conditions (see details), with unkown entries set to NA

d

The dimension for the resulting completion.

Details

The matrix D is a partial-distance matrix, meaning some of its entries are unknown. It must satisfy the following conditions in order to be completed:

Value

P

The completed point configuration in dimension d

D

The completed Euclidean distance matrix

References

Rahman, D., & Oldford, R.W. (2016). Euclidean Distance Matrix Completion and Point Configurations from the Minimal Spanning Tree.

Examples

1
2
3
4
5
6
7
8
9
#D matrix containing only the minimum spanning tree
D <- matrix(c(0,3,NA,3,NA,NA,
              3,0,1,NA,NA,NA,
              NA,1,0,NA,NA,NA,
              3,NA,NA,0,1,NA,
              NA,NA,NA,1,0,1,
              NA,NA,NA,NA,1,0),byrow=TRUE, nrow=6)
              
edmc(D, method="grs", d=3)

edmcr documentation built on Sept. 10, 2021, 5:10 p.m.

Related to grs in edmcr...