Statistical analyses
Reflectance spectra can be interpreted as a multivariate phenotype, where reflectance values at each discrete wavelength are a variable. Therefore, dewlap color can be represented in a multidimensional color space. To reduce the dimensionality of the spectral data, we binned reflectance values into 10-nm bins using the procspec function inpavo (Maia et al., 2013). Each of the three positions on the dewlap where we took spectral readings was included as a separate variable and repeated measurements at each position were averaged. We used the base R function prcomp to conduct a principal component analysis (PCA) on 123 variables representing the reflectance spectra.
We conducted linear mixed effect models using lme4 , lmerand lmerTest packages in R (Bates et al., 2015; Kuznetsova et al., 2017). For these models, we assigned principal component (PC) axes 1 or 2, which includes all colorimetric variables across the spectral range, as the response variables. Further, percent Western Cuba ancestry (see ‘Population structure and genetic diversity’ section below) was included as a fixed factor along with the covariates annual mean temperature, annual mean precipitation, and canopy openness. We also included site as a random effect to account for variation among populations not related to our main hypotheses. To further investigate dewlap variation, we used models with the same covariates, as well as fixed and random effects as previously described to evaluate individual variables describing aspects of the dewlap: UV reflectance, total brightness, and hue across the three dewlap positions; color composition of red, orange, and yellow; and dewlap size (i.e., area and perimeter). We log-transformed data to improve normality when appropriate.
We performed a generalized linear model, specifically a binomial logistic regression, to identify whether any variables predict dewlap pattern (i.e., solid or spotted) using the base R function glm . The predictor variables were Western Cuba ancestry, canopy openness, annual mean temperature, and annual mean precipitation. All statistical analyses were performed in R.