Data files underlying the figures in Gordon et al. "Expectation and attention increase the integration of top-down and bottom-up signals in perception through different pathways", PLoS Biology 2019.

Data for Figure 3 - DataPlosBio2019_Fig3.mat:
chanlocs = chanel locations for EEGLAB data structure.
roi = chanel numbers for posterior ROI. 
MspcStmPred = MSPCstim of the PV trials ('predictable') 
MspcStmUpred = MSPCstim of the IR trials ('unpredictable') 
MspcResPred = MSPCres of the PV trials ('predictable')
MspcResUpred= MSPCres of he IR trials ('unpredictable'). 
structure- chanel X IM (SSVEP-SWIFT and SSVEP+SWIFT) X trial. 

Data for Figure 4 - DataPlosBio2019_Fig4.mat:
chanlocs = chanel locations for EEGLAB data structure.
roi = chanel numbers for posterior ROI. 
MspcStmFce = MSPCstim of the 'count faces' trials.
MspcStmHse = MSPCstim of the 'count houses' trials.
MspcResFce = MSPCres of the 'count faces' trials.
MspcResHse = MSPCres of the 'count houses' trials.
structure- chanel X IM (SSVEP-SWIFT(face), SSVEP+SWIFT(face),SSVEP-SWIFT(house), SSVEP+SWIFT(house) ) X trial. 
For example, MspcStmFce(:,1:2,:) and MspcStmHse(:,3:4,:) signify  MSPCstim values of the counted (attended) images, while MspcStmFce(:,3:4,:) and MspcStmHse(:,1:2,:) signify  MSPCstim values of non-counted (unattended) images.

Data for figure S1a - DataPlosBio2019_S1a.mat:
fr10 = frequencies corresponding to Fourier-transform amplitue SNRs depicted in AmpPred and AmpUpred. Determined by the half bandwidth of the alanysis window, and the ability to compute SNR (which cannot be done near the edges of the spectrum)
AmpPred = Amplitude SNRs of the PV (predictable) trials
AmpUpred = Amplitude SNRs of the IR (unpredictable) trials
structure- chanel X frequency  X trial. 

Data for figure S1b - DataPlosBio2019_S1b.mat:
fr = frequencies corresponding to Fourier-transform amplitue SNRs depicted in Amp08, Amp10 and AmpCs. Determined by the half bandwidth of the alanysis window, and the ability to compute SNR (which cannot be done near the edges of the spectrum)
Amp08 = Fourier amplitude SNRs of the trials in which the image appearing at 0.8 Hz was counted (house or face, counterbalanced).
Amp10 = Fourier amplitude SNRs of the trials in which the image appearing at 1 Hz was counted (house or face, counterbalanced).
AmpCs =  Fourier amplitude SNRs of the trials in which the crosses were counted.

Data for figure S5 - DataPlosBio2019_S5.mat:
MspcRes2fAtt= MSPCres of the 4th-order IMs (2f2+2f1 and 2f2-2f1) of the counted (attended) images, computed using the phases of 2f1 and 2f2 as 'inputs' (i.e., considering the 4th-order IMs to be the 2nd-order IMs obtained from the interaction between the two 2nd harmonics).
MspcResffAtt= MSPCres of the 4th-order IMs (2f2+2f1 and 2f2-2f1) of the counted (attended) images, computed using the phases of f2+f1 and f2-f1 as 'inputs' (i.e., considering the 4th order IMs to be the 2nd harmonics of the 2nd-order IMs obtained from the interaction between the two fundamentals).
MspcRes2fUna= MSPCres of the 4th-order IMs (2f2+2f1 and 2f2-2f1) of the non-counted (unattended) images, computed using the phases of 2f1 and 2f2 as 'inputs'.
MspcResffUna= MSPCres of the 4th-order IMs (2f2+2f1 and 2f2-2f1) of the non-counted (unattended) images, computed using the phases of f2+f1 and f2-f1 as 'inputs'.

Data for Figure 5 - DataPlosBio2019_Fig5.Rda:
R data frame for Figure 5. The figure was created in R using the effects, ggplot2 and psych libraries.
The models:
mdlStmPlot= lmer(mspcStm ~ Att*uncert10 + (1|subject:chan:freq) + (0+uncert10|subject) + (0+Att|subject) + (0+Att:uncert10|subject), data=subset(dataSWSS, post==1 & (freq=="F8.7" | freq=="F11.3")),REML=TRUE)
mdlResPlot= lmer(mspcRes ~ Att*uncert10 + (1|subject:chan:freq) + (0+uncert10|subject) + (0+Att|subject) + (0+Att:uncert10|subject), data=subset(dataSWSS, post==1 & (freq=="F8.7" | freq=="F11.3")),REML=TRUE)
The code for creating the plot (the same code is used for MspcRes just with mdlResPlot in the first row instead of mdlStmPlot):
ef1 <- effect(term="Att*uncert10", mod=mdlStmPlot)
efdata1<-as.data.frame(ef1)
efdata1$Att < -as.factor(efdata1$Att)
gp <- ggplot(efdata1, aes(x=uncert10, y=fit, color=Att,group=Att)) + geom_line(size=2) +geom_ribbon(aes(ymin=fit-se, ymax=fit+se, fill=Att),alpha=0.2) + theme_classic() + theme(text=element_text(size=20)) + coord_cartesian(ylim = c(0.41, 0.48)) 
gp + scale_color_manual(values=c("palegreen1","green4")) + scale_fill_manual(values=c("palegreen1","green4"))