match.rec {matchFeat}R Documentation

Recursive Initialization Method

Description

RECUR1 algorithm of Bandelt et al (2004) to find starting point in the multidimensional assignment problem with decomposable costs (MDADC)

Usage

match.rec(x, unit = NULL, w = NULL, control = list())

Arguments

x

data: matrix of dimensions (mn,p) or 3D array of dimensions (p,m,n) with m = number of labels/classes, n = number of sample units, and p = number of variables)

unit

integer (=number of units) or vector mapping rows of x to sample units (length mn). Must be specified only if x is a matrix.

w

weights for loss function: single positive number, p-vector of length, or (p,p) positive definite matrix

control

tuning parameters

Value

A list of class matchFeat with components

sigma

best set of permutations for feature vectors ((m,n) matrix)

cluster

associated clusters (= inverse permutations)

cost

minimum objective value

mu

sample mean for each class/label ((p,m) matrix)

V

sample covariance for each class/label ((p,m) matrix

call

function call

References

Degras (2022) "Scalable feature matching across large data collections." doi:10.1080/10618600.2022.2074429
Bandelt, Maas, and Spieksma (2004), "Local search heuristics for multi-index assignment problems with decomposable costs." doi:10.1057/palgrave.jors.2601723

See Also

match.2x, match.bca, match.gaussmix, match.template, match.kmeans

Examples

data(optdigits)
m <- length(unique(optdigits$label)) # number of classes
n <- nrow(optdigits$x) / m # number of units

## Use function with data in matrix form
fit1 <- match.rec(optdigits$x, unit=n)

## Use function with data in array form
p <- ncol(optdigits$x)
x <- t(optdigits$x)
dim(x) <- c(p,m,n)
fit2 <- match.rec(x)

[Package matchFeat version 1.0 Index]