Sleep spindles are linked to white matter connectivity differentially in older adults with and without cognitive impairment.
The 2 matches
- [1] § Materials and methods › Participants ↔ DWI_EEG_osf.Rmd, lines 157–199 · score 0.74 · cholinesterase inhibitors, mood stabilizers, PSG, hypnotics, sedatives, MMSE
- [2] § Materials and methods › Overnight polysomnography ↔ DWI_EEG_osf.Rmd, lines 157–199 · score 0.58 · sleep onset, sleep efficiency, scoring, wake, events, architecture
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
R Markdown · 1,196 lines · 47 KB · no license · 2 matches
- ---
- title: "Sleep microarchitecture and DWI"
- author: "Aaron Lam"
- date: "01/11/2024"
- output: word_document
- ---
- ```{r setup, include=FALSE}
- knitr::opts_chunk$set(echo = TRUE)
- library(haven)
- library(dplyr)
- library(tidyr)
- library(ggplot2)
- library(interactions)
- library(effectsize)
- library(rsq)
- library(readxl)
- library(lubridate)
- ```
- ## R Markdown
- This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see <http://rmarkdown.rstudio.com>.
- When you click the **Knit** button a document will be generated that includes both content as well as the output of any embedded R code chunks within the document. You can embed an R code chunk like this:
- ```{r load-data, include = FALSE}
- df <- read.csv("/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Data/Shawn_DWI_EEG dataset.csv")
- sleep_df <- read_sav("/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Data/HBA_Sleep Satellite_Master Data File_20231222_AL.sav")
- redcap_df <- read.csv("/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Data/NEWDiscoveringNovelB_DATA_2026-02-28_0910.csv")
- morediagnoses_df <- read.csv("/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Data/ABC_ID_and_clinical_diagnosis.csv")
- ```
- ```{r data cleaning, include = FALSE}
- # Define timepoints, derivations, and metrics
- timepoints <- c("BL", "LTFU1", "LTFU2")
- derivations <- c("C3", "C4", "Cz", "F3", "F4", "Fz")
- metrics <- c(
- "Absolute_NREM_Delta", "Absolute_NREM_Theta", "Absolute_NREM_Alpha",
- "Absolute_NREM_Sigma", "Absolute_NREM_Beta", "Absolute_NREM_0.25_to_1.0Hz",
- "Absolute_NREM_11.0_to_13.0Hz", "Absolute_NREM_13.0_to_15.0Hz",
- "NREM_Spl_pmin", "NREM_Spl_fast_pmin", "NREM_Spl_slow_pmin", "NREM_MeanMaxHeight"
- )
- # Create a list of column names by iterating over each combination
- sleep_columns <- c("ABC_ID") # Start with IDs for merging
- for (tp in timepoints) {
- for (deriv in derivations) {
- for (metric in metrics) {
- sleep_columns <- c(sleep_columns, paste(tp, deriv, metric, sep = "_"))
- }
- }
- }
- # Keep only Sleep Micro-columns
- sleep_df_filtered <- sleep_df %>%
- select(all_of(sleep_columns)) %>%
- as.data.frame()
- # Convert from wide to long format, extracting timepoint, derivation, and metric from column names
- sleep_data_long <- sleep_df_filtered %>%
- pivot_longer(
- -ABC_ID,
- names_to = c("Timepoint", ".value"),
- names_pattern = "(BL|LTFU1|LTFU2)_(.*)"
- )
- # Extract ABC_ID and Timepoint from XNAT_scan_id in df
- df <- df %>%
- mutate(
- ABC_ID = substr(XNAT_scan_id, 1, 8),
- Timepoint = sub(".*_(\\w+)$", "\\1", XNAT_scan_id)
- )
- merged_data <- df %>%
- left_join(sleep_data_long, by = c("ABC_ID" = "ABC_ID", "Timepoint" = "Timepoint"))
- # Calculate relative delta power for each region
- merged_data <- merged_data %>%
- mutate(
- F3_Relative_Delta = F3_Absolute_NREM_Delta / (
- F3_Absolute_NREM_Delta + F3_Absolute_NREM_Theta + F3_Absolute_NREM_Alpha +
- F3_Absolute_NREM_Sigma + F3_Absolute_NREM_Beta),
- F4_Relative_Delta = F4_Absolute_NREM_Delta / (
- F4_Absolute_NREM_Delta + F4_Absolute_NREM_Theta + F4_Absolute_NREM_Alpha +
- F4_Absolute_NREM_Sigma + F4_Absolute_NREM_Beta),
- Fz_Relative_Delta = Fz_Absolute_NREM_Delta / (
- Fz_Absolute_NREM_Delta + Fz_Absolute_NREM_Theta + Fz_Absolute_NREM_Alpha +
- Fz_Absolute_NREM_Sigma + Fz_Absolute_NREM_Beta),
- C3_Relative_Delta = C3_Absolute_NREM_Delta / (
- C3_Absolute_NREM_Delta + C3_Absolute_NREM_Theta + C3_Absolute_NREM_Alpha +
- C3_Absolute_NREM_Sigma + C3_Absolute_NREM_Beta),
- C4_Relative_Delta = C4_Absolute_NREM_Delta / (
- C4_Absolute_NREM_Delta + C4_Absolute_NREM_Theta + C4_Absolute_NREM_Alpha +
- C4_Absolute_NREM_Sigma + C4_Absolute_NREM_Beta),
- Cz_Relative_Delta = Cz_Absolute_NREM_Delta / (
- Cz_Absolute_NREM_Delta + Cz_Absolute_NREM_Theta + Cz_Absolute_NREM_Alpha +
- Cz_Absolute_NREM_Sigma + Cz_Absolute_NREM_Beta)
- )
- # Calculate frontal and central averages
- merged_data <- merged_data %>%
- mutate(
- Frontal_Avg_Relative_Delta = rowMeans(select(., F3_Relative_Delta, F4_Relative_Delta, Fz_Relative_Delta), na.rm = TRUE),
- Central_Avg_Relative_Delta = rowMeans(select(., C3_Relative_Delta, C4_Relative_Delta, Cz_Relative_Delta), na.rm = TRUE)
- )
- head(merged_data)
- # Average C3, C4, F3, C4
- merged_data$central_NREM_Spl_pmin <- rowMeans(merged_data[, c("C3_NREM_Spl_pmin", "C4_NREM_Spl_pmin",
- "Cz_NREM_Spl_pmin")],
- na.rm = TRUE)
- merged_data$frontal_NREM_Spl_pmin <- rowMeans(merged_data[, c("F3_NREM_Spl_pmin",
- "F4_NREM_Spl_pmin", "Fz_NREM_Spl_pmin")],
- na.rm = TRUE)
- merged_data$central_NREM_Spl_fast_pmin <- rowMeans(merged_data[, c("C3_NREM_Spl_fast_pmin", "C4_NREM_Spl_fast_pmin",
- "Cz_NREM_Spl_fast_pmin" )],
- na.rm = TRUE)
- merged_data$frontal_NREM_Spl_fast_pmin <- rowMeans(merged_data[, c( "F3_NREM_Spl_fast_pmin",
- "F4_NREM_Spl_fast_pmin", "Fz_NREM_Spl_fast_pmin")] ,
- na.rm = TRUE)
- merged_data$central_NREM_Spl_slow_pmin <- rowMeans(merged_data[, c("C3_NREM_Spl_slow_pmin", "C4_NREM_Spl_slow_pmin",
- "Cz_NREM_Spl_slow_pmin")],
- na.rm = TRUE)
- merged_data$frontal_NREM_Spl_slow_pmin <- rowMeans(merged_data[, c( "F3_NREM_Spl_slow_pmin",
- "F4_NREM_Spl_slow_pmin", "Fz_NREM_Spl_slow_pmin")],
- na.rm = TRUE)
- merged_data$central_NREM_MeanMaxHeight <- rowMeans(merged_data[, c( "C3_NREM_MeanMaxHeight",
- "C4_NREM_MeanMaxHeight", "Cz_NREM_MeanMaxHeight")],
- na.rm = TRUE)
- merged_data$frontal_NREM_MeanMaxHeight <- rowMeans(merged_data[, c( "F3_NREM_MeanMaxHeight",
- "F4_NREM_MeanMaxHeight", "Fz_NREM_MeanMaxHeight")],
- na.rm = TRUE)
- # SLOW OSCILLATIONS
- merged_data$central_Absolute_NREM_0.25_to_1.0Hz <- rowMeans(merged_data[, c("C3_Absolute_NREM_0.25_to_1.0Hz", "C4_Absolute_NREM_0.25_to_1.0Hz",
- "Cz_Absolute_NREM_0.25_to_1.0Hz")],
- na.rm = TRUE)
- merged_data$frontal_Absolute_NREM_0.25_to_1.0Hz <- rowMeans(merged_data[, c("F3_Absolute_NREM_0.25_to_1.0Hz",
- "F4_Absolute_NREM_0.25_to_1.0Hz", "Fz_Absolute_NREM_0.25_to_1.0Hz")],
- na.rm = TRUE)
- # Remove rows where there is no micro architecture
- merged_data <- merged_data %>%
- filter(!is.na(central_NREM_Spl_pmin) | !is.na(frontal_Absolute_NREM_0.25_to_1.0Hz))
- # Convert redcap_event_name values in redcap_df to match timepoint labels
- redcap_df <- redcap_df %>%
- mutate(Timepoint = case_when(
- redcap_event_name == "baseline_clinical_arm_1" ~ "BL",
- redcap_event_name == "ltfu1_clinical_ass_arm_1" ~ "LTFU1",
- redcap_event_name == "ltfu2_clinical_ass_arm_1" ~ "LTFU2",
- TRUE ~ NA_character_ # Set unmatched values to NA if there are any
- )) %>%
- select(abc_id, Timepoint, cognitive_classification, sex_spss, age_spss, gds_total_spss, vascular_disease_spss, bmi_spss, mmse_spss, cirs_total_score_spss, antidep_yn_spss, psqi_global_spss, apnea_hypopnea_index_tst, o2_desat3percent_index_tst,
- total_sleep_time_min, wake_after_sleep_onset_min, sleep_efficiency_percent_tib, nrem_min, rem_min, antidep_yn, t0_ct_2_1,t0_ct_3_1,t0_ct_4_1,t0_ct_5_1,t0_ct_6_1, psg_study_date, hba_mri_date) %>%
- mutate(across(everything(), ~ replace(.x, .x %in% c(777, 888, 999), NA)))%>%
- mutate(abc_id = paste0("ABC_", abc_id))
- ### List of Meds and RedCap codes
- # antidep_yn
- # hypnotics or sedatives - t0_ct_2_1
- # mood stabilisers/antiepileptic - t0_ct_3_1
- # antipsychotics - t0_ct_4_1
- # Benzo - t0_ct_5_1
- # Cholinesterase inhibitirs - t0_ct_6_1
- final_merged_data <- left_join(merged_data, redcap_df, by = c("ABC_ID" = "abc_id", "Timepoint" = "Timepoint"))
- morediagnoses_df <- morediagnoses_df %>%
- filter(ABC_ID != "")
- final_merged_data <- left_join(final_merged_data, morediagnoses_df, by = c("ABC_ID" = "ABC_ID", "Timepoint" = "Timepoint"))
- # Code below was used for identifying missing clinical diagnoses
- #missing_data <- final_merged_data %>%
- # filter(is.na(SCIvsMCI)) %>%
- # select(ABC_ID, Timepoint, clinical_diagnosis)
- # Save the selected columns to a CSV file
- #write.csv(missing_data, "C:/Users/Aaron Lam/OneDrive - The University of Sydney (Staff)/9. PAPERS/1. #Co-authors/2024/SK_FBA_Sleepmicro/Analysis/ABC_ID_and_clinical_diagnosis.csv", row.names = FALSE)
- #clean up diagnoses - # 0 = SCI, 1=MCI
- final_merged_data <- final_merged_data %>%
- mutate(SCIvsMCI = ifelse(cognitive_classification == 1, 1,
- ifelse(cognitive_classification == 2, 0,
- ifelse(cognitive_classification == 3,1,
- ifelse(cognitive_classification == 4, 1,
- ifelse(cognitive_classification == 5, 1,
- ifelse(cognitive_classification == 6, 1, NA)))))))
- # Obtaining more diagnoses
- final_merged_data <- final_merged_data %>%
- mutate(SCIvsMCI = ifelse(is.na(SCIvsMCI),
- case_when(
- clinical_diagnosis == 1 ~ 0,
- clinical_diagnosis == 2 ~ 0,
- clinical_diagnosis == 3 ~ 1,
- clinical_diagnosis == 4 ~ 1,
- clinical_diagnosis == 5 ~ 1,
- clinical_diagnosis == 6 ~ 1,
- clinical_diagnosis == 7 ~ 1,
- clinical_diagnosis == 8 ~ 1
- ),
- SCIvsMCI))
- final_merged_data$SCIvsMCI <- as.factor(final_merged_data$SCIvsMCI)
- final_merged_data <- final_merged_data %>%
- filter(!is.na(SCIvsMCI))
- table(final_merged_data$SCIvsMCI)
- final_merged_data <- final_merged_data %>%
- mutate(frontal_Absolute_NREM_0.25_to_1.0Hz = ifelse(frontal_Absolute_NREM_0.25_to_1.0Hz >= 800, NA, frontal_Absolute_NREM_0.25_to_1.0Hz)) %>%
- mutate(central_Absolute_NREM_0.25_to_1.0Hz = ifelse(central_Absolute_NREM_0.25_to_1.0Hz >= 800, NA, central_Absolute_NREM_0.25_to_1.0Hz))
- dvs <- c("central_NREM_Spl_pmin",
- "frontal_NREM_Spl_pmin",
- "central_NREM_Spl_fast_pmin",
- "frontal_NREM_Spl_fast_pmin",
- "central_NREM_Spl_slow_pmin",
- "frontal_NREM_Spl_slow_pmin",
- "frontal_NREM_MeanMaxHeight",
- "central_NREM_MeanMaxHeight",
- "frontal_Absolute_NREM_0.25_to_1.0Hz",
- "central_Absolute_NREM_0.25_to_1.0Hz")
- final_merged_data[paste0("log_", dvs)] <- log(final_merged_data[dvs])
- final_merged_data$ATR_total_fbc<- rowMeans(
- final_merged_data[, c("ATR_left_fbc", "ATR_right_fbc")],
- na.rm = TRUE
- )
- final_merged_data$SLF_III_total_fbc <- rowMeans(
- final_merged_data[, c("SLF_III_left_fbc", "SLF_III_right_fbc")],
- na.rm = TRUE
- )
- final_merged_data$SLF_II_total_fbc <- rowMeans(
- final_merged_data[, c("SLF_II_left_fbc", "SLF_II_right_fbc")],
- na.rm = TRUE
- )
- ```
- ```{r model functions, include = false}
- # Define the function
- run_moderation_analysis <- function(data, dvs, ivs, moderator, output_dir = "results") {
- # Create output directory if it doesn't exist
- if (!dir.exists(output_dir)) dir.create(output_dir)
- # Loop through each combination of DV and IV
- for (dv in dvs) {
- for (iv in ivs) {
- # Subset the data to remove rows with NA in the relevant variables
- temp_data <- data[complete.cases(data[, c(dv, iv, moderator)]), ]
- # Construct the formula
- formula <- as.formula(paste(scale(dv)), "~", scale(iv), "*", scale(moderator))
- # Fit the model
- model <- lm(formula, data = temp_data)
- # Save the model summary to a text file
- summary_file <- file.path(output_dir, paste0("model_", dv, "_", iv, "_summary.txt"))
- capture.output(summary(model), file = summary_file)
- # Create interaction plot
- temp_data$predicted <- predict(model)
- gg <- ggplot(temp_data, aes_string(x = iv, y = dv, color = moderator)) +
- geom_point(alpha = 0.6) +
- geom_smooth(method = "lm", se = FALSE) +
- labs(title = paste("Interaction Effect:", iv, "and", moderator, "on", dv),
- x = iv, y = dv, color = moderator) +
- theme_minimal()
- # Save the plot
- plot_file <- file.path(output_dir, paste0("plot_", dv, "_", iv, ".png"))
- ggsave(plot_file, plot = gg)
- }
- }
- }
- # Define the function
- run_moderation_analysis_withcovariates <- function(data, dvs, ivs, moderator, covariates = NULL, output_dir = "results") {
- # Create output directory if it doesn't exist
- if (!dir.exists(output_dir)) dir.create(output_dir)
- # Standardize function (only for numeric variables)
- standardize <- function(x) {
- if (is.numeric(x)) {
- return((x - mean(x, na.rm = TRUE)) / sd(x, na.rm = TRUE))
- } else {
- return(x) # Return non-numeric variables unchanged
- }
- }
- # Loop through each combination of DV and IV
- for (dv in dvs) {
- for (iv in ivs) {
- # Subset the data to remove rows with NA in the relevant variables
- vars_to_check <- c(dv, iv, moderator, covariates)
- temp_data <- data[complete.cases(data[, vars_to_check]), ]
- # Standardize only numeric variables
- temp_data[[dv]] <- standardize(temp_data[[dv]])
- temp_data[[iv]] <- standardize(temp_data[[iv]])
- temp_data[[moderator]] <- standardize(temp_data[[moderator]])
- if (!is.null(covariates)) {
- numeric_covariates <- covariates[sapply(temp_data[covariates], is.numeric)]
- temp_data[numeric_covariates] <- lapply(temp_data[numeric_covariates], standardize)
- }
- # Construct the formula with covariates
- covariate_terms <- if (!is.null(covariates)) paste(covariates, collapse = " + ") else ""
- formula <- if (covariate_terms != "") {
- as.formula(paste(dv, "~", iv, "*", moderator, "+", covariate_terms))
- } else {
- as.formula(paste(dv, "~", iv, "*", moderator))
- }
- # Fit the model
- model <- lm(formula, data = temp_data)
- # Save the model summary to a text file
- summary_file <- file.path(output_dir, paste0("model_", dv, "_", iv, "_summary.txt"))
- capture.output(summary(model), file = summary_file)
- # Create interaction plot
- temp_data$predicted <- predict(model)
- gg <- ggplot(temp_data, aes_string(x = iv, y = dv, color = moderator)) +
- geom_point(alpha = 0.6) +
- geom_smooth(method = "lm", se = FALSE) +
- labs(title = paste("Interaction Effect:", iv, "and", moderator, "on", dv),
- x = iv, y = dv, color = moderator) +
- theme_minimal()
- # Save the plot
- plot_file <- file.path(output_dir, paste0("plot_", dv, "_", iv, ".png"))
- ggsave(plot_file, plot = gg)
- }
- }
- }
- # t-test function
- analyze_group_differences <- function(data, binary_var, variables, output_dir = "results") {
- # Create output directory if it doesn't exist
- if (!dir.exists(output_dir)) dir.create(output_dir)
- # Ensure the binary variable is a factor
- data[[binary_var]] <- as.factor(data[[binary_var]])
- # Loop through the variables
- for (var in variables) {
- # Remove rows with NA in the relevant columns
- temp_data <- data[complete.cases(data[, c(binary_var, var)]), ]
- # Perform a t-test
- t_test <- t.test(as.formula(paste(var, "~", binary_var)), data = temp_data)
- # Save the t-test results to a text file
- summary_file <- file.path(output_dir, paste0("ttest_", var, "_by_", binary_var, ".txt"))
- capture.output(print(t_test), file = summary_file)
- # Calculate mean and standard error for bar graph
- summary_stats <- temp_data %>%
- group_by(!!sym(binary_var)) %>%
- summarise(
- Mean = mean(!!sym(var), na.rm = TRUE),
- SE = sd(!!sym(var), na.rm = TRUE) / sqrt(n())
- )
- # Create bar graph of means with error bars
- gg <- ggplot(summary_stats, aes_string(x = binary_var, y = "Mean", fill = binary_var)) +
- geom_bar(stat = "identity", position = position_dodge(), alpha = 0.7) +
- geom_errorbar(aes(ymin = Mean - SE, ymax = Mean + SE), width = 0.2, position = position_dodge(0.9)) +
- labs(
- title = paste("Mean of", var, "by", binary_var),
- x = binary_var, y = paste("Mean of", var), fill = binary_var
- ) +
- theme_minimal() +
- theme(legend.position = "none")
- # Save the plot
- plot_file <- file.path(output_dir, paste0("barchart_", var, "_by_", binary_var, ".png"))
- ggsave(plot_file, plot = gg)
- }
- }
- ```
- ```{r Table 1, echo=FALSE}
- table(final_merged_data$SCIvsMCI)
- table(final_merged_data$SCIvsMCI, final_merged_data$sex_spss)
- chisq.test(final_merged_data$SCIvsMCI, final_merged_data$sex_spss)
- table(final_merged_data$SCIvsMCI, final_merged_data$antidep_yn_spss)
- chisq.test(final_merged_data$SCIvsMCI, final_merged_data$antidep_yn_spss)
- # Mean (SD) within groups - t-test for Age, MMSE, GDS15, BMI, CIRS-G, PSQI-total score, Vascular risk index.
- hist(final_merged_data$age_spss)
- t.test(age_spss ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$age_spss, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- wilcox.test(mmse_spss ~ SCIvsMCI, data = final_merged_data, exact = FALSE)
- tapply(final_merged_data$mmse_spss, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$mmse_spss, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- hist(final_merged_data$gds_total_spss)
- t.test(log1p(final_merged_data$gds_total_spss) ~ SCIvsMCI, var.equal = TRUE,data = final_merged_data)
- tapply(final_merged_data$gds_total_spss, final_merged_data$SCIvsMCI, mean, na.rm = TRUE)
- tapply(final_merged_data$gds_total_spss, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- t.test(bmi_spss ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$bmi_spss, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- t.test(log1p(cirs_total_score_spss) ~ SCIvsMCI, var.equal = TRUE,data = final_merged_data)
- tapply(final_merged_data$cirs_total_score_spss, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$cirs_total_score_spss, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- hist(final_merged_data$psqi_global_spss)
- t.test(sqrt(psqi_global_spss) ~ SCIvsMCI,var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$psqi_global_spss, final_merged_data$SCIvsMCI, mean, na.rm = TRUE)
- tapply(final_merged_data$psqi_global_spss, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- #t.test(as.numeric(vascular_disease_spss) ~ SCIvsMCI, data = final_merged_data) # issue with the data
- #tapply(final_merged_data$vascular_disease_spss, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- ```
- ```{r Table 2, echo=FALSE}
- hist(final_merged_data$total_sleep_time_min)
- t.test(total_sleep_time_min ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$total_sleep_time_min, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- hist(final_merged_data$nrem_min)
- t.test(nrem_min ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$nrem_min, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- hist(final_merged_data$rem_min)
- t.test(rem_min ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$rem_min, final_merged_data$SCIvsMCI, sd, na.rm = TRUE)
- hist(log(final_merged_data$wake_after_sleep_onset_min))
- t.test(log(wake_after_sleep_onset_min) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$wake_after_sleep_onset_min, final_merged_data$SCIvsMCI==0, median, na.rm = TRUE)
- hist(final_merged_data$sleep_efficiency_percent_tib^2)
- t.test(sleep_efficiency_percent_tib^2 ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$sleep_efficiency_percent_tib, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$sleep_efficiency_percent_tib, final_merged_data$SCIvsMCI==0, IQR, na.rm = TRUE)
- hist(log(final_merged_data$apnea_hypopnea_index_tst))
- t.test(log1p(apnea_hypopnea_index_tst) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$apnea_hypopnea_index_tst, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$apnea_hypopnea_index_tst, final_merged_data$SCIvsMCI==0, IQR, na.rm = TRUE)
- hist(log(final_merged_data$o2_desat3percent_index_tst))
- t.test(log1p(o2_desat3percent_index_tst) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$o2_desat3percent_index_tst, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$o2_desat3percent_index_tst, final_merged_data$SCIvsMCI==0, IQR, na.rm = TRUE)
- # SO
- hist(log(final_merged_data$frontal_Absolute_NREM_0.25_to_1.0Hz))
- t.test(log(frontal_Absolute_NREM_0.25_to_1.0Hz) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$frontal_Absolute_NREM_0.25_to_1.0Hz, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$frontal_Absolute_NREM_0.25_to_1.0Hz, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(central_Absolute_NREM_0.25_to_1.0Hz) ~ SCIvsMCI,var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$central_Absolute_NREM_0.25_to_1.0Hz, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$central_Absolute_NREM_0.25_to_1.0Hz, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- #Spindles
- t.test(log(frontal_NREM_Spl_pmin) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$frontal_NREM_Spl_pmin, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$frontal_NREM_Spl_pmin, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(central_NREM_Spl_pmin) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$central_NREM_Spl_pmin, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$central_NREM_Spl_pmin, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(frontal_NREM_Spl_fast_pmin) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$frontal_NREM_Spl_fast_pmin, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$frontal_NREM_Spl_fast_pmin, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(central_NREM_Spl_fast_pmin) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$central_NREM_Spl_fast_pmin, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$central_NREM_Spl_fast_pmin, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(frontal_NREM_MeanMaxHeight) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$frontal_NREM_MeanMaxHeight, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$frontal_NREM_MeanMaxHeight, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- t.test(log(central_NREM_MeanMaxHeight) ~ SCIvsMCI, var.equal = TRUE, data = final_merged_data)
- tapply(final_merged_data$central_NREM_MeanMaxHeight, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$central_NREM_MeanMaxHeight, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- ```
- ```{r Supplementary Table 1, echo=FALSE}
- hist(final_merged_data$ATR_left_fbc)
- hist(final_merged_data$ATR_right_fbc)
- hist(final_merged_data$SLF_II_left_fbc)
- hist(final_merged_data$SLF_II_right_fbc)
- hist(final_merged_data$SLF_III_left_fbc)
- hist(final_merged_data$SLF_III_right_fbc)
- wilcox.test(ATR_total_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$ATR_total_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$ATR_total_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- wilcox.test(ATR_right_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$ATR_right_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$ATR_right_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- wilcox.test(SLF_II_total_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$SLF_II_total_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$SLF_II_total_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- wilcox.test(SLF_II_right_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$SLF_II_right_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$SLF_II_right_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- wilcox.test(SLF_III_total_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$SLF_III_total_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$SLF_III_total_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- wilcox.test(SLF_III_right_fbc ~ SCIvsMCI, data=final_merged_data)
- tapply(final_merged_data$SLF_III_right_fbc, final_merged_data$SCIvsMCI, median, na.rm = TRUE)
- tapply(final_merged_data$SLF_III_right_fbc, final_merged_data$SCIvsMCI==1, IQR, na.rm = TRUE)
- ```
- # Averaged tract analysis
- ```{r AVERAGED TRACTS ANALYSIS}
- # Setup your variables of interest
- dvs <- c("log_central_NREM_Spl_pmin",
- "log_frontal_NREM_Spl_pmin",
- "log_central_NREM_Spl_fast_pmin",
- "log_frontal_NREM_Spl_fast_pmin",
- "log_central_NREM_Spl_slow_pmin",
- "log_frontal_NREM_Spl_slow_pmin",
- "log_frontal_NREM_MeanMaxHeight",
- "log_central_NREM_MeanMaxHeight")
- ivs <- c("ATR_total_fbc",
- "SLF_III_total_fbc",
- "SLF_II_total_fbc")
- moderator <- "SCIvsMCI"
- covariates <- c("sex_spss", "age_spss")
- # Run the function
- run_moderation_analysis_withcovariates(
- data = final_merged_data,
- dvs = dvs,
- ivs = ivs,
- moderator = moderator,
- covariates = covariates,
- output_dir = "/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Revision1_Results/Total_tract_log_spl_Corrected_moderationAnalyses/"
- )
- ```
- ```{r AVERAGED TRACTS ANALYSIS}
- # Setup your variables of interest
- dvs <- c("log_frontal_Absolute_NREM_0.25_to_1.0Hz",
- "log_central_Absolute_NREM_0.25_to_1.0Hz")
- ivs <- c("ATR_total_fbc",
- "SLF_III_total_fbc",
- "SLF_II_total_fbc")
- moderator <- "SCIvsMCI"
- covariates <- c("sex_spss", "age_spss")
- # Run the function
- run_moderation_analysis_withcovariates(
- data = final_merged_data,
- dvs = dvs,
- ivs = ivs,
- moderator = moderator,
- covariates = covariates,
- output_dir = "/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Revision1_Results/Total_tract_log_SOpower_Corrected_moderationAnalyses/"
- )
- ```
- ## Table 3 effect sizes and FDR corrections
- ```{r}
- # frontal
- fiti <- lm(log_frontal_NREM_Spl_slow_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_slow_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_slow_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- #central
- fiti <- lm(log_central_NREM_Spl_slow_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_slow_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_slow_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- # Benjamini-Hochberg procedure
- # Main
- pvals <- c(0.291,0.419,0.629,0.202,0.961,0.213)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- # Interactions
- pvals <- c(0.408,0.186,0.883,0.190,0.501,0.381)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- # Fast spindle density - moderation
- ```{r simple slopes}
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_III_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_III_total_fbc, x.label = "Total SLF-III FBC", y.label = "Central fast spindle denstiy",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, line.thickness = 2, point.size = 2,interval = TRUE) +
- theme(
- axis.title.x = element_text(size = 20, colour = "black"),
- axis.title.y = element_text(size = 20, colour = "black"),
- axis.text = element_text(size = 20, face="bold", colour = "black")
- )
- # Effect size of fast spindle density
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- rsq::rsq.partial(fiti)
- ```
- ## Table 4 effect sizes and FDR corrections
- ```{r}
- # frontal
- fiti <- lm(log_frontal_NREM_Spl_fast_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_fast_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_fast_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- #central
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_fast_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- # Benjamini-Hochberg procedure
- # Main
- pvals <- c(0.236,0.696,0.745,0.809,0.149,0.028)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- # Interactions
- pvals <- c(0.490,0.642,0.904,0.659,0.052,0.028)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- ## Table 5 effect sizes and FDR corrections
- ```{r}
- # frontal
- fiti <- lm(log_frontal_Absolute_NREM_0.25_to_1.0Hz ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_Absolute_NREM_0.25_to_1.0Hz ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_Absolute_NREM_0.25_to_1.0Hz ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- #central
- fiti <- lm(log_central_Absolute_NREM_0.25_to_1.0Hz ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_Absolute_NREM_0.25_to_1.0Hz ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_Absolute_NREM_0.25_to_1.0Hz ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- # Benjamini-Hochberg procedure
- # Main
- pvals <- c(0.751,0.774,0.432,0.771,0.324,0.158)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- # Interactions
- pvals <- c(0.928,0.322,0.073,0.771,0.324,0.158)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- ## Table 6 effect sizes and FDR corrections
- ```{r}
- # frontal
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- #central
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- # Benjamini-Hochberg procedure
- pvals <- c(0.871,0.872,0.929,0.813,0.937,0.989)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- # Interactions
- pvals <- c(0.555,0.026,0.461,0.554,0.009,0.351)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- # Spindle amplitude simple slopes with FDR at the end
- ``` {r simple slopes}
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- x <- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- x$slopes
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_total_fbc, x.label = "Total SLF-II FBC", y.label = "Central overall spindle amplitude", modx.labels = c("SCD","MCI"), modx = SCIvsMCI, line.thickness = 2, point.size = 2,interval = TRUE) +
- theme(
- axis.title.x = element_text(size = 20, colour = "black"),
- axis.title.y = element_text(size = 20, colour = "black"),
- axis.text = element_text(size = 20, face="bold", colour = "black")
- )
- # remove outliers and repeat analysis
- outliers <- order(final_merged_data$log_central_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:2]
- # Create new variable
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_central_NREM_MeanMaxHeight
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_total_fbc, x.label = "Total SLF-II FBC", y.label = "Central overall spindle amplitude",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- # frontal repeat
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_total_fbc, x.label = "Total SLF-II FBC", y.label = "Frontal overall spindle amplitude",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- # remove frontal outliers
- outliers <- order(final_merged_data$log_frontal_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:4]
- # Create new variable
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_frontal_NREM_MeanMaxHeight
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- # model
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_total_fbc, x.label = "Total SLF-II FBC", y.label = "Central overall spindle amplitude",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- ### FDR corrections
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- x <- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- x$slopes
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- x <- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- x$slopes
- pvals <- c(0.937,0.00001,0.873,0.000010)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- # Correlation of fast and slow spindles
- ```{r}
- cor.test(final_merged_data$frontal_NREM_Spl_fast_pmin,final_merged_data$frontal_NREM_Spl_slow_pmin)
- cor.test(final_merged_data$central_NREM_Spl_fast_pmin,final_merged_data$central_NREM_Spl_slow_pmin)
- ```
- # removing outliers in unilateral tracts (left vs. right)
- ```{r}
- ### FRONTAL ####
- # remove outliers and repeat analysis
- outliers <- order(final_merged_data$log_frontal_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:4]
- # Create new variable
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_frontal_NREM_MeanMaxHeight
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_left_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_II_left_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_left_fbc, x.label = "Frontal overall spindle amplitude", y.label = "Total SLF-II FBC",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_right_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_II_right_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_right_fbc, x.label = "Frontal overall spindle amplitude", y.label = "Total SLF-II FBC",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- ### CENTRAL ####
- # remove outliers and repeat analysis
- outliers <- order(final_merged_data$log_central_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:2]
- # Create new variable
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_central_NREM_MeanMaxHeight
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_II_total_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_left_fbc, x.label = "Central overall spindle amplitude", y.label = "Total SLF-II FBC",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_right_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- summary(fiti)
- sim_slopes(fiti, pred = SLF_II_right_fbc, modx = SCIvsMCI, jnplot = TRUE)
- # Interaction plot with confidence intervals
- interact_plot(fiti, plot.points=TRUE, pred = SLF_II_right_fbc, x.label = "Central overall spindle amplitude", y.label = "Total SLF-II FBC",modx.labels = c("SCD","MCI"), modx = SCIvsMCI, interval = TRUE)
- ```
- # Correlation of tracts
- ```{r}
- library(Hmisc)
- tract_data <- final_merged_data[, c("ATR_total_fbc",
- "SLF_II_total_fbc",
- "SLF_III_total_fbc")]
- cor_results <- rcorr(as.matrix(tract_data))
- cor_results$r # correlation matrix
- cor_results$P # p-value matrix
- ```
- # Effect size of combined tracts - whole sample
- ```{r}
- ### FRONTAL ###
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- #### CENTRAL ####
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- ```
- # Effect size of combined tracts -REPEAT IN OUTLIERS REMOVED
- ```{r}
- ### CHOOSE HOW MANY OUTLIERS TO REMOVE
- # remove outliers and repeat analysis
- # Frontal
- # remove outliers and repeat analysis
- outliers <- order(final_merged_data$log_frontal_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:2]
- # Create new variable
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_frontal_NREM_MeanMaxHeight
- final_merged_data$log_frontal_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- # Central
- outliers <- order(final_merged_data$log_central_NREM_MeanMaxHeight,
- decreasing = TRUE)[1:2]
- # Create new variable
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved <-
- final_merged_data$log_central_NREM_MeanMaxHeight
- final_merged_data$log_central_NREM_MeanMaxHeight_outlierremoved[outliers] <- NA
- ### FRONTAL ###
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_frontal_NREM_MeanMaxHeight_outlierremoved ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- #### CENTRAL ####
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ ATR_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_II_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- summary(fiti)
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 0))
- eta_squared(fiti, partial = TRUE)
- fiti <- lm(log_central_NREM_MeanMaxHeight_outlierremoved ~ SLF_III_total_fbc + sex_spss + age_spss, data = subset(final_merged_data, SCIvsMCI == 1))
- eta_squared(fiti, partial = TRUE)
- ```
- ## Supplementary Table 2 effect sizes and FDR correction
- ```{r}
- # frontal
- fiti <- lm(log_frontal_NREM_Spl_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_frontal_NREM_Spl_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- #central
- fiti <- lm(log_central_NREM_Spl_pmin ~ ATR_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_pmin ~ SLF_II_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- fiti <- lm(log_central_NREM_Spl_pmin ~ SLF_III_total_fbc * SCIvsMCI + sex_spss + age_spss, data = final_merged_data)
- rsq::rsq.partial(fiti)
- # Benjamini-Hochberg procedure
- # Main
- pvals <- c(0.639,0.655,0.620,0.664,0.652,0.644)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- # Interactions
- pvals <- c(0.755,0.285,0.819,0.841,0.181,0.594)
- qvals <- p.adjust(pvals, method = "BH")
- qvals
- ```
- ```{r bimodal distribution of spindles}
- path <- "/Users/alam2002/Library/CloudStorage/OneDrive-TheUniversityofSydney(Staff)/9. PAPERS/DWI_EEG/1. Analysis/Data/IndividualSpindles/ABC_1169_spindles.xls" # Two random subjects with high number of spindles ABC0378
- spindles <- read_excel(path, sheet = "C3") #F3 and C3
- freq_df <- spindles %>%
- select(`Frequency (Hz)`) %>%
- filter(!is.na(`Frequency (Hz)`))
- hist(freq_df$`Frequency (Hz)`, breaks = 40,
- main = "Central spindle frequency distribution",
- xlab = "Frequency (Hz)")
- abline(v = 13, lty = 2)
- ```
- ## Medications
- ```{r}
- # antidep_yn
- table(final_merged_data$antidep_yn)
- # first antidep medication
- table(final_merged_data$t0_ct_1_1)
- # hypnotics or sedatives - t0_ct_2_1
- sum(!is.na(final_merged_data$t0_ct_2_1))
- # mood stabilisers/antiepileptic - t0_ct_3_1
- sum(!is.na(final_merged_data$t0_ct_3_1))
- # antipsychotics - t0_ct_4_1
- sum(!is.na(final_merged_data$t0_ct_4_1))
- # Benzo - t0_ct_5_1
- sum(!is.na(final_merged_data$t0_ct_5_1))
- # Cholinesterase inhibitirs - t0_ct_6_1
- sum(!is.na(final_merged_data$t0_ct_6_1))
- ```
- ## MRI date difference
- ```{r}
- final_merged_data <- final_merged_data %>%
- mutate(
- hba_mri_date = as.Date(hba_mri_date)
- )
- final_merged_data <- final_merged_data %>%
- mutate(
- psg_study_date = parse_date_time(
- psg_study_date,
- orders = c("mdy", "dmy")
- ) %>% as.Date()
- )
- final_merged_data$hba_mri_date
- final_merged_data$psg_study_date
- date_diff <- difftime(as.Date(final_merged_data$hba_mri_date),
- as.Date(final_merged_data$psg_study_date),
- units = "days")
- mean(abs(as.numeric(date_diff)), na.rm = TRUE)
- sd(abs(as.numeric(date_diff)), na.rm = TRUE)
- ```
DWI_EEG_osf.Rmd, no license · at the source
Overview
- School of Psychology, The University of Sydney, Sydney, NSW 2050, Australia
- Brain and Mind Centre and Charles Perkins Centre, The University of Sydney, Sydney 2050, NSW, Australia
- CIRUS, Sleep and Circadian Research Group, Woolcock Institute of Medical Research, Macquarie University, Sydney 2113, NSW, Australia
- Sydney Imaging and School of Biomedical Engineering, The University of Sydney, Sydney 2050, NSW, Australia
- School of Psychological Sciences, Macquarie University, Sydney 2113, NSW, Australia
Abstract
While sleep disturbance increases with age and neurodegeneration, the relationship between sleep micro-architecture and changes in key white matter tracts is unknown. We aimed to determine how sleep spindles and slow oscillations relate to structural connectivity within selected white matter tracts in older adults at risk for dementia. In this cross-sectional study, 67 participants (mean age = 68.1; 47 females) with subjective cognitive decline (n = 21) or mild cognitive impairment (n = 46) underwent neuropsychological assessment, magnetic resonance imaging and polysomnography. White matter connectivity of anterior thalamic radiation and superior longitudinal fasciculus subdivisions II and III was quantified using whole-brain tractography, with left and right tracts combined. Primary sleep micro-architecture outcomes included slow (11–13 Hz) and fast (13–16 Hz) spindle density and slow oscillation (0.25–1 Hz) power. Secondary outcomes included: overall spindle density (11–16 Hz) and amplitude. Linear regressions assessed associations between sleep micro-architecture and structural connectivity, adjusting for age and sex, with cognitive classification as a moderator. Multiple comparisons were controlled for using the Benjamini–Hochberg false discovery rate procedure, with q < 0.1 considered statistically significant. The mild cognitive impairment group exhibited lower frontal and central fast spindle density compared to the subjective cognitive impairment group (P < 0.05), with no other group differences in sleep macro-architecture or slow oscillatory activity. After false discovery rate correction, there were no significant associations between slow spindle density, fast spindle density or slow oscillation power and tract connectivity. An interaction between central fast spindle density and superior longitudinal fasciculus III connectivity was observed prior to false discovery rate correction, explaining 8% of unique variance, but did not remain significant after correction (q > 0.10). Exploratory analyses reveal a significant interaction between superior longitudinal fasciculus II connectivity and cognitive classification on spindle amplitude, with greater connectivity associated with higher spindle amplitude in individuals with mild cognitive impairment (P = 0.001), but not in those with subjective cognitive decline (P > 0.05). Overall, white matter connectivity of the anterior thalamic radiation and superior longitudinal fasciculus was not robustly associated with sleep spindle density or slow oscillatory power in this at-risk cohort. However, superior longitudinal fasciculus II connectivity may differentially relate to spindle amplitude in mild cognitive impairment, potentially reflecting altered thalamocortical network engagement in early neurodegeneration.
Reproduced under the paper's license (CC BY), from the paper cited above.
Repository
Its files are read in the Code ↔ Paper reader above, with 2 matches between paragraphs and lines of code.
OSF uy7jk
Availability: 1 check, the latest on 27 September 2026: the link answers (HTTP 200)
- 27 September 2026: the link answers (HTTP 200)
1 file
- DWI_EEG_osf.Rmd, R, 1,196 lines, 2 matches
The paper's code and data availability statement is in the Data section.
Tracing map
Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.
What the map holds:
- 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
- 1 script, each with its path and the digest of its content;
- 2 matches between paragraphs of the paper and lines of the code (method lexical-v1);
- neither the text of the paper nor the code itself.
Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.
Data
No dataset and no data link were found in the paper.
Data availability
Due to ethical considerations, data used in this article will be shared upon reasonable request to the corresponding author. The code supporting the findings of this study is available at: osf.io/
Reproduced under the paper's license (CC BY), from the paper cited above.
Versions
The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.
Version 1, 27 September 2026: the first record
Recorded: type, language, journal, volume, issue, pages, dates, 7 authors, 5 keywords, 4 funders, 63 references.
Cite
This paper
Lam, A., Kong, S. D., Palmer, J. R., Calamante, F., Almgren, H., D’Rozario, A. L., & Naismith, S. L. (2026). Sleep spindles are linked to white matter connectivity differentially in older adults with and without cognitive impairment. Brain communications, 8(4), fcag303. https://
BibTeX
@article{lam2026sleep,
author = {Lam, Aaron and Kong, Shawn Dexiao and Palmer, Jake R and Calamante, Fernando and Almgren, Hannes and D’Rozario, Angela L and Naismith, Sharon L},
title = {{Sleep spindles are linked to white matter connectivity differentially in older adults with and without cognitive impairment}},
journal = {Brain communications},
year = {2026},
month = aug,
volume = {8},
number = {4},
pages = {fcag303},
publisher = {Oxford University Press},
issn = {2632-1297},
doi = {10.1093/
url = {https://
pmid = {42582630},
pmcid = {PMC13458153}
}
RIS
TY - JOUR
AU - Lam, Aaron
AU - Kong, Shawn Dexiao
AU - Palmer, Jake R
AU - Calamante, Fernando
AU - Almgren, Hannes
AU - D’Rozario, Angela L
AU - Naismith, Sharon L
TI - Sleep spindles are linked to white matter connectivity differentially in older adults with and without cognitive impairment
T2 - Brain communications
J2 - Brain Commun
PY - 2026
DA - 2026/
VL - 8
IS - 4
SP - fcag303
SN - 2632-1297
PB - Oxford University Press
DO - 10.1093/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.1093/
"type": "article-journal",
"title": "Sleep spindles are linked to white matter connectivity differentially in older adults with and without cognitive impairment",
"container-title": "Brain communications",
"author": [
{
"family": "Lam",
"given": "Aaron"
},
{
"family": "Kong",
"given": "Shawn Dexiao"
},
{
"family": "Palmer",
"given": "Jake R"
},
{
"family": "Calamante",
"given": "Fernando"
},
{
"family": "Almgren",
"given": "Hannes"
},
{
"family": "D’Rozario",
"given": "Angela L"
},
{
"family": "Naismith",
"given": "Sharon L"
}
],
"container-title-short":
"volume": "8",
"issue": "4",
"page": "fcag303",
"DOI": "10.1093/
"PMID": "42582630",
"PMCID": "PMC13458153",
"ISSN": "2632-1297",
"publisher": "Oxford University Press",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
8,
11
]
]
}
}
The tracing map gets a citation of its own once an author has validated it and it has a DOI.
Similar papers
The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.
- [1] doi:10.1093/braincomms/fcag204 [code]
- Altered rhythmic and arrhythmic electroencephalographic activity during non-rapid eye movement sleep in amnestic mild cognitive impairment.Journal: Brain communicationsIn common: Alzheimer's / dementia, EEG, 7 references
- [2] doi:10.1126/sciadv.aec2348 [code]
- Congenital blindness reduces myelination in human visual cortex.Journal: Science advancesIn common: ggplot2, tidyverse, structural MRI / diffusion, 9 references
- [3] doi:10.1016/j.dcn.2026.101721 [code]
- Neonatal amygdala microstructure and structural connectivity are associated with autistic traits at 2 years of age.Journal: Developmental cognitive neuroscienceIn common: structural MRI / diffusion, 10 references
- [4] doi:10.1038/s41467-026-73072-6 [code]
- Mapping the spatiotemporal continuum of structural connectivity development across the human connectome in youth.Journal: Nature communicationsIn common: easystats, ggplot2, tidyverse, structural MRI / diffusion, 6 references
- [5] doi:10.1016/j.nicl.2026.104053 [code]
- Childhood white matter organization predicts adolescent internalizing problems among youth with and without ADHD.Journal: NeuroImage. ClinicalIn common: ggplot2, tidyverse, structural MRI / diffusion, 7 references
- [6] doi:10.1162/imag.a.1153 [code]
- TRAMFIX: TRavelling Across Melbourne for FIXel-based analysis (a reproducibility and reliability study).Journal: Imaging neuroscience (Cambridge, Mass.)In common: structural MRI / diffusion, 8 references
- [7] doi:10.1093/pnasnexus/pgag108
- Aging disrupts the temporal organization of slow oscillations beyond density reduction.Journal: PNAS nexusIn common: systems, 6 references
- [8] doi:10.1162/imag.a.1325 [code]
- Decoding everyday levels of musical training from subcortical white-matter architecture.Journal: Imaging neuroscience (Cambridge, Mass.)In common: ggplot2, tidyverse, systems, structural MRI / diffusion, 6 references
- [9] doi:10.1162/imag.a.1303
- Composite reaction time and variability correlate with whole-brain white-matter characteristics.Journal: Imaging neuroscience (Cambridge, Mass.)In common: structural MRI / diffusion, 7 references
- [10] doi:10.7554/elife.103097 [code]
- Canonical neurodevelopmental trajectories of structural and functional manifolds.Journal: eLifeIn common: ggplot2, tidyverse, structural MRI / diffusion, 5 references
Contribute
The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.
Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 1 repository of the authors' code, each at its verified commit and with its license, 1 script, and 2 matches between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:896b65f753b1d1c8…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[.
Discussion, reproductions, activity
Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
