DOI: 10.5061/dryad.k3j9kd5fv
title: Data from: Effects of past mating behavior versus past ejaculation on male mate choice and male attractiveness

description: Past reproductive effort allows males to assess their ability to acquire
 mates, but it also consumes resources that can reduce their future
 competitive ability. Few studies have examined how a male’s reproductive
 history affects his subsequent mate choice; and, to date, no study has
 determined the relative contribution of past mating behavior and past
 ejaculate production because these two forms of investment are naturally
 highly correlated. Here, we disentangled the relative effects of past
 mating behavior and past ejaculate production in male mosquitofish
 (Gambusia holbrooki) by experimentally preventing some males from
 ejaculating when trying to mate. We assessed the effect of mating behavior
 on mate choice by comparing males that had previously been with or without
 access to females and male rivals for 16 weeks; and assessed the effect of
 ejaculation on mate choice by comparing males that either could or could
 not ejaculate when they had access to females for 16 weeks. We compared
 (1) time females spent with each male, (2) total distance males swam, (3)
 total time males spent inspecting females, (4) proportion of time males
 spent with the solitary females in separate models, with age (week 8, week
 16) and treatment of reproductive history ("naive male",
 "mating only male" and "mating and ejaculation males")
 as fixed factors.  We showed that reproductive history did not
 affect male attractiveness, but it did affect male mate choice. Somewhat
 surprisingly, in two-choice trials males from all three treatments
 preferred females in the vicinity of a rival over solitary females. This
 preference was marginally stronger for males engaging in previous mating
 behavior but was unaffected by past ejaculate production. This is the
 first study to quantify the relative influence of pre- and post-copulatory
 reproductive investment on male mate choice.
description: # Effects of past mating behavior versus past ejaculation on male mate
 choice and male attractiveness
 ## Description of the data
 and file structure The analysis can be re-run using the R code called
 "Chung et al. mosquitofish mate choice". For each response
 variable (time females spent with each male; total distance males swam;
 total time males spent inspecting females; proportion of time males spent
 with the solitary female), we used mixed models including male ID as a
 random factor, to account for repeated measurements of the same male. We
 included reproductive treatment (“naïve”, “mating only”, “mating and
 ejaculation”), treatment duration (8 weeks, 16 weeks) and their
 interaction in initial models. A non-significant interaction was removed
 from the final model to interpret the main effects. Removing
 non-significant interactions did not significantly alter the model fit, as
 determined by log-likelihood ratio tests. Full model outputs (for both
 initial and final models) are provided in the supplementary material. Wald
 chi-square tests were performed to calculate the *P* value using the
 *Anova* function in the *car* package (R studio v1.3.1093 with R v4.0.5).
 We used type III sums of squares for models with the interaction term and
 type II sums of squares for models without the interaction. Results are
 presented as mean ± SE. The significance level is set at alpha = 0.05 (two
 tailed). We ran Tukey’s post hoc pairwise tests (*emmeans* package) if the
 treatment effect was significant. Any deviations from this approach are
 specified below. (i)             Male attractiveness We employed a
 two-step analysis to investigate male attractiveness. First, we tested
 whether females preferred to spend time with males rather than alone by
 comparing the proportion of time spent near the empty compartment to that
 expected by chance (= 0.25) using separate one sample *t*-tests for trials
 at weeks 8 and 16. The proportion of time was power-transformed to meet
 the assumption of normality (determined via Shapiro-Wilk tests). Second,
 we tested whether male reproductive history, treatment duration and their
 interaction affected how much time a female spent with a male using a
 generalized linear mixed model (GLMM). Quasi-Poisson error was employed to
 ensure that the data variance conformed to the model assumption, which was
 assessed using a dispersion test in the *DHARMa* package. The total time
 females spent in the association zone of each male was the response
 variable, with female ID as a random factor to account for three males
 being tested in the same trial. We analyzed the first step using the file
 called "relative_time_empty", which contains data on the time
 females spent within four association zones when tested with males at two
 different age groups: when males were young (Week8: W8) and old (Week 16:
 W16). The columns include "female_id", "male_age",
 "male1_time" (i.e., time spent with the first male)",
 "male2_time" (i.e., time spent with the second male),
 "male3_time" (i.e., time spent with the third male), and
 "empty_time" (i.e., time spent in the empty corner). Finally, we
 calculated the relative time females spent in the empty corner
 ("relative_time_empty") by dividing the "empty_time"
 by the sum of "male1_time", "male2_time",
 "male3_time", and "empty_time". The time was recorded
 in seconds. We analyzed the second step using the file called
 'male_attractiveness,' which contains data on the time females
 spent with each treatment male: namely, "Naive" (i.e., males
 without reproductive history), "Mating_only" (i.e., males that
 could mate but could not ejaculate), and
 "Mating_and_ejaculation" (i.e., males that could mate and
 ejaculate). In this file, each treatment male has an individual row (i.e.,
 "male_id") with their testing age (i.e., "age"),
 either Week 8 (W8) or Week 16 (W16). Each row also reveals which females
 chose them ("female_id") and the time females spent with them
 ("time" in seconds). Finally, we report whether or not the focal
 male was located in the middle corner ("in_middle_corner": yes
 or no), meaning the corner located between the other two corners that
 contained a focal male. (ii)           Male mate choice We ran linear
 mixed models (LMMs) to test the effects of male reproductive history,
 treatment duration and their interaction on male: (a) distance swum and
 (b) time spent inspecting females. We analyzed the proportion of time
 males spent with the solitary female compared to the other female using a
 GLMM (binomial error, cbind function of absolute time with each female),
 where trial ID was considered as a random effect to account for
 overdispersion. Pair ID was included as a random factor to account for
 repeated usage of a combination of stimulus fish (max 3 trials per
 combination; one per treatment). We further tested whether the proportion
 of time males of each type at 8 and 16 weeks respectively spent with a
 solitary female differed from the null expectation (= 50%). To do this, we
 ran six separate intercept-only GLM models (quasi-binomial error, cbind
 function of absolute time with each female). An intercept of 0 corresponds
 to males spending 50% of the time with each female (ln(*p*/[1 − *p*]),
 where *p* = proportion of time with the solitary female). If the intercept
 is significantly greater than zero, this indicates that males spent
 significantly more time with the solitary female. The analysis was
 conducted using the file named "male_mate_choice". Each focal
 male has its individual row ("male_id") with the assigned
 "treatment" (Naive, Mating_only, Mating_and_ejaculation; see
 above for details) and "age" (Week 8 = W8; Week 16 = W16). Male
 information was all reported, including: w8_survival: Whether the male
 survived until Week 8 (1 means alive; 0 means died). This is only shown
 for males tested at Week 8 (i.e., age = W8). w16_survival: Whether the
 male survived until Week 16 (1 means alive; 0 means died). This is only
 shown for males tested at Week 16 (i.e., age = W16). pre_body_length: Male
 body size before treatment. For an age of Week 8, this means the size at
 Week 0. For an age of Week 16, this means the size at Week 8 (in
 millimeters). post_body_length: Male body size after treatment. For an age
 of Week 8, this means the size at Week 8. For an age of Week 16, this
 means the size at Week 16 (in millimeters). pre_gonopo_length: Male's
 gonopodium length (i.e., intromittent organ) before treatment. For an age
 of Week 8, this means the gonopodium size at Week 0. For an age of Week
 16, this means the gonopodium size at Week 8 (in millimeters).
 post_gonopo_length: Male's gonopodium length after treatment. For an
 age of Week 8, this means the gonopodium size at Week 8. For an age of
 Week 16, this means the gonopodium size at Week 16 (in millimeters).
 Total_distance_swum: The total distance males swam during the mate choice
 trial (in centimeters). Total_inspection_time: The total time males spent
 with both females (in seconds). Fish_pair_id: The identity for each
 combination of two females and a model male in each trial.
 time_with_female_with_rival: The time males spent with the female
 surrounded by another male (in seconds). time_with_solitary_female: The
 time males spent with the solitary female (in seconds).
 body_length_female_with_rival: The body length of the female surrounded by
 another male (in millimeters). body_length_solitary_female: The body
 length of the solitary female (in millimeters). body_length_rival: The
 body length of the model male (in millimeters). trial_id: The identity of
 each individual trial. Proportion_time: The relative time males spent with
 the solitary female (i.e., dividing "time_with_solitary_female"
 by the sum of "time_with_female_with_rival" and
 "time_with_solitary_female"). Note: "na" indicates
 non-available data (i.e., the fish died before measurement). Finally, we
 have updated a raw data file that includes the overall data for both (i)
 male attractiveness and (ii) male mate choice (note: "na" means
 missing values where the fish had died before measurement). ##
 Sharing/Access information Our experimental and analysis plans were
 registered online before data collection
 ([osf.io/swdv7](https://osf.io/swdv7)).