netvr: Optimal variable-ratio match from a distance matrix.

Description Usage Arguments Details Value References

View source: R/netvr.R

Description

The function creates the network for optimal variable-ratio matching to be passed via callrelax to the Fortran code for Bertsekas and Tseng's (1988) Relax IV.

Of limited interest to most users; function netvr() would typically be called by some other functions.

Usage

1
2
3
netvr(z,dist,min.control=1,max.control=min.control,
total.control=sum(z)*min.control,
fine=rep(1,length(z)),penalty=1000)

Arguments

z

A vector whose ith coordinate is 1 for a treated unit and is 0 for a control.

dist

A distance list with the starting node (treated subjec), ending node (control), the extra distance between them.

min.control

A positive integer giving the minimum number of controls to be matched to each treated subject. If min.control is too large, the match will be infeasible.

max.control

A positive integer giving the maximum number of controls to be matched to each treated subject.

total.control

A positive integer giving the total number of controls to be matched to each treated subject. If total.control is too large, the match will be infeasible.

fine

A vector of with length(z)=length(fine) giving the nominal levels that are to be nearly-finely balanced.

penalty

A numeric penalty imposed for each violation of fine balance.

Details

The network contains a bipartite graph for treated and control subjects plus additional nodes for fine balance categories, plus additional nodes accept needed deviations from fine balance yielding near-fine balance.

Value

A network for optimal variable-ratio matching.

References

Bertsekas, D. P. and Tseng, P. (1988) The relax codes for linear minimum cost network flow problems. Annals of Operations Research, 13, 125-190. Fortran and C code: http://www.mit.edu/~dimitrib/home.html. Available in R via the optmatch package.


thickmatch documentation built on April 14, 2020, 5:30 p.m.

Related to netvr in thickmatch...