David,

How would you interpret the results of a post hoc test for sexcolor when 
you have an interaction term with sexcolor in your model?

Perhaps it would be helpful to plot doy vs. predicted tle with confidence 
intervals for each of the four levels of sexcolor at a fixed tl (e.g., the 
mean).  This would give you a visualization of if, where, and how tle 
differs with respect to sexcolor.

Jean


chirleu <ville...@iim.csic.es> wrote on 11/05/2012 02:51:34 AM:
> 
> Hi.
> I'm analysing some fish biological traits with a gam in mgcv.  After 
several
> tries, I got this model
> log(tle) = sexcolor + s(doy, bs = "cc", by = sexcolor) +log(tl)
> 
> sexcolor is a factor with 4 levels
> doy is "day of year", which is modeled as a smoother
> tl is "total length of the fish"
> 
> The summary of this models is (only parametric coefficientes):
> 
> Parametric coefficients:
>                                                        Estimate Std. 
Error t
> value Pr(>|t|) 
> (Intercept)                                -1.34237    0.42340  -3.170 
> 0.001733 ** 
> sexcolorSpotted males        -0.04405    0.12568  -0.350    0.726309 
> sexcolorPlain females            0.30812    0.08191   3.762    0.000215 
***
> sexcolorSpotted females      0.18642    0.08018   2.325    0.020948 * 
> log(tl)                                            3.42331    0.11608 
> 29.490  < 2e-16 ***
> ---
> Signif. codes:  0 ?***? 0.001 ?**? 0.01 ?*? 0.05 ?.? 0.1 ? ? 1 
> 
> Is there any way to do post hoc test for categorical variables in the
> parametric part of the model? I mean,  levels for sexcolor are being
> compared with the reference level ("Plain males"), so I see that 
"Spotted
> males", for example, are not different from "Plain males", whereas 
females
> (both Plain and Spotted) are significantly different from "Plain males".
> Now, I'd like to make multiple comparisons between other combination of
> levels, i.e., "Plain females" vs. "Spotted males", for example.
> 
> Any suggestion?
> 
> Thanks, 
> 
> David

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to