Skip to main content
Dryad logo

Strength and direction of sexual direction and sex roles vary between social groups in a coral reef cardinalfish


Rueger, Theresa (2022), Strength and direction of sexual direction and sex roles vary between social groups in a coral reef cardinalfish, Dryad, Dataset,


The strength and direction of sexual selection can vary among geographically distinct populations, and within populations across time. However, spatial and temporal variability at the level of the social unit is rarely explored. Here we investigate sexual selection and sex roles in the paternally mouthbrooding and site-attached pajama cardinalfish, Sphaeramia nematoptera, where social groups can vary in size and adult sex ratio. We found that reproductive success scaled with mating success for both sexes, consistent with positive sexual selection at population level. However, within social groups, we show that adult sex-ratio and group size can influence the strength and direction of sexual selection. Our results show the Bateman gradient is steeper for females in groups with male-biased adult sex ratios and sex roles are reversed, but steeper for males in female-biased groups, and equally steep when the sex ratio is even. In medium sized groups, reproductive skew was highest for both sexes and males had a steeper Bateman gradient than females, whereas in small and large groups the gradients were equal. We conclude that the strength and direction of sexual selection and sex roles can be masked by social dynamics in group-living species when considering only population and demographic processes.


Study system and tagging 

This study was conducted over 9 months, spanning two years, over five different periods; October - November 2012, February - March 2013, July - August 2013, March - April 2014 and September 2014, in Kimbe Bay, Papua New Guinea(5°30’S, 150°05’E). To reflect approximately the same fieldwork timespan data were grouped by year. Social units or groups of the pajama cardinalfish, Sphaeramia nematoptera, were defined as occupying the same distinct patch of the stony coral Porites cylindrica at a minimum distance of 2m from another group (Fig. 1a). A total of 379 individuals from 18 groups at 5-17 m depth on five reefs were included in the study (see map in Rueger et al. 2019). All fish were caught using handnets and diluted clove oil solution (Munday and Wilson, 1997), and individually marked using Visible Implant Elastomer (VIE) tags (Northwest Marine Technology). For each individual, we recorded a unique identifier, their life-stage and sex (see Group size and structure), behaviour (see Behavioural observations), collected fin clips (see Measuring mating and reproductive success) and morphological measures (see Sexual dimorphism). 

Group size and structure: Spatial and temporal variation

The number of individual fish in 18 spatially different groups were counted and adult and juvenile status were determined based on standard length (Rueger et al. 2016b). Maturity was determined according to standard length (Rueger et al. 2016b). Sex was determined by observing the distended buccal cavity during brooding (male) and bulging abdomen shortly before brooding (female) as well as pairing behaviour (Rueger et al. 2016b, 2018). Sex change is not known to occur in cardinalfish. A total of 168 individuals in 18 groups were identified as adults based on standard length with the remaining 211 being juveniles or subadults. Detailed demographics, including adult sex ratio and adult group size (number of adults per group), were gathered for 18 groups (Fig. 1b & c). For 10 groups three years of observations were available, for four groups two years of observations were available and for four groups only one year of observations was available. Reproduction was observed for 121 adult individuals in 16 groups; in one group reproduction was observed in all three years, in nine groups reproduction was observed in two years and in six groups reproduction was observed in only one year. To determine whether adult sex ratio and group size varied significantly across years and within groups, we conducted a linear mixed model (LMM) analysis using the lme4 package (Bates et al. 2015). We used adult sex ratio and group size as response variables in two separate models, year and group ID and their interaction as fixed factors and group ID as random intercept. Significance tests for LMMs were performed by likelihood ratio tests of the full model with the effect in question tested against the model without the effect. No obvious deviations from homoscedasticity were detected by visually inspecting the residual plots. No outliers or high variance inflation factors (VIF) were detected in any of the best-fit models, using performance (Luedecke et al., 2020). Conditional and marginal R2 were calculated using Nakagawa’s R2 in performance. All statistical analyses in this study were done in R version 4.0.3 (R Core team, 2020).

Figure 1. a) Photo of a group of Sphaeramia nematoptera in Porites cylindrica in Kimbe Bay, Papua New Guinea (credit: TR). Frequency of b) mean adult sex ratio and c) mean group size for groups of S. nematoptera (N = 18 groups). Dashed green lines indicate categories used for analysis. d) Schematic of S. nematoptera, including location of the dorsal fin filament.

Measuring mating and reproductive success: Genetic parentage analysis 

Relative mating and reproductive success were measured by analyzing the parentage of embryos and matching them to known adult individuals in the population. A DNA sample was taken from each individual (N = 379) in the 18 groups by clipping their caudal fin using surgical scissors. The resulting fin-clips were stored in high grade 95% ethanol. Within the study periods, all broods were collected by catching brooding males (see Rueger et al. 2019 for detailed methods). Clutches were then subsampled for genetic analysis and individual embryos were stored in high grade 95% ethanol. To take into account the possibility of multiple mothers and fathers in each clutch, approx. 10 eggs were sampled from different parts of each egg mass, including several points on the surface and the center of the congealed egg mass. A total of 1056 embryos from 105 broods carried by 64 males were assayed. 

All individuals were genotyped at 23 microsatellite loci with a range of 3 to 34 alleles observed per locus. Four markers that showed high genotyping error (≥ 6%) were excluded from the analyses. The remaining 19 loci had an average genotyping error of 2.2% ± 0.4 SE. Parentage assignments were conducted with the software COLONY v2.0 (Jones & Wang 2010) to identify the most likely mother or mothers, and father or fathers, of a selection of eggs carried by male cardinalfish. We identified the number of genetic mates (mating success) and number of offspring (reproductive success) for each reproductive individual. Detailed methods of genotyping and parentage analysis as well as marker specific statistics can be found in Rueger et al. (2015) and Rueger et al. (2019). 

Bateman gradient 

We investigated the Bateman gradient by estimating the linear regression slope between mating success (number of genetic mates) and reproductive success (number of offspring assigned through parentage) (Lande and Arnold, 1983; Arnold and Wade, 1984). We compared the slopes between males and females collating all data for each individual for the five observational periods and using linear mixed model analysis (lme4 package, Bates et al. 2015). To explore the influence of group size and structure we calculated the mean number of adults for each group (Fig. 1b), and the mean adult sex ratio for each group (Fig. 1c) over all observational periods. We fit separate models for groups with female-biased (>1, n = 6), equal (1, n = 7) and male-biased (>1, n = 5) sex ratio and separate models for number of adults per group (group sizes were categorized into small (<5, n = 9), medium (5-10, n =7), and large (>10, n = 2). To account for different numbers of observations between individuals, we weighted the number of sampling periods that we recorded for each individual in the model. To account for non-independence of samples we included group ID as random intercept. Models were checked for fit and violations of assumptions as above.

Reproductive variance 

We quantified reproductive variance (variance in reproductive success as number of embryos assigned to each parent) for each sex per year of observation for the 16 groups in which reproduction was observed. We then used linear mixed effect models, to test for differences between males and females (fixed factor), using year as a random effect and weighting residuals by the number of reproductive success observations (number of clutches sampled) within a given year and sex. To explore the influence of group size and sex structure on reproductive variance, for each of the 16 groups for each of the three years where reproduction was observed (number of groups reproducing n2012= 6; n2013= 11; n2014= 13), we assigned a categorical variable representing group size (small: n2012 = 2, n2013= 5, n2014 = 4; medium: n2012 = 2, n2013= 3, n2014 = 8; large: n2012 = 2, n2013 = 3, n2014 = 1), and a category for adult sex ratio (female-biased (<1: n2012 = 1, n2013 = 4, n2014 = 3), equal (1: n2012 = 1, n2013 = 3, n2014 = 6), male-biased (>1: n2012 = 4, n2013 = 4, n2014 = 4)). We calculated reproductive variance for each category, sex and year and in separate models, we added number of adults and adult sex ratio as fixed factors, as well as their interaction with sex. In these models we kept year as random effect and weighted residuals by the number of observations as above. Models were checked for fit and violations of assumptions as above.

Reproductive skew 

To calculate skew in reproductive success (RS), we used the multinomial index implemented in the SkewCalc package (Ross et al. 2020). The multinomial index (M) is related to Nonacs’ binomial index B (Nonacs and Hager, 2011), and accounts for heterogeneity in the number of observational periods in which an individual was observed (Ross et al. 2020). We calculated M for males, females and the population as a whole, as well as for the different adult sex ratio and group size categories for each year (see Reproductive variance).

Sexual dimorphism 

Forty-seven adult S. nematoptera were caught and euthanized to extract their gonads and determine sex (see Rueger et al. 2018 for detailed methods). There were 20 females and 27 males in the sample. Their standard length (SL; fish length from the tip of the snout to the posterior end of the last vertebra excluding the length of the caudal (tail) fin) and the length of the dorsal filament (Fig. 1d) were measured to the nearest millimeter using calipers and wet weight (mass) was measured using a digital scale to the nearest 0.1g. 

We conducted a directed comparison between three morphological traits, SL, mass and dorsal fin filament, that are: 1) highly distinguishable in this species (dorsal fin filament length) (Fig. 1d), and 2) commonly sexually dimorphic among other species (body size). While dorsal fin filament length may simply be represented by a univariate measurement (mm), body size, in contrast, is better represented as a multivariate morphological trait (Freeman and Jackson 1990). Therefore, we first constructed a multivariate metric of body size by loading both SL (mm) and mass (g) into a principle component analysis (PCA) and extracting the first component from the PCA (the allometric size variable) for each individual (henceforth defined as ‘Body PC1’; explaining 97% of variance in SL and mass measurements). To aid in visual interpretation, PC1 values were normalized between 0 and 100. PCA was conducted in R using the function ‘prcomp’, and mass was not log transformed before loading into the PCA because both mass and dorsal filament scaled linearly (Linear Model: β = 2.96, t = 10.10, df = 45, p < 0.001, adjusted R2 = 0.687). Sexual dimorphism in body size was tested using a linear mixed-effects model with body size (Body PC1) as the Gaussian distributed response variable and sex (binomial) as the sole fixed effect predictor. 

Sexual dimorphism in dorsal filament was tested using a similar linear mixed-effects model, however, body size was replaced with dorsal filament (mm) as the response variable (Gaussian distributed). To account for an influence of body size on dorsal filament alone, and to test for differences in allometric scaling between body size and dorsal filament between sexes, we included sex (binomial), body size (numeric), and an interaction between sex and body size as fixed effect predictors. 

Behavioural observations

During each of the five observational periods, all individuals from 18 groups were located every two to three days via visual census on SCUBA. On each day we noted whether males were brooding, which individuals were in pairs (see Rueger et al. 2018 for details) and we recorded the subject and object of any aggressive behaviours (chases or bites) over 15-20 min. Overall, 500 hours of observational data on behaviours and social pair formation was collected. We compared the number of aggressive behaviours recorded per individual between males and females using a Fisher’s exact test. To determine whether adult sex ratio or the number of adults per group had an influence on the number of observed aggressions, we fitted a generalized linear mixed model (lme4 package, Bates et al. 2015) using a Poisson error distribution and fitting an observation level random effect term to account for overdispersion. 

Usage Notes

Datafiles for “Strength and direction of sexual direction and sex roles vary between social groups in a coral reef cardinalfish”.


Data from molecular parentage analysis on Sphaeramia nematoptera embryos matched to adults in the population.


Number of offspring and number of mates per year for Sphaeramia nematoptera in different social groups.


Number of aggressions directed at same sex and opposite sex individuals.


Size, weight and dorsal filament length data on a subset of the Sphaeramia nematoptera population.