##Set working directory
setwd("C:/Users/ChanRW/OneDrive - Universiteit Twente/2020_MSCA_IF/2_Bachelor_thesis/Step_Emma/Data Analysis/Dataframes")
##Packages##
library(readxl)
## Warning: package 'readxl' was built under R version 3.6.3
library(haven)
## Warning: package 'haven' was built under R version 3.6.3
library(tidyverse)
## Warning: package 'tidyverse' was built under R version 3.6.3
## -- Attaching packages --------------------------------------- tidyverse 1.3.1 --
## v ggplot2 3.3.3 v purrr 0.3.4
## v tibble 3.1.1 v dplyr 1.0.6
## v tidyr 1.1.3 v stringr 1.4.0
## v readr 1.4.0 v forcats 0.5.1
## Warning: package 'ggplot2' was built under R version 3.6.3
## Warning: package 'tibble' was built under R version 3.6.3
## Warning: package 'tidyr' was built under R version 3.6.3
## Warning: package 'readr' was built under R version 3.6.3
## Warning: package 'purrr' was built under R version 3.6.3
## Warning: package 'dplyr' was built under R version 3.6.3
## Warning: package 'stringr' was built under R version 3.6.3
## Warning: package 'forcats' was built under R version 3.6.3
## -- Conflicts ------------------------------------------ tidyverse_conflicts() --
## x dplyr::filter() masks stats::filter()
## x dplyr::lag() masks stats::lag()
library(lme4)
## Warning: package 'lme4' was built under R version 3.6.3
## Loading required package: Matrix
##
## Attaching package: 'Matrix'
## The following objects are masked from 'package:tidyr':
##
## expand, pack, unpack
library(effects)
## Warning: package 'effects' was built under R version 3.6.3
## Loading required package: carData
## Warning: package 'carData' was built under R version 3.6.3
## lattice theme set by effectsTheme()
## See ?effectsTheme for details.
library(lattice)
## Warning: package 'lattice' was built under R version 3.6.3
library(car)
## Warning: package 'car' was built under R version 3.6.3
## Registered S3 methods overwritten by 'car':
## method from
## influence.merMod lme4
## cooks.distance.influence.merMod lme4
## dfbeta.influence.merMod lme4
## dfbetas.influence.merMod lme4
##
## Attaching package: 'car'
## The following object is masked from 'package:dplyr':
##
## recode
## The following object is masked from 'package:purrr':
##
## some
library(ggplot2)
library(knitr)
## Warning: package 'knitr' was built under R version 3.6.3
library(reshape2)
## Warning: package 'reshape2' was built under R version 3.6.3
##
## Attaching package: 'reshape2'
## The following object is masked from 'package:tidyr':
##
## smiths
library(dplyr)
library(forcats)
library(DHARMa)
## Warning: package 'DHARMa' was built under R version 3.6.3
## This is DHARMa 0.4.1. For overview type '?DHARMa'. For recent changes, type news(package = 'DHARMa') Note: Syntax of plotResiduals has changed in 0.3.0, see ?plotResiduals for details
library(Hmisc)
## Warning: package 'Hmisc' was built under R version 3.6.3
## Loading required package: survival
## Loading required package: Formula
## Warning: package 'Formula' was built under R version 3.6.3
##
## Attaching package: 'Hmisc'
## The following objects are masked from 'package:dplyr':
##
## src, summarize
## The following objects are masked from 'package:base':
##
## format.pval, units
library(phia)
## Warning: package 'phia' was built under R version 3.6.3
library(lsmeans)
## Warning: package 'lsmeans' was built under R version 3.6.3
## Loading required package: emmeans
## Warning: package 'emmeans' was built under R version 3.6.3
## The 'lsmeans' package is now basically a front end for 'emmeans'.
## Users are encouraged to switch the rest of the way.
## See help('transition') for more information, including how to
## convert old 'lsmeans' objects and scripts to work with 'emmeans'.
library(emmeans)
library(multcomp)
## Warning: package 'multcomp' was built under R version 3.6.3
## Loading required package: mvtnorm
## Warning: package 'mvtnorm' was built under R version 3.6.3
## Loading required package: TH.data
## Warning: package 'TH.data' was built under R version 3.6.3
## Loading required package: MASS
##
## Attaching package: 'MASS'
## The following object is masked from 'package:dplyr':
##
## select
##
## Attaching package: 'TH.data'
## The following object is masked from 'package:MASS':
##
## geyser
library(nlme)
## Warning: package 'nlme' was built under R version 3.6.3
##
## Attaching package: 'nlme'
## The following object is masked from 'package:lme4':
##
## lmList
## The following object is masked from 'package:dplyr':
##
## collapse
##Import dataset from the directory
df <- readxl::read_excel("C://Users//ChanRW//OneDrive - Universiteit Twente//2020_MSCA_IF//2_Bachelor_thesis//Step_Emma//Data Analysis//Dataframes//df_keypresslevel2.xlsx")
#Creating factors
df$subject <- factor(df$subject)
df$Block <- factor(df$session)
df$key <- factor(df$key)
df$accuracy <- factor(df$accuracy)
#Fifth model: Feedback.RT - Finger position - Block
m.footstep1 <- lmer(RT ~ key * Block + (accuracy|subject), data = df)
Anova(m.footstep1)
## Analysis of Deviance Table (Type II Wald chisquare tests)
##
## Response: RT
## Chisq Df Pr(>Chisq)
## key 299.675 5 < 2.2e-16 ***
## Block 794.231 7 < 2.2e-16 ***
## key:Block 78.764 35 3.238e-05 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(m.footstep1)
## Linear mixed model fit by REML ['lmerMod']
## Formula: RT ~ key * Block + (accuracy | subject)
## Data: df
##
## REML criterion at convergence: 18749.4
##
## Scaled residuals:
## Min 1Q Median 3Q Max
## -3.104 -0.240 -0.067 0.120 53.995
##
## Random effects:
## Groups Name Variance Std.Dev. Corr
## subject (Intercept) 0.8139 0.9022
## accuracy1 0.4783 0.6916 -0.99
## Residual 0.2922 0.5406
## Number of obs: 11520, groups: subject, 5
##
## Fixed effects:
## Estimate Std. Error t value
## (Intercept) 7.890e-01 6.801e-02 11.601
## key2 -1.807e-01 4.936e-02 -3.661
## key3 -2.162e-01 4.936e-02 -4.381
## key4 -2.681e-01 4.941e-02 -5.425
## key5 -5.984e-02 4.939e-02 -1.212
## key6 2.204e-01 4.938e-02 4.464
## Block2 -2.385e-01 4.941e-02 -4.827
## Block3 -3.406e-01 4.942e-02 -6.892
## Block4 -3.668e-01 4.941e-02 -7.424
## Block5 -3.460e-01 4.940e-02 -7.003
## Block6 -3.513e-01 4.942e-02 -7.109
## Block7 -4.133e-01 4.942e-02 -8.363
## Block8 -4.891e-01 4.941e-02 -9.899
## key2:Block2 -4.578e-02 6.979e-02 -0.656
## key3:Block2 -5.925e-02 6.979e-02 -0.849
## key4:Block2 -7.632e-02 6.982e-02 -1.093
## key5:Block2 -2.334e-01 6.980e-02 -3.343
## key6:Block2 -4.053e-01 6.980e-02 -5.807
## key2:Block3 2.336e-02 6.979e-02 0.335
## key3:Block3 -6.659e-05 6.979e-02 -0.001
## key4:Block3 -3.624e-03 6.982e-02 -0.052
## key5:Block3 -1.306e-01 6.981e-02 -1.871
## key6:Block3 -3.041e-01 6.981e-02 -4.357
## key2:Block4 2.991e-02 6.979e-02 0.429
## key3:Block4 2.092e-02 6.979e-02 0.300
## key4:Block4 2.957e-02 6.983e-02 0.424
## key5:Block4 -1.021e-01 6.982e-02 -1.462
## key6:Block4 -3.183e-01 6.981e-02 -4.560
## key2:Block5 -1.899e-02 6.979e-02 -0.272
## key3:Block5 5.065e-04 6.979e-02 0.007
## key4:Block5 1.328e-02 6.983e-02 0.190
## key5:Block5 -1.233e-01 6.981e-02 -1.767
## key6:Block5 -3.333e-01 6.981e-02 -4.774
## key2:Block6 -2.683e-02 6.979e-02 -0.384
## key3:Block6 -2.289e-02 6.979e-02 -0.328
## key4:Block6 -5.103e-03 6.982e-02 -0.073
## key5:Block6 -1.628e-01 6.980e-02 -2.332
## key6:Block6 -3.168e-01 6.981e-02 -4.538
## key2:Block7 3.991e-02 6.979e-02 0.572
## key3:Block7 3.816e-02 6.980e-02 0.547
## key4:Block7 5.600e-02 6.982e-02 0.802
## key5:Block7 -8.693e-02 6.981e-02 -1.245
## key6:Block7 -2.970e-01 6.981e-02 -4.254
## key2:Block8 9.970e-02 6.979e-02 1.429
## key3:Block8 9.613e-02 6.979e-02 1.377
## key4:Block8 1.027e-01 6.982e-02 1.470
## key5:Block8 -3.140e-02 6.980e-02 -0.450
## key6:Block8 -2.175e-01 6.981e-02 -3.116
##
## Correlation matrix not shown by default, as p = 48 > 12.
## Use print(x, correlation=TRUE) or
## vcov(x) if you need it
##M1
#Need Effects lib
ae.m.footstep1<-allEffects(m.footstep1)
ae.m.df.footstep1<-as.data.frame(ae.m.footstep1[[1]])
#The main plot.
ae.position<-ggplot(ae.m.df.footstep1, aes(x=key,y=fit, group=Block))+
geom_ribbon(aes(ymin=lower, ymax=upper, fill=Block), alpha=0.2) +
geom_line(aes(size=0.5, color=Block)) +
geom_point(aes(color=Block, size=2))+
ylab("RT (ms)")+
xlab("Position")+
theme_classic()
#Printing Session effects facet
print(ae.position)
#Interaction post-hocs (Fifth model)
lsmeans(m.footstep1, pairwise ~ Block | key)
## Note: D.f. calculations have been disabled because the number of observations exceeds 3000.
## To enable adjustments, add the argument 'pbkrtest.limit = 11520' (or larger)
## [or, globally, 'set emm_options(pbkrtest.limit = 11520)' or larger];
## but be warned that this may result in large computation time and memory use.
## Note: D.f. calculations have been disabled because the number of observations exceeds 3000.
## To enable adjustments, add the argument 'lmerTest.limit = 11520' (or larger)
## [or, globally, 'set emm_options(lmerTest.limit = 11520)' or larger];
## but be warned that this may result in large computation time and memory use.
## $lsmeans
## key = 1:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 0.789 0.0680 Inf 0.65566 0.922
## 2 0.550 0.0677 Inf 0.41774 0.683
## 3 0.448 0.0677 Inf 0.31556 0.581
## 4 0.422 0.0678 Inf 0.28934 0.555
## 5 0.443 0.0677 Inf 0.31023 0.576
## 6 0.438 0.0677 Inf 0.30492 0.570
## 7 0.376 0.0677 Inf 0.24293 0.508
## 8 0.300 0.0677 Inf 0.16709 0.433
##
## key = 2:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 0.608 0.0682 Inf 0.47459 0.742
## 2 0.324 0.0678 Inf 0.19114 0.457
## 3 0.291 0.0678 Inf 0.15814 0.424
## 4 0.271 0.0678 Inf 0.13854 0.404
## 5 0.243 0.0678 Inf 0.11046 0.376
## 6 0.230 0.0678 Inf 0.09730 0.363
## 7 0.235 0.0677 Inf 0.10204 0.368
## 8 0.219 0.0678 Inf 0.08598 0.352
##
## key = 3:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 0.573 0.0682 Inf 0.43911 0.706
## 2 0.275 0.0678 Inf 0.14209 0.408
## 3 0.232 0.0678 Inf 0.09923 0.365
## 4 0.227 0.0678 Inf 0.09399 0.360
## 5 0.227 0.0678 Inf 0.09440 0.360
## 6 0.199 0.0678 Inf 0.06567 0.331
## 7 0.198 0.0678 Inf 0.06472 0.330
## 8 0.180 0.0678 Inf 0.04687 0.313
##
## key = 4:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 0.521 0.0683 Inf 0.38693 0.655
## 2 0.206 0.0679 Inf 0.07306 0.339
## 3 0.177 0.0679 Inf 0.04359 0.310
## 4 0.184 0.0678 Inf 0.05075 0.317
## 5 0.188 0.0678 Inf 0.05530 0.321
## 6 0.164 0.0678 Inf 0.03156 0.297
## 7 0.164 0.0678 Inf 0.03062 0.296
## 8 0.134 0.0678 Inf 0.00151 0.267
##
## key = 5:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 0.729 0.0683 Inf 0.59528 0.863
## 2 0.257 0.0679 Inf 0.12420 0.390
## 3 0.258 0.0679 Inf 0.12486 0.391
## 4 0.260 0.0677 Inf 0.12747 0.393
## 5 0.260 0.0678 Inf 0.12701 0.393
## 6 0.215 0.0678 Inf 0.08213 0.348
## 7 0.229 0.0678 Inf 0.09592 0.362
## 8 0.209 0.0678 Inf 0.07568 0.341
##
## key = 6:
## Block lsmean SE df asymp.LCL asymp.UCL
## 1 1.009 0.0680 Inf 0.87618 1.143
## 2 0.366 0.0677 Inf 0.23286 0.498
## 3 0.365 0.0677 Inf 0.23199 0.497
## 4 0.324 0.0677 Inf 0.19150 0.457
## 5 0.330 0.0677 Inf 0.19745 0.463
## 6 0.341 0.0677 Inf 0.20863 0.474
## 7 0.299 0.0677 Inf 0.16633 0.432
## 8 0.303 0.0677 Inf 0.17013 0.435
##
## Degrees-of-freedom method: asymptotic
## Confidence level used: 0.95
##
## $contrasts
## key = 1:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.238494 0.0494 Inf 4.827 <.0001
## 1 - 3 0.340617 0.0494 Inf 6.892 <.0001
## 1 - 4 0.366797 0.0494 Inf 7.424 <.0001
## 1 - 5 0.345983 0.0494 Inf 7.003 <.0001
## 1 - 6 0.351302 0.0494 Inf 7.109 <.0001
## 1 - 7 0.413335 0.0494 Inf 8.363 <.0001
## 1 - 8 0.489145 0.0494 Inf 9.899 <.0001
## 2 - 3 0.102123 0.0493 Inf 2.069 0.4349
## 2 - 4 0.128303 0.0493 Inf 2.600 0.1557
## 2 - 5 0.107489 0.0493 Inf 2.178 0.3650
## 2 - 6 0.112808 0.0493 Inf 2.286 0.3012
## 2 - 7 0.174841 0.0493 Inf 3.543 0.0094
## 2 - 8 0.250651 0.0493 Inf 5.079 <.0001
## 3 - 4 0.026180 0.0493 Inf 0.531 0.9995
## 3 - 5 0.005366 0.0494 Inf 0.109 1.0000
## 3 - 6 0.010685 0.0493 Inf 0.217 1.0000
## 3 - 7 0.072718 0.0493 Inf 1.474 0.8218
## 3 - 8 0.148529 0.0493 Inf 3.010 0.0532
## 4 - 5 -0.020814 0.0494 Inf -0.422 0.9999
## 4 - 6 -0.015495 0.0494 Inf -0.314 1.0000
## 4 - 7 0.046538 0.0493 Inf 0.943 0.9818
## 4 - 8 0.122348 0.0493 Inf 2.479 0.2042
## 5 - 6 0.005319 0.0494 Inf 0.108 1.0000
## 5 - 7 0.067352 0.0494 Inf 1.365 0.8733
## 5 - 8 0.143163 0.0494 Inf 2.901 0.0724
## 6 - 7 0.062033 0.0493 Inf 1.257 0.9144
## 6 - 8 0.137843 0.0493 Inf 2.793 0.0966
## 7 - 8 0.075810 0.0493 Inf 1.536 0.7878
##
## key = 2:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.284269 0.0494 Inf 5.750 <.0001
## 1 - 3 0.317257 0.0495 Inf 6.413 <.0001
## 1 - 4 0.336887 0.0495 Inf 6.811 <.0001
## 1 - 5 0.364973 0.0495 Inf 7.379 <.0001
## 1 - 6 0.378132 0.0495 Inf 7.644 <.0001
## 1 - 7 0.373422 0.0495 Inf 7.547 <.0001
## 1 - 8 0.389448 0.0495 Inf 7.873 <.0001
## 2 - 3 0.032988 0.0494 Inf 0.668 0.9978
## 2 - 4 0.052617 0.0494 Inf 1.066 0.9637
## 2 - 5 0.080703 0.0494 Inf 1.635 0.7290
## 2 - 6 0.093863 0.0493 Inf 1.902 0.5494
## 2 - 7 0.089153 0.0494 Inf 1.806 0.6156
## 2 - 8 0.105178 0.0494 Inf 2.131 0.3946
## 3 - 4 0.019630 0.0494 Inf 0.398 0.9999
## 3 - 5 0.047716 0.0494 Inf 0.967 0.9790
## 3 - 6 0.060875 0.0494 Inf 1.234 0.9221
## 3 - 7 0.056165 0.0494 Inf 1.138 0.9485
## 3 - 8 0.072191 0.0494 Inf 1.463 0.8273
## 4 - 5 0.028086 0.0494 Inf 0.569 0.9992
## 4 - 6 0.041245 0.0494 Inf 0.836 0.9911
## 4 - 7 0.036535 0.0494 Inf 0.740 0.9958
## 4 - 8 0.052561 0.0494 Inf 1.065 0.9639
## 5 - 6 0.013159 0.0494 Inf 0.267 1.0000
## 5 - 7 0.008449 0.0494 Inf 0.171 1.0000
## 5 - 8 0.024475 0.0494 Inf 0.496 0.9997
## 6 - 7 -0.004710 0.0493 Inf -0.095 1.0000
## 6 - 8 0.011315 0.0493 Inf 0.229 1.0000
## 7 - 8 0.016026 0.0493 Inf 0.325 1.0000
##
## key = 3:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.297749 0.0495 Inf 6.020 <.0001
## 1 - 3 0.340683 0.0495 Inf 6.884 <.0001
## 1 - 4 0.345874 0.0495 Inf 6.992 <.0001
## 1 - 5 0.345476 0.0495 Inf 6.985 <.0001
## 1 - 6 0.374194 0.0495 Inf 7.563 <.0001
## 1 - 7 0.375179 0.0495 Inf 7.580 <.0001
## 1 - 8 0.393011 0.0495 Inf 7.944 <.0001
## 2 - 3 0.042934 0.0493 Inf 0.870 0.9887
## 2 - 4 0.048125 0.0494 Inf 0.975 0.9780
## 2 - 5 0.047727 0.0494 Inf 0.967 0.9790
## 2 - 6 0.076445 0.0493 Inf 1.549 0.7805
## 2 - 7 0.077429 0.0493 Inf 1.569 0.7690
## 2 - 8 0.095262 0.0493 Inf 1.930 0.5297
## 3 - 4 0.005191 0.0494 Inf 0.105 1.0000
## 3 - 5 0.004793 0.0494 Inf 0.097 1.0000
## 3 - 6 0.033511 0.0493 Inf 0.679 0.9975
## 3 - 7 0.034495 0.0494 Inf 0.699 0.9970
## 3 - 8 0.052327 0.0493 Inf 1.060 0.9648
## 4 - 5 -0.000398 0.0494 Inf -0.008 1.0000
## 4 - 6 0.028320 0.0494 Inf 0.574 0.9992
## 4 - 7 0.029305 0.0494 Inf 0.594 0.9990
## 4 - 8 0.047137 0.0494 Inf 0.955 0.9804
## 5 - 6 0.028718 0.0494 Inf 0.582 0.9991
## 5 - 7 0.029702 0.0494 Inf 0.602 0.9989
## 5 - 8 0.047535 0.0494 Inf 0.963 0.9795
## 6 - 7 0.000984 0.0494 Inf 0.020 1.0000
## 6 - 8 0.018816 0.0493 Inf 0.381 0.9999
## 7 - 8 0.017832 0.0493 Inf 0.361 1.0000
##
## key = 4:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.314815 0.0495 Inf 6.357 <.0001
## 1 - 3 0.344241 0.0495 Inf 6.949 <.0001
## 1 - 4 0.337223 0.0495 Inf 6.808 <.0001
## 1 - 5 0.332705 0.0495 Inf 6.716 <.0001
## 1 - 6 0.356405 0.0495 Inf 7.196 <.0001
## 1 - 7 0.357340 0.0495 Inf 7.214 <.0001
## 1 - 8 0.386478 0.0495 Inf 7.802 <.0001
## 2 - 3 0.029426 0.0494 Inf 0.596 0.9989
## 2 - 4 0.022408 0.0494 Inf 0.454 0.9998
## 2 - 5 0.017890 0.0494 Inf 0.362 1.0000
## 2 - 6 0.041590 0.0493 Inf 0.843 0.9906
## 2 - 7 0.042525 0.0494 Inf 0.862 0.9893
## 2 - 8 0.071663 0.0493 Inf 1.452 0.8326
## 3 - 4 -0.007018 0.0494 Inf -0.142 1.0000
## 3 - 5 -0.011536 0.0494 Inf -0.234 1.0000
## 3 - 6 0.012164 0.0494 Inf 0.246 1.0000
## 3 - 7 0.013099 0.0494 Inf 0.265 1.0000
## 3 - 8 0.042237 0.0494 Inf 0.856 0.9897
## 4 - 5 -0.004518 0.0494 Inf -0.092 1.0000
## 4 - 6 0.019182 0.0494 Inf 0.389 0.9999
## 4 - 7 0.020117 0.0494 Inf 0.408 0.9999
## 4 - 8 0.049254 0.0494 Inf 0.998 0.9749
## 5 - 6 0.023700 0.0494 Inf 0.480 0.9997
## 5 - 7 0.024635 0.0494 Inf 0.499 0.9997
## 5 - 8 0.053773 0.0494 Inf 1.089 0.9592
## 6 - 7 0.000935 0.0494 Inf 0.019 1.0000
## 6 - 8 0.030073 0.0493 Inf 0.609 0.9988
## 7 - 8 0.029138 0.0494 Inf 0.590 0.9990
##
## key = 5:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.471873 0.0495 Inf 9.533 <.0001
## 1 - 3 0.471214 0.0495 Inf 9.513 <.0001
## 1 - 4 0.468882 0.0495 Inf 9.465 <.0001
## 1 - 5 0.469304 0.0495 Inf 9.476 <.0001
## 1 - 6 0.514084 0.0495 Inf 10.382 <.0001
## 1 - 7 0.500260 0.0495 Inf 10.100 <.0001
## 1 - 8 0.520544 0.0495 Inf 10.512 <.0001
## 2 - 3 -0.000658 0.0494 Inf -0.013 1.0000
## 2 - 4 -0.002990 0.0494 Inf -0.061 1.0000
## 2 - 5 -0.002569 0.0494 Inf -0.052 1.0000
## 2 - 6 0.042211 0.0493 Inf 0.855 0.9898
## 2 - 7 0.028387 0.0493 Inf 0.575 0.9992
## 2 - 8 0.048672 0.0493 Inf 0.986 0.9765
## 3 - 4 -0.002332 0.0494 Inf -0.047 1.0000
## 3 - 5 -0.001910 0.0494 Inf -0.039 1.0000
## 3 - 6 0.042869 0.0494 Inf 0.869 0.9888
## 3 - 7 0.029046 0.0494 Inf 0.589 0.9990
## 3 - 8 0.049330 0.0494 Inf 0.999 0.9747
## 4 - 5 0.000421 0.0493 Inf 0.009 1.0000
## 4 - 6 0.045201 0.0494 Inf 0.916 0.9847
## 4 - 7 0.031378 0.0494 Inf 0.636 0.9984
## 4 - 8 0.051662 0.0494 Inf 1.047 0.9672
## 5 - 6 0.044780 0.0494 Inf 0.907 0.9855
## 5 - 7 0.030956 0.0494 Inf 0.627 0.9985
## 5 - 8 0.051240 0.0494 Inf 1.038 0.9687
## 6 - 7 -0.013824 0.0493 Inf -0.280 1.0000
## 6 - 8 0.006461 0.0493 Inf 0.131 1.0000
## 7 - 8 0.020284 0.0493 Inf 0.411 0.9999
##
## key = 6:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.643790 0.0494 Inf 13.032 <.0001
## 1 - 3 0.644734 0.0494 Inf 13.043 <.0001
## 1 - 4 0.685117 0.0494 Inf 13.861 <.0001
## 1 - 5 0.679245 0.0494 Inf 13.743 <.0001
## 1 - 6 0.668086 0.0494 Inf 13.516 <.0001
## 1 - 7 0.710332 0.0494 Inf 14.369 <.0001
## 1 - 8 0.706633 0.0494 Inf 14.295 <.0001
## 2 - 3 0.000944 0.0493 Inf 0.019 1.0000
## 2 - 4 0.041326 0.0494 Inf 0.837 0.9910
## 2 - 5 0.035454 0.0493 Inf 0.718 0.9965
## 2 - 6 0.024296 0.0493 Inf 0.492 0.9997
## 2 - 7 0.066541 0.0494 Inf 1.348 0.8802
## 2 - 8 0.062843 0.0494 Inf 1.273 0.9088
## 3 - 4 0.040382 0.0493 Inf 0.818 0.9922
## 3 - 5 0.034510 0.0493 Inf 0.699 0.9970
## 3 - 6 0.023352 0.0493 Inf 0.473 0.9998
## 3 - 7 0.065597 0.0493 Inf 1.329 0.8879
## 3 - 8 0.061899 0.0493 Inf 1.254 0.9153
## 4 - 5 -0.005872 0.0493 Inf -0.119 1.0000
## 4 - 6 -0.017030 0.0493 Inf -0.345 1.0000
## 4 - 7 0.025215 0.0493 Inf 0.511 0.9996
## 4 - 8 0.021517 0.0493 Inf 0.436 0.9999
## 5 - 6 -0.011158 0.0493 Inf -0.226 1.0000
## 5 - 7 0.031087 0.0493 Inf 0.630 0.9985
## 5 - 8 0.027389 0.0493 Inf 0.555 0.9993
## 6 - 7 0.042245 0.0493 Inf 0.856 0.9897
## 6 - 8 0.038547 0.0493 Inf 0.781 0.9941
## 7 - 8 -0.003698 0.0493 Inf -0.075 1.0000
##
## Degrees-of-freedom method: asymptotic
## P value adjustment: tukey method for comparing a family of 8 estimates
lsmeans(m.footstep1, pairwise ~ key | Block)
## Note: D.f. calculations have been disabled because the number of observations exceeds 3000.
## To enable adjustments, add the argument 'pbkrtest.limit = 11520' (or larger)
## [or, globally, 'set emm_options(pbkrtest.limit = 11520)' or larger];
## but be warned that this may result in large computation time and memory use.
## Note: D.f. calculations have been disabled because the number of observations exceeds 3000.
## To enable adjustments, add the argument 'lmerTest.limit = 11520' (or larger)
## [or, globally, 'set emm_options(lmerTest.limit = 11520)' or larger];
## but be warned that this may result in large computation time and memory use.
## $lsmeans
## Block = 1:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.789 0.0680 Inf 0.65566 0.922
## 2 0.608 0.0682 Inf 0.47459 0.742
## 3 0.573 0.0682 Inf 0.43911 0.706
## 4 0.521 0.0683 Inf 0.38693 0.655
## 5 0.729 0.0683 Inf 0.59528 0.863
## 6 1.009 0.0680 Inf 0.87618 1.143
##
## Block = 2:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.550 0.0677 Inf 0.41774 0.683
## 2 0.324 0.0678 Inf 0.19114 0.457
## 3 0.275 0.0678 Inf 0.14209 0.408
## 4 0.206 0.0679 Inf 0.07306 0.339
## 5 0.257 0.0679 Inf 0.12420 0.390
## 6 0.366 0.0677 Inf 0.23286 0.498
##
## Block = 3:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.448 0.0677 Inf 0.31556 0.581
## 2 0.291 0.0678 Inf 0.15814 0.424
## 3 0.232 0.0678 Inf 0.09923 0.365
## 4 0.177 0.0679 Inf 0.04359 0.310
## 5 0.258 0.0679 Inf 0.12486 0.391
## 6 0.365 0.0677 Inf 0.23199 0.497
##
## Block = 4:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.422 0.0678 Inf 0.28934 0.555
## 2 0.271 0.0678 Inf 0.13854 0.404
## 3 0.227 0.0678 Inf 0.09399 0.360
## 4 0.184 0.0678 Inf 0.05075 0.317
## 5 0.260 0.0677 Inf 0.12747 0.393
## 6 0.324 0.0677 Inf 0.19150 0.457
##
## Block = 5:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.443 0.0677 Inf 0.31023 0.576
## 2 0.243 0.0678 Inf 0.11046 0.376
## 3 0.227 0.0678 Inf 0.09440 0.360
## 4 0.188 0.0678 Inf 0.05530 0.321
## 5 0.260 0.0678 Inf 0.12701 0.393
## 6 0.330 0.0677 Inf 0.19745 0.463
##
## Block = 6:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.438 0.0677 Inf 0.30492 0.570
## 2 0.230 0.0678 Inf 0.09730 0.363
## 3 0.199 0.0678 Inf 0.06567 0.331
## 4 0.164 0.0678 Inf 0.03156 0.297
## 5 0.215 0.0678 Inf 0.08213 0.348
## 6 0.341 0.0677 Inf 0.20863 0.474
##
## Block = 7:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.376 0.0677 Inf 0.24293 0.508
## 2 0.235 0.0677 Inf 0.10204 0.368
## 3 0.198 0.0678 Inf 0.06472 0.330
## 4 0.164 0.0678 Inf 0.03062 0.296
## 5 0.229 0.0678 Inf 0.09592 0.362
## 6 0.299 0.0677 Inf 0.16633 0.432
##
## Block = 8:
## key lsmean SE df asymp.LCL asymp.UCL
## 1 0.300 0.0677 Inf 0.16709 0.433
## 2 0.219 0.0678 Inf 0.08598 0.352
## 3 0.180 0.0678 Inf 0.04687 0.313
## 4 0.134 0.0678 Inf 0.00151 0.267
## 5 0.209 0.0678 Inf 0.07568 0.341
## 6 0.303 0.0677 Inf 0.17013 0.435
##
## Degrees-of-freedom method: asymptotic
## Confidence level used: 0.95
##
## $contrasts
## Block = 1:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.18072 0.0494 Inf 3.661 0.0034
## 1 - 3 0.21624 0.0494 Inf 4.381 0.0002
## 1 - 4 0.26809 0.0494 Inf 5.425 <.0001
## 1 - 5 0.05984 0.0494 Inf 1.212 0.8314
## 1 - 6 -0.22044 0.0494 Inf -4.464 0.0001
## 2 - 3 0.03552 0.0494 Inf 0.720 0.9796
## 2 - 4 0.08737 0.0494 Inf 1.769 0.4859
## 2 - 5 -0.12088 0.0494 Inf -2.449 0.1397
## 2 - 6 -0.40116 0.0494 Inf -8.121 <.0001
## 3 - 4 0.05184 0.0494 Inf 1.050 0.9010
## 3 - 5 -0.15640 0.0494 Inf -3.169 0.0191
## 3 - 6 -0.43668 0.0494 Inf -8.840 <.0001
## 4 - 5 -0.20825 0.0494 Inf -4.218 0.0004
## 4 - 6 -0.48853 0.0494 Inf -9.890 <.0001
## 5 - 6 -0.28028 0.0494 Inf -5.673 <.0001
##
## Block = 2:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.22649 0.0493 Inf 4.590 0.0001
## 1 - 3 0.27550 0.0494 Inf 5.582 <.0001
## 1 - 4 0.34441 0.0494 Inf 6.975 <.0001
## 1 - 5 0.29322 0.0494 Inf 5.939 <.0001
## 1 - 6 0.18485 0.0494 Inf 3.746 0.0025
## 2 - 3 0.04900 0.0494 Inf 0.993 0.9204
## 2 - 4 0.11791 0.0494 Inf 2.388 0.1602
## 2 - 5 0.06672 0.0494 Inf 1.352 0.7559
## 2 - 6 -0.04164 0.0494 Inf -0.844 0.9593
## 3 - 4 0.06891 0.0494 Inf 1.396 0.7294
## 3 - 5 0.01772 0.0494 Inf 0.359 0.9992
## 3 - 6 -0.09064 0.0494 Inf -1.836 0.4422
## 4 - 5 -0.05119 0.0493 Inf -1.037 0.9054
## 4 - 6 -0.15955 0.0494 Inf -3.231 0.0156
## 5 - 6 -0.10836 0.0494 Inf -2.195 0.2401
##
## Block = 3:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.15736 0.0494 Inf 3.189 0.0179
## 1 - 3 0.21631 0.0494 Inf 4.382 0.0002
## 1 - 4 0.27171 0.0494 Inf 5.504 <.0001
## 1 - 5 0.19044 0.0494 Inf 3.857 0.0016
## 1 - 6 0.08367 0.0493 Inf 1.696 0.5347
## 2 - 3 0.05895 0.0493 Inf 1.195 0.8397
## 2 - 4 0.11435 0.0494 Inf 2.317 0.1871
## 2 - 5 0.03308 0.0494 Inf 0.670 0.9852
## 2 - 6 -0.07368 0.0494 Inf -1.493 0.6688
## 3 - 4 0.05540 0.0494 Inf 1.123 0.8722
## 3 - 5 -0.02587 0.0494 Inf -0.524 0.9952
## 3 - 6 -0.13263 0.0494 Inf -2.687 0.0777
## 4 - 5 -0.08128 0.0493 Inf -1.647 0.5671
## 4 - 6 -0.18804 0.0494 Inf -3.808 0.0019
## 5 - 6 -0.10676 0.0494 Inf -2.162 0.2556
##
## Block = 4:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.15081 0.0493 Inf 3.056 0.0272
## 1 - 3 0.19532 0.0493 Inf 3.958 0.0011
## 1 - 4 0.23851 0.0494 Inf 4.833 <.0001
## 1 - 5 0.16192 0.0494 Inf 3.281 0.0133
## 1 - 6 0.09788 0.0493 Inf 1.983 0.3518
## 2 - 3 0.04451 0.0493 Inf 0.902 0.9461
## 2 - 4 0.08770 0.0494 Inf 1.777 0.4807
## 2 - 5 0.01111 0.0494 Inf 0.225 0.9999
## 2 - 6 -0.05293 0.0493 Inf -1.073 0.8924
## 3 - 4 0.04319 0.0493 Inf 0.875 0.9525
## 3 - 5 -0.03340 0.0494 Inf -0.677 0.9845
## 3 - 6 -0.09744 0.0493 Inf -1.975 0.3570
## 4 - 5 -0.07659 0.0493 Inf -1.552 0.6304
## 4 - 6 -0.14064 0.0494 Inf -2.849 0.0500
## 5 - 6 -0.06405 0.0494 Inf -1.298 0.7865
##
## Block = 5:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.19971 0.0494 Inf 4.047 0.0007
## 1 - 3 0.21573 0.0494 Inf 4.371 0.0002
## 1 - 4 0.25481 0.0494 Inf 5.162 <.0001
## 1 - 5 0.18316 0.0494 Inf 3.711 0.0028
## 1 - 6 0.11282 0.0493 Inf 2.286 0.1995
## 2 - 3 0.01603 0.0493 Inf 0.325 0.9995
## 2 - 4 0.05510 0.0493 Inf 1.117 0.8747
## 2 - 5 -0.01655 0.0493 Inf -0.335 0.9994
## 2 - 6 -0.08689 0.0494 Inf -1.761 0.4915
## 3 - 4 0.03907 0.0493 Inf 0.792 0.9690
## 3 - 5 -0.03258 0.0493 Inf -0.660 0.9862
## 3 - 6 -0.10292 0.0494 Inf -2.085 0.2950
## 4 - 5 -0.07165 0.0493 Inf -1.452 0.6950
## 4 - 6 -0.14199 0.0494 Inf -2.877 0.0463
## 5 - 6 -0.07034 0.0494 Inf -1.425 0.7116
##
## Block = 6:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.20755 0.0493 Inf 4.206 0.0004
## 1 - 3 0.23913 0.0494 Inf 4.845 <.0001
## 1 - 4 0.27319 0.0494 Inf 5.534 <.0001
## 1 - 5 0.22262 0.0494 Inf 4.510 0.0001
## 1 - 6 0.09634 0.0493 Inf 1.952 0.3702
## 2 - 3 0.03159 0.0493 Inf 0.640 0.9880
## 2 - 4 0.06564 0.0494 Inf 1.330 0.7684
## 2 - 5 0.01507 0.0494 Inf 0.305 0.9996
## 2 - 6 -0.11121 0.0494 Inf -2.253 0.2135
## 3 - 4 0.03406 0.0493 Inf 0.690 0.9831
## 3 - 5 -0.01651 0.0493 Inf -0.335 0.9994
## 3 - 6 -0.14279 0.0494 Inf -2.893 0.0442
## 4 - 5 -0.05057 0.0493 Inf -1.025 0.9098
## 4 - 6 -0.17685 0.0494 Inf -3.582 0.0046
## 5 - 6 -0.12628 0.0494 Inf -2.558 0.1079
##
## Block = 7:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.14081 0.0494 Inf 2.853 0.0495
## 1 - 3 0.17808 0.0494 Inf 3.608 0.0042
## 1 - 4 0.21209 0.0494 Inf 4.297 0.0003
## 1 - 5 0.14676 0.0494 Inf 2.973 0.0350
## 1 - 6 0.07655 0.0494 Inf 1.551 0.6310
## 2 - 3 0.03728 0.0493 Inf 0.755 0.9747
## 2 - 4 0.07129 0.0493 Inf 1.445 0.6996
## 2 - 5 0.00596 0.0494 Inf 0.121 1.0000
## 2 - 6 -0.06425 0.0494 Inf -1.302 0.7844
## 3 - 4 0.03401 0.0493 Inf 0.689 0.9832
## 3 - 5 -0.03132 0.0493 Inf -0.635 0.9884
## 3 - 6 -0.10153 0.0494 Inf -2.056 0.3106
## 4 - 5 -0.06533 0.0493 Inf -1.324 0.7719
## 4 - 6 -0.13554 0.0494 Inf -2.745 0.0667
## 5 - 6 -0.07021 0.0494 Inf -1.422 0.7137
##
## Block = 8:
## contrast estimate SE df z.ratio p.value
## 1 - 2 0.08102 0.0494 Inf 1.642 0.5707
## 1 - 3 0.12011 0.0494 Inf 2.433 0.1447
## 1 - 4 0.16542 0.0494 Inf 3.351 0.0104
## 1 - 5 0.09124 0.0494 Inf 1.848 0.4346
## 1 - 6 -0.00296 0.0494 Inf -0.060 1.0000
## 2 - 3 0.03909 0.0493 Inf 0.792 0.9690
## 2 - 4 0.08440 0.0493 Inf 1.710 0.5249
## 2 - 5 0.01022 0.0493 Inf 0.207 0.9999
## 2 - 6 -0.08398 0.0494 Inf -1.701 0.5310
## 3 - 4 0.04531 0.0493 Inf 0.918 0.9420
## 3 - 5 -0.02887 0.0493 Inf -0.585 0.9920
## 3 - 6 -0.12306 0.0494 Inf -2.493 0.1262
## 4 - 5 -0.07418 0.0493 Inf -1.503 0.6622
## 4 - 6 -0.16837 0.0494 Inf -3.410 0.0085
## 5 - 6 -0.09419 0.0494 Inf -1.907 0.3976
##
## Degrees-of-freedom method: asymptotic
## P value adjustment: tukey method for comparing a family of 6 estimates