R/calculate_wgt_corr.R
calculate_wgt_cor.Rd
The function calculates a weighted Pearson correlation coefficient between
variable A and B using wtd.cor
.
calculate_wgt_cor(d.sub, x, y)
d.sub | a dataframe with data. |
---|---|
x | character string of the name of variable A. |
y | character string of the name of variable B. |
the numeric value of the correlation coefficient.