Skip to content
Prev 5577 / 7419 Next

mixed model on proportion data

Hi Mariano,

You could use a log ratio between undamaged and damage proportions [1] 
and obtain a response variable not constrained between 0 and 1. If so 
you will have to replace zeros by a detection limit. [2] used 65% of 
the detection limit as a basis for replacement, but there are many 
options available for imputing zeros [3]. To make things simpler here, 
I replace zeros by 1% and 100% by 99% (no 100% damaged though). Then I 
compute a log ratio between undamaged and damaged. A positive log ratio 
means the damage is less than 50%, and conversely with 0 meaning 50% 
damaged.

dam_imp = gaston$dam
dam_imp[gaston$dam == 0] = 1
dam_imp[gaston$dam == 100] = 99
gaston$dam_lr = log((100-dam_imp) / dam_imp)
hist(gaston$dam)
hist(gaston$dam_lr)

There are many 0% and many 95%.

M1 <- lmer(dam_lr ~ treat + day + (1|pair/plant), data=gaston)
summary(M1)
hist(residuals(M1))

The distribution of residuals seems not so bad.

[1] 
http://www.sediment.uni-goettingen.de/staff/tolosana/extra/CoDaNutshell.pdf
[2] http://dx.doi.org/10.1016/j.gexplo.2013.09.003
[3] https://cran.r-project.org/web/packages/zCompositions/index.html