wtd.partial.cor: Computes weighted partial correlations, controlling for covariates
Description
wtd.partial.cor estimates the weighted partial correlation between two variables or sets of variables, controlling for additional covariates. This function uses weighted regression to residualize the inputs and computes the correlation of the residuals, providing standard errors and significance tests.