Skip to main content

Density-by-diet interactions during larval development shape adult life-history trait expression and fitness in a polyphagous fly

Cite this dataset

Morimoto, Juliano (2021). Density-by-diet interactions during larval development shape adult life-history trait expression and fitness in a polyphagous fly [Dataset]. Dryad.


Habitat quality early in life determines individual fitness, with possible long-term evolutionary effects on groups and populations. In holometabolous insects, larval ecology plays a major role in determining the expression of traits in adulthood, but how ecological conditions during larval stage interact to shape adult life-history and fitness, particularly in non-model organisms, remains subject to scrutiny. Consequently, our knowledge of the interactive effects of ecological factors on insect development is limited. Here, using the polyphagous fly Bactrocera tryoni, we conducted a fully-factorial design where we manipulated larval density and larval diet (protein-rich, standard, and sugar-rich) to gain insights into how these ecological factors interact to modulate adult fitness. As expected, a protein-rich diet resulted in faster larval development, heavier and leaner adults that were more fecund compared with standard and sugar-rich diets, irrespective of larval density. Females from the protein-rich larval diet had overall higher reproductive rate (i.e., eggs per day) than females from other diets, and reproductive rate decreased linearly with density for females from the protein-rich but non-linearly for females from the standard and sugar-rich diets over time. Surprisingly, adult lipid reserve increased with larval density for adults from the sugar-rich diet (as opposed to decreasing, as in other diets), possibly due to a stress-response to an extremely adverse condition during development (i.e., high intraspecific competition and poor nutrition). Together, our results provide insights into how ecological factors early in life interact and shape the fate of individuals through life-stages in holometabolous insects.


The data has been collected at the controlled temperature rooms at Macquarie University in 2019. The data was collected by behavioural and physiological protocols detailed in the manuscript. Analysis were conducted in R, and the script to replicate the analysis is attached along with the raw data.

Usage notes

File names

Ahn_density_emergence rate_2019.csv: Data for adult emergence

Ahn_density_fecundity_2019.csv: Data for the measures of fecundity

Ahn_density_lipid_2019.csv: Data for the measures of lipid content and body composition

Ahn_density_pupalweight_2019.csv: Data for the measures of pupal weight

Anh_density_DeveTime_2019.csv: Data for the measures of developmental time



Replicate: Replicate number

Volume/egg_vol: Egg volume used to create different densities

Density: Factor with 5 levels, corresponding to the 5 densities used in each diet

Diet: Factor with 3 levels, corresponding to the 3 diets used in the experiment

Id: For cases where repeated measures of same population was performed (e.g., several individuals from the same replicate), we used ‘id’ to identify the measures. 

Day: days of data collection (for temporal patterns, e.g., offspring production per day).

Sex: sex of the individual

N_total: total number of pupae

Num_male / num_female: number of each sex emerging from the pupae (for the pupal experiment) and the number of adult individuals in the population (for the fecundity experiment)

Num_emerg: total number of emergence

Female_male: sex ratio, female divided by male

Num_eggs: number of eggs produced by a population

Eggs_per_female: standardized number of eggs by the number of the females present in the population

Wt0 and wt1: dried weight before and after lipid extraction

Lipidwt: difference between wt0 and wt1

Prop_lipid: proportion of lipid relative to initial body weight (i.e., lipidwt / wt0)

Pupal_weight: weight of the pupae

First_jump, las_jump, interval_jump: the time until the first and last larvae jump to pupation, and the difference in time between these two events.

First_emerg: first adult emergence from pupae

Dev_time: developmental time in days accounting for the interval between first and last larval jumps.