Questions tagged [compare-contrast]
23 questions
0
votes
0 answers
Can we use different contrast codings for different predictor variables entered within a linear mixed effects model?
I'm trying to test the 4way-interaction effect of the block (2 levels), learning condition (2 levels), group (2 levels) and age(4 levels)in a mixed effect model:
agmt.confir.mod2 <- lmer(RTNormalized~ Block * SeqType * Group * AgeRange +…

Arpitha
- 27
- 3
0
votes
1 answer
R - specifying interaction contrasts for aov
How to specificy the contrasts (point estimates, 95CI and p-values) for the between-group differences of the within-group delta changes?
In the example below, I would be interest in the between-groups (group = 1 minus group = 2) of delta changes…

jtjtjtjt
- 105
- 6
0
votes
0 answers
categorical fixed effect with three levels
I have a fixed effect with three levels and I used the following contrasts that created 2 columns in my data set
data = data %>%
mutate(contrast_B = ifelse(group == "A", -0.5,
ifelse(type == "B", 0.5, 0))) %>%
…

Aroma
- 1
- 1
0
votes
2 answers
Contrasts between successive levels of a factor in R
I'm writing this post because I'm stuck in the analysis of a data file from a laboratorial experiment.
In this experiment, I counted the number of females (of a small arthropod) present in a specific environment, throughout 26 time points (TP).…

André Mira
- 5
- 3
0
votes
1 answer
Equivalent to contrast (Stata) in R
I wonder if there is some equivalent to Stata's contrast command in R.
Specifically I am interested in sex@agegroup#group2
I know package margins to calculate marginal (or partial) effects from model objects.
From Stata web page I extracted an…

Rodrigo_BC
- 161
- 11
0
votes
0 answers
How to set specific level contrasts with lmer in lme4
I have a mixed model containing the response variable (resp), two fixed effects (fix1 and fix2) and a random factor (ran1). In particular:
fix1 has 2 levels (control and treatment);
fix2 has 7 levels (from 1 to 7, indicating time in a categorical…

Matteo Petit Bon
- 1
- 3
0
votes
0 answers
Create design contrast matrix using automatic function
I would like to create a function that return design contrast matrix of factors with number of factors, levels in each factor as input. Im my example, I have:
1st factor
treat <- gl(3, 20, labels = paste("t", 1:3, sep=""))
2nd factor
imp <-…

Leprechault
- 1,531
- 12
- 28
0
votes
1 answer
Algorithm for checking if two HSL color values would have a bad contrast?
In javascript/jquery, if I have two colors in HSL (or hex or rgb) format, is there an algorithm that can check if the contrast is bad? One color is text, and the other color is the background of the text. I need to follow standard accessibility…

omega
- 40,311
- 81
- 251
- 474