create contrasts between factor levels

linfct_factors_contrasts(m)

Examples


m <- sim_make_model_lm( "interaction")
#> creating sampleName from fileName column
#> completing cases
#> Joining with `by = join_by(protein_Id)`
xl <- linfct_factors_contrasts(m)
m <- lm(Petal.Width ~ Species, data = iris)
linfct_factors_contrasts(m)
#>                                      (Intercept) Speciesversicolor
#> Speciessetosa - Speciesversicolor              0                -1
#> Speciessetosa - Speciesvirginica               0                 0
#> Speciesversicolor - Speciesvirginica           0                 1
#>                                      Speciesvirginica
#> Speciessetosa - Speciesversicolor                   0
#> Speciessetosa - Speciesvirginica                   -1
#> Speciesversicolor - Speciesvirginica               -1