The aim

  • Here, we tested the effect of even spacing of sensitivities on colour discrimination in a tetrachromatic visual system. Specifically, we ran visual models with an evenly spaced visual system and an unevenly spaced visual system, then compared spectral contrast in all three comparison groups (‘leaf vs. flower’, ‘leaf vs. beetle’, ‘beetle vs. flower’).

  • These two visual systems have the same upper and lower sensitivities with varying distribution of the two middle sensitivities. The evenly spaced visual system has peak sensitivities at 355 nm, 455 nm, 560 nm, and 660 nm, while VS 660 from the Main models section is used to represent the unevenly spaced visual system, with peak sensitivities at 355 nm, 445 nm, 530 nm, and 660 nm.

  • The model parameters and the statistical methods remain the same as described in the main text.



Sensitivity curves

Figure caption: Sensitivity curves of the evenly spaced visual system (solid lines) and the unevenly spaced visual system (VS 660; dotted lines).

Figure caption: Sensitivity curves of the evenly spaced visual system (solid lines) and the unevenly spaced visual system (VS 660; dotted lines).



Normalised sensitivity curves

Figure caption: Normalised sensitivity curves of the evenly spaced visual system (solid lines) and the unevenly spaced visual system (VS 660; dotted lines).

Figure caption: Normalised sensitivity curves of the evenly spaced visual system (solid lines) and the unevenly spaced visual system (VS 660; dotted lines).



Data description

  • We used the same spectral data collected from beetles and plants as described in the Main models section.



Run the visual models

  • We ran the visual models with the same parameter settings and steps as in the main models.
## D65
get.d65.vismodel <- function(i){
  
  vs.i <- vismodel(dataset[1:501,], 
                   visual = i, #this need to change according to the visual system
                   bkg = aveleaf$aveleaf, 
                   illum = irradiance.d65[1:501,2], 
                   qcatch = 'fi', 
                   relative = FALSE,
                   vonkries = TRUE)
  return(vs.i)
}
get.evenspace.coldist <- function(i){
  
  con <- coldist(modeldata = i, # put output of vismodel()
                   noise="neural", 
                   achro=FALSE, 
                   n = c(1.14,1,1.26,1.38),
                   weber = 0.12,
                   weber.ref = 4)
  
  return(con)
}

#Contrast calculation
Cbuprest.even.space.d65  <-  get.evenspace.coldist(buprest.even.space.d65)

#VS660
Cbuprest660 <- get.evenspace.coldist(buprest660)

#combine all contrast value in each comparison group

even.vissys_d65 <- list(Cbuprest.even.space.d65, Cbuprest660)
even.fl.vissys <- list("even.fl", "Vis5.fl") 
even.bl.vissys <- list("even.bl", "Vis5.bl")
even.bf.vissys <- list("even.bf", "Vis5.bf") 

### flower vs leaf
allvis.fl_d65.even <- data_frame()
for (i in 1:length(even.vissys_d65)) {
  
  temp.i <- even.vissys_d65[[i]] %>% 
    filter(str_detect(patch1,"flower")) %>% 
    filter(str_detect(patch2,"leaves"))
  
  temp.i$vissys <- strrep(even.fl.vissys[[i]],1)
  
  allvis.fl_d65.even <- temp.i %>% rbind(allvis.fl_d65.even)  
}

### beetle vs leaf
allvis.bl_d65.even <- data_frame()
for (i in 1:length(even.vissys_d65)) {
  
  temp.i <- even.vissys_d65[[i]] %>% 
    filter(str_detect(patch2,"beetle")) %>% 
    filter(str_detect(patch1,"leaves"))
  
  temp.i$vissys <- strrep(even.bl.vissys[[i]],1)
  
  allvis.bl_d65.even <- temp.i %>% rbind(allvis.bl_d65.even)  
}

### beetle vs flower
allvis.bf_d65.even <- data_frame()
for (i in 1:length(even.vissys_d65)) {
  
  temp.i <- even.vissys_d65[[i]] %>% 
    filter(str_detect(patch1,"flower")) %>% 
    filter(str_detect(patch2,"beetle"))
  
  temp.i$vissys <- strrep(even.bf.vissys[[i]],1)
  
  allvis.bf_d65.even <- temp.i %>% rbind(allvis.bf_d65.even)  
}



Contrast tables

system flower.vs.leaf beetle.vs.leaf beetle.vs.flower
evenspace 7.439 6.187 7.684
VS 660 7.553 6.346 7.815



Compare contrasts

  • To compare contrasts between visual systems, We conducted Wald chi-square tests on generalised linear mixed models (GLMM) followed by posthoc tests.

  • In the models, we assigned

    • Independent variable: contrast
    • Dependent variable:
      • Fixed factor: visual system
      • Random factor: sample ID of both targets in the comparison


get.lmer <- function(datlist, compnnumber){
  
  lmer(dS ~ vissys + (1|patch2) + (1|patch1), 
       data = datlist[[compnnumber]], REML = F)
  #REML=F, in order to fit the model using the likelihood ratio test. Otherwise, the lmer default will fit the model using the REML (REstricted Maximum Likelihood) criterion.
}

get.posthocsum <- function(modelx){
  
  summary(glht(modelx, 
               linfct = mcp(vissys = "Tukey")), 
          test = adjusted("bonferroni"))
}

Flower vs. Leaf

Analysis of Deviance Table (Type II Wald chisquare tests)
  Chisq Df Pr(>Chisq)
vissys 9.796 1 0.001749



Beetle vs. Leaf

Analysis of Deviance Table (Type II Wald chisquare tests)
  Chisq Df Pr(>Chisq)
vissys 16.88 1 3.984e-05



Beetle vs. Flower

Analysis of Deviance Table (Type II Wald chisquare tests)
  Chisq Df Pr(>Chisq)
vissys 5.045 1 0.0247



Summary

For all three comparison groups, VS 660 (unevenly spaced visual system) has significantly higher contrast than the evenly spaced visual system. This indicates that our results were not biased by uneven spacing of spectral sensitivities in our hypothetical visual systems.