README ====== Dataset title: Pre-registration: Effects of school start times on adolescent sleep in Stockholm high schools Recommended Citation: Lemke, T., & Hadlaczky, G. (2026). Pre-registration: Effects of school start times on adolescent sleep in Stockholm high schools (Version 1) [Data set]. Karolinska Institutet. See the Swedish National Data Service catalogue entry, https://researchdata.se/en, for this dataset for complete metadata, contact information, and information about how to obtain the dataset. Responsible organization: Karolinska Institutet Description: This dataset is connected to a longitudinal observational study examining the association between school start times (SST) and sleep in upper secondary students in Stockholm, Sweden. Stockholm City has implemented delayed school start times (no earlier than 09:00) in selected classes across three upper secondary schools during the 2025/26 academic year. This created variation in start times across classes, enabling an observational evaluation of how SST affects adolescents' sleep. The study uses naturally occurring variation in school start times across the classes, those with delayed SST and a selection of classes that maintained their original schedules, treating SST as a continuous class-level exposure variable. Data were collected from n=527 upper secondary students (gymnasium, year 2) across 20 classes in three schools in Stockholm. Questionnaire data were collected at four time points: at the start of the school term (baseline), and at 1, 3, and 6 months follow-up. The primary outcome for this pre-registration is weekday sleep duration, measured via self-report using the Karolinska Sleep Questionnaire (KSQ). The exposure variable is the weekly average school start time per class, derived from class schedules, expressed in hours from midnight and centered at 08:00. The study uses a Bayesian multilevel modelling approach (three-level: measurement occasions nested within students nested within classes), implemented in R using the brms package. Missing data are handled via model-based imputation using the mi() function in brms. For the purpose of pre-registration, the files provided at this stage contain simulated data only. The simulated data mirror the structure, variables, formats, and expected distributions of the real data that will be analysed. The simulation is grounded in observed parameters from the class schedules (School start times.csv) and published estimates of sleep duration in Swedish adolescents (Lemke et al., 2023). License: The dataset is shared under a Creative Commons Attribution 4.0 (CC BY 4.0) licence, allowing reuse and adaptation with appropriate attribution. Access to the non-simulated dataset is restricted due to ethical and privacy requirements. Access restrictions: Access to real data will be possible after publication of analyses and subject to ethical and legal approval. Essential information for dataset reuse: The data files are provided as structured tabular files that can be read using standard statistical software. No proprietary software is required. The original analyses are planned to be conducted in R, although reuse is not restricted to any specific software environment. Analysis scripts and documentation are expected to be made available after publication of primary results. Dataset organization: Not applicable. Datafile descriptions: 1) Preregistered hypotheses.pdf: Document outlining the pre-registered hypotheses. 2) Generative model_preregistration.R: R script documenting the development of the model specifying the data-generating process used to simulate the dataset, including all parameter values and their justifications. The script also contains the prior specification, prior predictive checks, and planned model fitting and posterior predictive checks using the simulated data. Three models of increasing complexity are specified: Model 1 includes mean SST only; Model 2 adds within-week variability in SST (SD of daily start times across the week); Model 3 additionally adjusts for gender. Model 3 is the model that will be used for the analysis of the observed data. The following folder structure is required to run Generative model_preregistration.R The script locates files relative to its own position (via box::file()), not the working directory. It must be placed exactly two folder levels below the project root, with the following structure: Project root/ ├── 5) Data/ │ └── School start times.csv └── 6) Analysis/ └── Generative model/ └── [this script].R Input: 5) Data/School start times.csv (semicolon-delimited) Output: simulated data, prior/posterior samples, and fitted model objects (.rds/.csv) are saved to 6) Analysis/Generative model/. The relevant saveRDS()/write.csv() lines are currently commented out in the script; uncomment them to reproduce saved output. Dependencies: box, dplyr, tidyr, ggplot2, brms, lme4, bayesplot Folder names and the two-level nesting must be preserved exactly, or the path-finding will fail silently. 3) simulated_data.csv: Simulated longitudinal dataset containing one row per student per measurement occasion. Includes student ID, class ID, school, occasion (survey time), class-level SST (weekly average and within-week SD, in hours), gender, and observed weekday sleep duration (in hours, with simulated missingness). The simulated sleep duration values are generated using the data-generating process described in the generative model script, with parameters grounded in published Swedish adolescent sleep data (Lemke et al., 2023) and data on the effects of school start times on sleep (Yip et al., 2022). 4) School start times.csv: Schedule with school start times for the participating classes. Relevant references: Lemke, T., Hökby, S., Wasserman, D., Carli, V., & Hadlaczky, G. (2023). Associations between sleep habits, quality, chronotype and depression in a large cross-sectional sample of Swedish adolescents. Plos one, 18(11), e0293580. Yip, T., Wang, Y., Xie, M., Ip, P. S., Fowle, J., & Buckhalt, J. (2022). School start times, sleep, and youth outcomes: a meta-analysis. Pediatrics, 149(6), e2021054068. Abbreviations: SST = School Start Time Further description of variable names in simulated_data.csv: student_id Unique student identifier (integer) class_id Unique class identifier (integer, 1-20) school School identifier (character: School 1, School 2, School 3) occasion Measurement occasion (integer: 1=baseline, 2=1 month, 3=3 months, 4=6 months) sst_week Weekly average school start time for the class (hours from midnight) sst_week_centered Weekly average SST centered at 08:00 (sst_week - 8) sst_sd Within-week SD of school start times for the class (hours) gender Student gender (integer: 0=boy, 1=girl) v_class Class random intercept u_student Student random intercept mu True linear predictor (weekday sleep in hours) sleep_raw Weekday sleep duration with occasion-level noise (hours) sleep Observed weekday sleep duration with missingness missing Indicates missingness for sleep variable Further description of variable names in School start times.csv: Class Class identifier School School identifier Schedule_number Some classes schedules changed during the academic year. Each class has information on SST from two schedule periods, the period indicated by this variable. Group Indicates if a class implemented delayed SST (Group = 1) or maintained their schedules (Group = 2) Schedule_valid_from Start date of the schedule period. Schedule_valid_to End date of the schedule period. Monday to Friday Indicates the classes SST for each weekday in minutes from midnight. Version control: This dataset does not contain files under version control. Source code information: Statistical analyses will be conducted in R. The script for the generative model is included in this release and documents the data simulation, prior specification, prior predictive checks, model fitting, and posterior predictive checks using the simulated data. The script with the generative model will also be used for the analysis of the final dataset. Any changes in the script or modelling will be documented and released alongside the final dataset. Data Quality: The sleep duration data are based on self-report questionnaires. School start time data are derived from classes' schedules provided by school administrations. Missing data arise from non-response to follow-up questionnaires and are handled via model-based imputation.