These objects are used when:
In this case, a correlation coefficient (via stats::cov.wt()) is computed with
the proper variable roles. Values closer to 1 or -1 (i.e., abs(cor_pearson)
closer to 1) are associated with more important predictors.
Estimating the scores
In filtro, the score_* objects define a scoring method (e.g., data
input requirements, package dependencies, etc). To compute the scores for
a specific data set, the fit() method is used. The main arguments for
these functions are:
object
A score class object (e.g., score_cor_pearson).
formula
A standard R formula with a single outcome on the right-hand side and one or more predictors (or .) on the left-hand side. The data are processed via stats::model.frame()
data
A data frame containing the relevant columns defined by the formula.
...
Further arguments passed to or from other methods.
case_weights
A quantitative vector of case weights that is the same length as the number of rows in data. The default of NULL indicates that there are no case weights.
Missing values are removed for each predictor/outcome combination being
scored.
In cases where the underlying computations fail, the scoring proceeds
silently, and a missing value is given for the score.