• No results found

8.4 Chapter 5 Supplementary Materials

8.4.2 Experiment 5.2

8.4.2.1 Mean target-heading angle as a function of distance 8.4.2.1.1 Building the model

A taxonomy of models was fitted on the mean target-heading angles as a function of walking distance (0.5m ~ 6m). On the basis of model baseline, model dstRI included the level-1 predictor distance and model dstRS introduced random slopes. Model fml.int included the level-2 predictor Familiarity and model fml.slpincluded the interaction term Familiarity × distance. Model cue.int included the level-2 predictor Cue (Dark, Strobe and Lit) and model cue.slp included its interaction with distance. Model fml.cue.int included the Familiarity × distance interaction and model fml.cue.slp included the three-way interaction Familiarity × Cue × distance for testing the differential effect of familiarity on the slope depending on cue availability.

baseline <- lme(headingErr ~ 1, random = ~1|SubjectNo, data = offset.long, met

hod = "ML", na.action = na.exclude, control = list(opt = "optim"))

# Adding distance as the level-1 fixed effect

dstRI <- update(baseline, .~. + distance)

dstRS <- update(dstRI, random = ~ distance|SubjectNo) # Effect of Familiarity on the intercept

fml.int <- update(dstRS, .~. + Familiarity) # Effect of Familiarity on the Slope

fml.slp <- update(fml.int, .~. + Familiarity : distance) # Effect of cue availability on the intercept

cue.int <- update(fml.slp, .~. + Cue) # Effect of cue availability on the Slope

cue.slp <- update(cue.int, .~. + Cue : distance) # Interaction on the intercept

186 # Interaction on the slope

fml.cue.slp <- update(fml.cue.int, .~. + Familiarity : Cue : distance)

8.4.2.1.2 Compare the models

The R code and output for model comparisons are listed below. In the output list, the first column shows the name of the model. The column logLik shows the magnitude of log- likelihood of the model. The column L.Ratioshows the -2LL between the current model and the previous model before the predictor was added in. The p-values can be used to determine whether the improvement of model fit is significant.

# Code

anova(baseline, dstRI, dstRS, fml.int, fml.slp, cue.int, cue.slp, fml.cue.int, fml .cue.slp)

# Output

## Model df AIC BIC logLik Test L.Ratio p-value ## baseline 1 3 176143.1 176168.5 -88068.53 ## dstRI 2 4 174798.8 174832.7 -87395.37 1 vs 2 1346.311 <.0001 ## dstRS 3 6 169718.5 169769.5 -84853.27 2 vs 3 5084.212 <.0001 ## fml.int 4 7 169719.6 169779.1 -84852.82 3 vs 4 0.902 0.3423 ## fml.slp 5 8 169720.9 169788.8 -84852.46 4 vs 5 0.716 0.3976 ## cue.int 6 10 169700.0 169784.9 -84840.01 5 vs 6 24.890 <.0001 ## cue.slp 7 12 169700.2 169802.0 -84838.09 6 vs 7 3.857 0.1454 ## fml.cue.int 8 14 169699.2 169818.1 -84835.62 7 vs 8 4.927 0.0851 ## fml.cue.slp 9 16 169701.6 169837.4 -84834.78 8 vs 9 1.676 0.4326

8.4.2.1.3 Parameter estimates in the model fml.cue.int

The R code and output for showing the estimated parameters in the final model fml.cue.int is shown below. In the output above, the column named Value shows the estimated value of the parameter. The columns named t-value and p-value show the result of the hypothesis test on the parameter. If the p-value reaches the threshold (α = 0.05), it is suggested that the parameter estimate is different from 0. Here the Dark-Familiar condition is the reference condition, therefore the rows Intercept and distance show the estimates of the intercept and slope in the Dark-Familiar condition. The rows below show the estimates of the difference in the intercept and slope between the Dark-Familiar condition and other conditions.

# Code

summary(fml.cue.int, corr = FALSE) # Output

## Fixed effects: headingErr ~ distance + Familiarity + Cue + distance:Familiarity + distance:Cue + Familiarity:Cue

## Value Std.Error DF t-value p-value ## (Intercept) 5.985018 0.5517343 35857 10.847645 0.0000

187 ## distance -0.195048 0.1483862 35857 -1.314464 0.1887 ## Unfamiliar 1.626211 0.7466591 66 2.177984 0.0330 ## Lit -1.204657 0.7636395 66 -1.577521 0.1195 ## Strobe 0.481590 0.7636432 66 0.630648 0.5304 ## distance: Unfamiliar 0.129219 0.1483846 35857 0.870840 0.3838 ## distance:Lit -0.335111 0.1817343 35857 -1.843964 0.0652 ## distance:Strobe -0.285451 0.1817330 35857 -1.570718 0.1163 ## Unfamiliar:Lit -2.142856 1.0061833 66 -2.129687 0.0369 ## Unfamiliar:Strobe -1.784672 1.0061851 66 -1.773701 0.0807

8.4.2.1.4 Estimation of slope parameters

Here we examined the estimated average slope between the Familiar and Unfamiliar groups for each cue condition (Dark, Strobe and Lit). This was also done by creating a contrast matrix using multcomp package (Hothorn et al., 2008). The R code and output are shown below. In the output list, the column Estimate shows the estimated slope of each condition. The z- and p-values are the results of hypothesis tests of whether the estimated slope in the corresponding condition is different from 0. Here we can see that except the Dark condition, both Strobe and Lit conditions have a significant negative slope.

# Code contrast.matrix <- rbind( "Dark" = c(0, 1, 0, 0, 0, 0.5, 0, 0, 0, 0), "Strobe" = c(0, 1, 0, 0, 0, 0.5, 0, 1, 0, 0), "Lit" = c(0, 1, 0, 0, 0, 0.5, 1, 0, 0, 0) )

postHocs <-glht(fml.cue.int, contrast.matrix) summary(postHocs, test = adjusted("none")) # Output

## Simultaneous Tests for General Linear Hypotheses ##

## Fit: lme.formula(fixed = headingErr ~ distance + Familiarity + Cue +

## distance:Familiarity + distance:Cue + Familiarity:Cue, data = offset.long, ## random = ~distance | SubjectNo, method = "ML", na.action = na.exclude, ## control = list(opt = "optim"))

##

## Linear Hypotheses:

## Estimate Std. Error z value Pr(>|z|) ## Dark == 0 -0.1304 0.1285 -1.015 0.310018 ## Strobe == 0 -0.4159 0.1285 -3.237 0.001209 ** ## Lit == 0 -0.4656 0.1285 -3.623 0.000291 ***

## ---

## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 ## (Adjusted p values reported -- none method)

188

8.4.2.2 Mean target-heading angle as a function of test trials 8.4.2.2.1 Building the model

A taxonomy of models was fitted on the mean target-heading angles as a function of trial (1 ~ 5). On the basis of model baseline, model trialM included the level-1 predictor Trial. Model trialMS introduced random slopes and model trialMAR took autocorrelation into account. Model fml.intincluded the level-2 predictor Familiarity and model fml.slp included the interaction term Familiarity × Trial. Model cue.int included the level-2 predictor Cue (Dark, Strobe and Lit) and model cue.slp included its interaction with Trial. The former tests the difference in the intercept or magnitude of the target-heading angle between Dark, Strobe and Lit condition; and the latter tests the difference in slope between the three conditions. Model fml.cue.int included the Familiarity × Trial interaction and model fml.cue.slp included the three-way interaction Familiarity × Cue × Trial for testing the differential effect of familiarity on the slope depending on cue availability.

baseline <- lme(target-heading_angle ~ 1, random = ~ 1 | SubjectNo, data = of fset.err.long, method = "ML", na.action = na.omit)

trialM <- update(baseline, .~. + Trial)

trialMS <- update(trialM, random = ~ Trial|SubjectNo, control = list(opt =

"optim", maxIter = 500))

trialMAR <- update(trialMS, correlation = corAR1()) # Effect of Familiarity on the intercept

fml.int <- update(trialMAR, .~. + Familiarity) # Effect of Familiarity on the Slope

fml.slp <- update(fml.int, .~. + Familiarity : Trial) # Effect of cue availability on the intercept

cue.int <- update(fml.slp, .~. + Cue) # Effect of cue availability on the Slope

cue.slp <- update(cue.int, .~. + Cue : Trial) # Interaction on the intercept

fml.cue.int <- update(cue.slp, .~. + Familiarity : Cue) # Interaction on the slope

fml.cue.slp <- update(fml.cue.int, .~. + Familiarity : Cue : Trial)

8.4.2.2.2 Compare the models

The R code and output for model comparisons are listed below. In the output list, the first column shows the name of the model. The column logLik shows the magnitude of log- likelihood of the model. The column L.Ratioshows the -2LL between the current model and the previous model before the predictor was added in. The p-values can be used to determine whether the improvement of model fit is significant. Here we can see that both model

189

cue.intand model cue.slpare significantly better than the previous one, suggesting that both magnitude of target-heading angle in Trial 1 and rate of change in target-heading angle across trials varied as a function of cue availability.

# Code

anova(baseline, trialM, trialMS, trialMAR, fml.int, fml.slp, cue.int, cue.slp, fml .cue.int, fml.cue.slp)

# Output

## Model df AIC BIC logLik Test L.Ratio p-value ## baseline 1 3 1562.290 1573.948 -778.1451 ## trialM 2 4 1563.202 1578.746 -777.6010 1 vs 2 1.0882 0.2969 ## trialMS 3 6 1567.142 1590.459 -777.5713 2 vs 3 0.0594 0.9707 ## trialMAR 4 7 1539.852 1567.054 -762.9258 3 vs 4 29.2909 <.0001 ## fml.int 5 8 1540.467 1571.556 -762.2338 4 vs 5 1.3840 0.2394 ## fml.slp 6 9 1542.039 1577.014 -762.0194 5 vs 6 0.4286 0.5126 ## cue.int 7 11 1519.339 1562.086 -748.6696 6 vs 7 26.6997 <.0001 ## cue.slp 8 13 1511.761 1562.281 -742.8806 7 vs 8 11.5779 0.0031 ## fml.cue.int 9 15 1513.469 1571.761 -741.7348 8 vs 9 2.2916 0.3180 ## fml.cue.slp 10 17 1515.257 1581.321 -740.6285 9 vs 10 2.2125 0.3308

8.4.2.2.3 Estimation of slope parameters

Here we examined the estimated average slope between the Familiar and Unfamiliar groups for each cue condition (Dark, Strobe and Lit) by evaluating the parameter estimates in model cue.slp. The R code and output are shown below. In the output list, the column Estimateshows the estimated slope of each condition. The z- and p-values are the results of hypothesis tests of whether the estimated slope in the corresponding condition is different from 0. Here we can see that target-heading angle only decreased significantly in the Dark condition. # Code contrast.matrix <- rbind( "Dark" = c(0, 1, 0, 0, 0, 0, 0, 0), "Strobe" = c(0, 1, 0, 0, 0, 0, 0, 1), "Lit" = c(0, 1, 0, 0, 0, 0, 1, 0) )

postHocs <-glht(cue.slp, contrast.matrix) summary(postHocs, test = adjusted("none")) # Output

## Simultaneous Tests for General Linear Hypotheses ##

## Fit: lme.formula(fixed = meanErr ~ Trial + Familiarity + Cue + Trial:Familiarit y +

## Trial:Cue, data = offset.err.long, random = ~Trial | SubjectNo, ## correlation = corAR1(), method = "ML", na.action = na.omit, ## control = list(opt = "optim", maxIter = 500))

##

## Linear Hypotheses:

## Estimate Std. Error z value Pr(>|z|) ## Dark == 0 -0.29607 0.10950 -2.704 0.00686 **

190

## Strobe == 0 0.15793 0.10950 1.442 0.14924 ## Lit == 0 0.05331 0.10950 0.487 0.62639

## ---

## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 ## (Adjusted p values reported -- none method)

8.4.2.2.4 Pairwise comparison on the slope estimates between the conditions

Then we created another contrast matrix and ran on the parameter estimates in model cue.slp for pairwise comparison on the average slopes between the Dark, Strobe and Lit conditions. The R code and output are shown below. In the output list, the column Estimate shows the estimated difference in slope between the two conditions in the comparison. The z- and p-values are the results of hypothesis tests of whether the estimated difference is different from 0. # Code contrast.matrix <- rbind( "Strobe - Dark" = c(0, 0, 0, 0, 0, 0, 0, 1), "Lit - Dark" = c(0, 0, 0, 0, 0, 0, 1, 0), "Strobe - Lit" = c(0, 0, 0, 0, 0, 0, -1, 1) )

postHocs <-glht(cue.slp, contrast.matrix) summary(postHocs, test = adjusted("bonferroni")) # Output

## Simultaneous Tests for General Linear Hypotheses ##

## Fit: lme.formula(fixed = meanErr ~ Trial + Familiarity + Cue + Trial:Familiarit y +

## Trial:Cue, data = offset.err.long, random = ~Trial | SubjectNo, ## correlation = corAR1(), method = "ML", na.action = na.omit, ## control = list(opt = "optim", maxIter = 500))

##

## Linear Hypotheses:

## Estimate Std. Error z value Pr(>|z|) ## Strobe - Dark == 0 0.4540 0.1341 3.385 0.00213 ** ## Lit - Dark == 0 0.3494 0.1341 2.605 0.02756 * ## Strobe - Lit == 0 0.1046 0.1341 0.780 1.00000

## ---

## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 ## (Adjusted p values reported -- bonferroni method)