Script and data for: Rezende et al (2020) Predicting temperature mortality and selection in natural Drosophila populations. Science, Accepted. Contains 24 files: (1) Thermal landscape functions.R - R script with functions described in Rezende et al (2020) (see Supp Mat, Implementation of the Model) (2) Analyses - R scripts to replicates analyses in the paper and Suppl Mat (5 files total): Analyses_1984_1991 - Thermal mortality based on temperature records for 1984 - 1991 (Figs 3 and S5). Analyses_2014_2018 - Thermal mortality based on temperature records for 2014 - 2018 (Figs 3 and S5). Analyses_Castaneda - Analyses of dataset by Castaneda et al 2015 (Figs S1 and S2). Analyses_Jorgensen - Analyses of static and dynamic assays by Jorgensen et al 2019 (Fig 2, Figs S3 and S4, 11 panels each). Analyses_Worked_examples - Worked examples 1 and 2 in Suppl Mat (3) Datasets (5 files total): Dataset_Brncic - Daily abundance of Drosophila subobscura measured on a monthly basis from 1984 - 1991 (source Benado & Brncic 1994). Columns:year month n - Total abundance (# individuals) Dataset_Castaneda - Lethal times measured in Drosophila subobscura at different constant temperatures (source Castaneda et al 2015). Columns:treat - acclimation temperature (cold = 13 C, warm = 18 C) ta - measurement temperature pop - population (S = Santiago, CU = Curico, CH = Chillan, PM = Puerto Montt, V = Valdivia) sex - males (m) and females (f) time - lethal times (min expressed in decimals) Dataset_Jorgensen_static - Lethal times for 11 Drosophila species at different constant temperatures (source Jorgensen et al 2019a,b DRYAD). Dataset_Jorgensen_dynamic - Lethal times for 11 Drosophila species during ramping experiments at three different warming rates (source Jorgensen et al 2019a,b DRYAD). Dataset_Mortality_1984_1991 - Thermal mortality based on temperatures records for 1984 - 1991 (output of Analyses_1984_1991.R employed in output of Analyses_2014_2018.R). (4) Air temperature data for Santiago, Chile, with 1 h resolution for 13 years. Files Temp*.csv for 1984 - 1991 and 2014 - 2018 (13 files total). References: 1. Benado M, Brncic D. 1994. An eight year phenological study of a local drosophilid community in Central Chile. J Zool Syst Evol Res 32: 51-63. 2. Casta–eda LE, Rezende EL, Santos, M. 2015. Heat tolerance in D. subobscura along a latitudinal gradient: contrasting patterns between plastic and genetic responses. Evolution 69:2721-2734. 3. J¿rgensen, LB, Malte, H, Overgaard, J. 2019a. How to assess Drosophila heat tolerance: Unifying static and dynamic tolerance assays to predict heat distribution limits. Funct Ecol. 33: 629Ð 642. https://doi.org/10.1111/1365-2435.13279 4. J¿rgensen, LB, Malte, H, Overgaard, J. 2019b. Data from: How to assess Drosophila heat tolerance: unifying static and dynamic tolerance assays to predict heat distribution limits, Dryad, Dataset, https://doi.org/10.5061/dryad.840j728