Rename a city data.frame onto the canonical audit schema
Source:R/fairness_cityprofile.R
morie_fairness_apply_profile.RdRename a city data.frame onto the canonical audit schema
Value
A new data.frame with the profile's columns renamed
to the canonical names, retaining only those canonical columns.
Examples
df <- data.frame(beat = c("A", "B"), score = c(0.1, 0.9))
p <- morie_fairness_city_profile(
"demo", area_col = "beat", risk_col = "score"
)
morie_fairness_apply_profile(df, p)
#> area risk
#> 1 A 0.1
#> 2 B 0.9