con_hamming_holland {holland} | R Documentation |
Congruence Index based on the Hamming distance
Description
The function computes the location-weighted, cost-sensitive Hammig distance (Hamming, 1950).
Usage
con_hamming_holland(a, b, costs = "hexa", weights = c(1.5, 1.25, 1))
Arguments
a |
a character vector with person Holland codes. |
b |
a character vector with environment Holland codes. |
costs |
character with default set to |
weights |
a numeric vector with length equal to |
Details
The function finds the distance according to Hamming (1950) between two sequences (see Abbott, 1995), which are the Holland codes given in argument a, which is the person code, and argument b, which is the environment code.
Value
a numeric with value for congruence.
References
Holland, J.L. 1963. A theory of vocational choice. I. Vocational images and choice. Vocational Guidance Quarterly, 11(4), 232–239.
Hamming, R. (1950). Error detecting and error correcting codes. Bell System Technical Journal, The, 29(2), 147–160.
Abbott, A. (1995, August). Sequence Analysis: New Methods for Old Ideas. Annual Review of Sociology, 21, 93–113.
Examples
con_hamming_holland(a="RIA",b="SEC") # max. difference
con_hamming_holland(a="RIA",b="RIA") # max. similarity
con_hamming_holland(a="RIASEC",b="SECRIA", weights=c(1.5,1.25,1,0.75,0.5,0.25)) # max. difference