DOI: 10.5061/dryad.2v6wwpzvv
title: Energy allocation explains how protozoan phenotypic traits change in response to temperature and resource supply

description: To survive and reproduce, living organisms need to maintain an efficient
 balance between energy intake and energy expenditure. Changes in
 environmental conditions can disrupt previously efficient energy
 allocation strategies, and organisms are required to change their
 behaviour, physiology, or morphology to cope with the new environment.
 However, how multiple phenotypic traits interact with one another and with
 environmental conditions to shape energy allocation remains poorly
 understood. To better understand this type of phenotype-environment
 interactions, we develop a predictive framework, grounded in energetic and
 biophysical principles that allows us to make predictions on how metabolic
 rate and movement speed should change in response to environmental
 temperature and resource supply, differentiating between short-term, acute
 exposure to novel conditions and longer-term exposure that allows
 acclimation or adaptation. We tested these predictions by exposing axenic
 populations of the ciliate Tetrahymena pyriformis to different
 combinations of temperature and resource availability. We measured
 population growth, cell size, respiration, and movement. Acute increases
 in temperature led to higher movement speeds and respiration rates,
 consistent with expectations from physical scaling relationships such as
 the Boltzmann–Arrhenius equation and the viscous drag acting on movement.
 However, by around 3.5 days after the introduction of Tetrahymena into a
 novel environment, all measured traits shifted toward values closer to
 those of the original environment. These changes likely reflect phenotypic
 acclimation responses that restored a more efficient energy allocation
 under the new conditions. Changes in cell size played a key role in this
 process by simultaneously affecting multiple phenotypic traits, including
 metabolic rate and the energetic costs of movement. In small microbial
 consumers like Tetrahymena, body size can change rapidly, relative to
 ecological and seasonal timescales. Changes in body size can therefore be
 effectively leveraged - alongside physiological and biochemical
 regulations -- to cope with environmental changes.
description: <strong>Cell cultures</strong>
 Axenic cultures of <em>Tetrahymena pyriformis</em>
 strain 1630/1W were obtained from CCAP (www.ccap.ac.uk) and cultured at 20
 degrees Celsius in a Proteose peptone - yeast extract medium 20 g Proteose
 peptone + 2.5 g yeast extract in 1L deionized water. Cells were maintained
 in the exponential growth phase at 20°C and 100% medium concentration for
 about 50 days (constant temperature, no light) in two replicates.
 Subsequently, cultures were split across 9 different treatments (3
 temperature conditions x 3 medium concentrations) and adapted to the new
 conditions for at least three weeks (corresponding to a minimum of 20
 generations), in four replicates for each condition.
 Throughout the entire duration of the adaptation period, cultures
 were kept in relatively constant growing conditions by adopting a serial
 transfer regime, subculturing repeatedly into fresh growth medium. At the
 end of the adaptation period, cultures were further split across a wide
 range of temperature conditions (keeping the same medium concentration at
 which they were adapted) to characterise thermal response curves for
 different biological quantities (respiration, movement speed, and
 population growth rate). Specifically, we measured acute thermal responses
 for respiration and movement speed (from 1.5 to 3 minutes after cells were
 moved to the new temperature for speed recordings, and from approximately
 30 minutes to three hours for respiration), and we measured long-term
 responses over a few days (2 to 6 generations, or 3.5 days on average,
 with differences depending on incubation temperature) for population
 growth, long-term movement speed, and cell volume changes.
 <strong>Population growth</strong><br>Assuming
 exponential growth throughout the experiment, the growth rate, expressed
 in the number of generations per day was calculated as
 log<sub>2</sub>(N(t) / N(0))/d where N(0) is the density at
 the beginning of a subculture, N(t) is the final density of the
 subculture, and d is the length of the subculture period in number of
 days.
 <strong>Respiration</strong><br>Oxygen
 consumption was measured using a 24-channel PreSens Sensor Dish Reader and
 2ml oxygen sensor vials from PreSens https://www.presens.de/ inside
 thermal cabinets at the desired temperature. Population-level respiration
 rate was then converted to the rate of energy consumption per individual
 cell by accounting for population density in the vial and assuming an
 equivalence of 1mol O<sub>2</sub> = 478576 J.
 <strong>Imaging</strong><br><em>Tetrahymena</em> cultures were imaged under the microscope in cell-counting slides (BVS100 FastRead), which provide a constant depth of 100 um. A microscope camera (Lumenera Infinity 3-3UR https://www.lumenera.com/infinity3-3ur.html was used to record videos at 30 fps. The temperature while imaging under the microscope stage was controlled using a temperature-controlled stage (Linkam PE120 Peltier System). <strong>Video tracking</strong><br>We used custom-made software (available at https://github.com/pernafrost/Tetrahymena written in Python and based on the opencv, traktor, and scikit-image libraries to extract trajectories and measurements of cell size and morphology directly from the videos. The software returns measurements for each `tracked particle', where a particle generally corresponds to one individual cell. However, there isn't a perfect one-to-one correspondence between \textit{Tetrahymena} cells and particles: a cell moving in and out of the field of view of the microscope camera would be labelled as a different particle, and occasionally the identity of two cells swimming close to each other and overlapping in the images were swapped. Given the very large number of individual measurements both across and within experimental conditions, we ignored this small intrinsic potential for pseudo-replication in our analyses. <strong>Movement analysis</strong><br>The instantaneous movement speed of each tracked particle was measured from the trajectories as the displacement per unit time of the centre of mass of the particle, measured over a time scale of 1/10 of a second (3 frames). We took the median of all the instantaneous speed values along the trajectory as the individual speed of the particle. We excluded from the analysis particles that did not move and cells with an unnaturally small size that might have been incorrectly detected in the image. Unless otherwise specified, in the analyses and the figures presented here we focus on the top 20% faster-moving cells within each tested experimental condition. This is because fastest moving cells are more likely to be representative of the intrinsic limits of <em>Tetrahymena</em> swimming, while slowly moving cells might be stuck temporarily against the microscope slide or they might be moving at slow speed for reasons independent of their ability to move faster. <strong>Estimation of cell volume</strong><br>The video-tracking software fits an ellipse around each segmented <em>Tetrahymena</em> cell. Cell volume V was estimated based on the major and minor axes of the best fitting ellipse (respectively l and w) using the formula  V = 4/3 pi l w^2 / 8.
description: # Energy allocation explains how protozoan phenotypic traits change in
 response to temperature and resource supply
 [https://doi.org/10.5061/dryad.2v6wwpzvv](https://doi.org/10.5061/dryad.2v6wwpzvv) Please refer to the original manuscript for details of methods. The code provided is meant to directly read the CSV data files with column names and other information as provided.  ## Description of the data and file structure File: Tetrahymena-revised.zip Video tracking and analysis of the movement of *Tetrahymena pyriformis* This repository contains the code (mostly R) associated with the manuscript [https://doi.org/10.1101/2023.07.25.550219](https://doi.org/10.1101/2023.07.25.550219) The data are also in the repository. The **video_tracking folder** contains the Python scripts used for tracking *Tetrahymena* cells from videos recorded under the microscope. If the scripts are used on different videos, it might be necessary to change file paths and also some parameters, such as the frame rate, and the scale for converting video pixels to units of length or volume (which depend on the resolution of the microscope). There is a readme file inside the folder. The output of the video tracking is files with information about each "particle" over different frames. The header line and first data line of one such file are shown below as an example of the file structure: "fileName", "particle", "medianFrame", "medianArea", "medianSpeed", "trajectoryLength", "autocorrelationTime", "autocorrelationTimeFrame", "autocorrelationTimeFrame2", "autocorrelationValue", "meanAbsAngle", "minSpeed", "maxSpeed", "percentile75Speed", "percentile25Speed", "meanSpeed", "meanArea", "minArea", "maxArea", "percentile75Area", "percentile25Area", "minAEllipse", "maxAEllipse", "meanAEllipse", "medianAEllipse", "minBEllipse", "maxBEllipse", "meanBEllipse", "medianBEllipse", "medianElongation", "nFrames", "meanNParticlesPerFrame", "meanDensity" "./initial_speed_responses_2021_02_22/a_20_100_1_tested_10C_diluted10cells_ml_rep1_trajectories.csv", 0, 112.5, 592.732103692195, 345.050153900855, 224, 0.4, 12, 11.5, 0.996707680921053, 0.171420467710599, 265.154203612464, 408.394527122387, 358.185695053792, 326.71562169791, 343.508876580095, 586.683816919826, 341.269999095506, 769.781952847007, 631.221201334545, 549.111126364198, 17.6834410893635, 26.1038036987876, 21.1476598685729, 21.0407123799652, 25.6575267458534, 58.5347725221707, 41.1238528489312, 40.9340172641884, 1.94505349660619, 849, 1.26383981154299, 1160.71296255088 It is possible to get information about how each measurement is obtained by looking into the code in the video tracking folder itself, but essentially in all files produced by the vide tracking there are columns that identify the object being tracked ("filename", "particle", "trajectoryLength"), columns that describe the characteristics of the culture or of the trajectory ("meanNParticlesPerFrame", "trajectoryLength"), columns that describe the shape of the tracked object ("medianArea", "maxArea", "meanAEllipse", "meanBEllipse", "medianElongation", etc.) and columns that describe the movement ("medianSpeed", "autocorrelationTime", "meanAbsAngle"). Information about the experimental conditions are typically contained in the first column ("fileName") as they were part of the filename given to the video, for example "initial_speed_responses" indicates the type of measurement (in this case an acute response to temperature), 2021_02_22 is the experiment date, a_20_100_1 indicates the adaptation conditions: 20°C, 100% growth medium, culture line 1. "tested10C" indicates the temperature at which the movement was recorded (in this case 10°C), diluted indicates that the culture was diluted to a lower cell density in order to better resolve individual cells, rep1 is the number of a (possibly repeated) measurement of the same culture under the microscope. Unless specified otherwise, the units of length are micrometres, and the units of time are seconds. ### The main data files (all with extension .csv) are: 1\) **/acute_speed_response/track_analysis_individual_particles.csv** a file with speed measurements of particles measured in an acute response to various temperature conditions. 2\) **/longer_term_speed_response/track_analysis_individual_particles.csv** same as above, but for longer term exposure to the new temperature condition 3\) **/Metabolic_rate_respiration/post_data/** various files with respiration data measured in the Sensor Dish reader at different temperature conditions. Files having the extension .xls are time series of oxygen, while csv files contain information about the start and end of the recording The file **/Metabolic_rate_respiration/summary_MR_post_adaptation.csv** contains measurements of respiration in the following form: "intercept","slope","r2","p.val","code","temperature","concentration","treatment","replicate","density","rate.per.cell","rate.per.cell.nW" -175.265777137724,-1.43794034568846,0.998278013581225,0,"100_15_A_8000",12.5,100,"15","A",8000,-1.79742543211058e-07,1.43367545456594 Where the most relevant columns are those that define the experiment ("temperature", "concentration", "treatment", and "replicate") and the measured rates of respiration ("rate.per.cell" and "rate.per.cell.nW"). Details of how the measurements are obtained can be found by looking into the code There are also other data files: 4\) **/population_growth_during_adaptation/growth_data_during_adaptation.csv** which contains the measurements of population density at each count and for each culture. The exact culture condition can be found in the "name" column (e.g., 20_100_1 means the culture kept at 20 degrees, 100% growth medium, replica 1). 5\) **/preliminary_data_nutrients_and_population_growth/data_growth_Rate_vs_medium_concentration.csv** in which cells were moved directly from 100% growth medium and 20 degrees to a range of conditions (with different growth medium concentrations and different temperatures) and their growth rate was measured (column "Growth_rate") 6\) **/preliminary_data_oxygen_concentration/data_cell_volume_vs_oxygen.csv** where there are measurements of cell volume for cells kept at different oxygen concentrations 7\) **/speed_over_time_preliminary_experiment/track_analysis_results_individual_particles_preliminary_experiment_long_tracking.csv** with measurements of acute speed responses from preliminary experiments and over a relatively long period of time (20 minutes) ## Code/Software The R code in each folder is meant to run on the data file in the same folder (or sometimes on data from different folders, but when this happens, the paths indicate clearly which files are read by each script) and then each script produces a number of figures or processed additional datasets (e.g., tables), which are saved to disk. These figures include both the figures included in the scientific manuscript and the associated supplementary information, and a large number of additional figures. Before running each script, it is recommended that all the file paths inside the script are double-checked and that the relevant libraries are installed. The full source code is also available on GitHub (link in Related Works), where it is also possible to track changes to the code. The data and code uploaded here are a snapshot of the GitHub repository taken on the 7th March 2024.