I have a question according the following example:
What I want to find out is whether two fertilizers (A and B) have different effects on the biomass of my plants. My explanatory variable is 'fertilizer' (categorial) with the levels 'A' and 'B'. My response variable is 'biomass' (continuous). Besides that, I have two other continuous variables 'seed mass' of the plants (measured before they germinated) and 'growth duration' (=harvesting date minus germination date). These two variables are expected explain some variance in my data and therefore I want to include them as covariates. (For each of the two levels I have 30 plants without any missing values.)
I read that my factor is a fixed effect and the covariates are random effects, as they represent a random sample out of the natural population. So I would do an ANCOVA in R using the lmer function (package lmerTest) like this:
model <- lmer(biomass~fertilizer+(1|seed_mass)+(1|growth_duration), data=dataset) anova(model)
My question - are my considerations and the way I'm performing the analysis correct? Or is this analysis not appropriate for my question? My special concern is about the covariates, if I should include them in a different way in the model.