View source: R/matched.distances.R
matched.distances | R Documentation |
From a match (as produced by pairmatch
or fullmatch
)
and a distance, extract the distances of matched units from their
matched counterparts.
matched.distances(matchobj, distance, preserve.unit.names = FALSE)
matchobj |
Value of a call to |
distance |
Either a distance matrix or the value of a call to
or |
preserve.unit.names |
Logical. If TRUE, for each matched set
|
From a match (as produced by pairmatch
or fullmatch
)
and a distance, extract the distances of matched units from their
matched counterparts.
A list of numeric vectors (or matrices) of distances, one for each matched set. Note that a matched set with 1 treatment and k controls, or with k treatments and 1 control, has k, not k+1, distances.
Ben B. Hansen
data(plantdist)
plantsfm <- fullmatch(plantdist)
(plantsfm.d <- matched.distances(plantsfm,plantdist,pres=TRUE))
unlist(lapply(plantsfm.d, max))
mean(unlist(plantsfm.d))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.