distance.euclid {TriMatch} | R Documentation |
Euclidean distance calculation.
Description
This method uses a simple Euclidean distance calculation for determining the distances between two matches. That is, |ps1 - ps2|.
Usage
distance.euclid(x, grouping, id, groups, caliper, nmatch = Inf)
Arguments
x |
vector of propensity scores. |
grouping |
vector or factor identifying group membership. |
id |
vector corresponding to unique identifer for each element in
|
groups |
vector of length two indicating the unique groups to calculate the distance between. The first element will be the rows, the second columns. |
caliper |
a scaler indicating the caliper to use for matching within each step. |
nmatch |
number of smallest distances to retain. |
Value
a list of length equal to x
. Each element of the list is a
named numeric vector where the values correspond to the distance and the
name to the id
.
[Package TriMatch version 0.9.9 Index]