Mitofusin-2 in ventral striatal D1 neurons regulates effort-based motivation through sex-specific mitochondrial-synaptic reprogramming.
A correction to this paper has been published: the notice, 42607229, from Europe PMC.
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 · 460 lines · 22 KB · CC-BY-4.0
- ## Chioino et al. 2026, DESeq2 and GSEA
- ## In case of issues/suggestions, please contact: [email hidden]
- # For the differential expression analysis
- require(DESeq2)
- require(pheatmap)
- require(RColorBrewer)
- require(ggplot2)
- require(reshape2)
- require(ggrepel)
- # For the GSEA
- require(clusterProfiler)
- require(org.Mm.eg.db)
- require(org.Rn.eg.db)
- require(enrichplot)
- require(forcats)
- require(DOSE)
- require(ggplot2)
- require(lattice)
- ##### Differential expression analysis #####
- # Load in the raw read counts
- counts <- read.table("Ribotag_counts_clean.csv", header = T, check.names = FALSE, sep = "\t")
- rownames(counts) <- counts[,1]
- # Define the conditions table
- condition <- c(rep("KD", 2), rep("Ctrl", 5), rep("KD", 3))
- condition <- c(rep("M", 5), rep("F", 6))
- coldata <- data.frame(sampleNames = colnames(counts)[-1], condition = condition[])
- ## Batch correction using sva package ()
- require(sva)
- b <- c(rep("1",4),rep("2",6)) # Define the batch vector
- batch <- ComBat_seq(as.matrix(counts[,-1]), batch = b, group = c(condition))
- write.csv2(batch, file = "Ale_M_combined_batchCorrected.csv",quote = F)
- batch <- as.data.frame(batch)
- batch$Geneid <- sapply(strsplit(counts$Geneid, "\\."), "[", 1)
- ## Run DESeq2
- ddsHTSeq <- DESeqDataSetFromMatrix(countData = batch[,], colData = coldata, design = ~c(condition))
- # Remove reads which are low (here below 5 counts) and genes that were not represented in 3 or more samples.
- ddsHTSeq <- ddsHTSeq[rowSums(counts(ddsHTSeq)) > 5, ]
- ddsHTSeq <- ddsHTSeq[rowSums(counts(ddsHTSeq) == 0) <= 3, ]
- # This tells the program that the reference (the level to which samples should be compared) is WT.
- ddsHTSeq$condition <- relevel(ddsHTSeq$condition, ref="Ctrl")
- #### QC begins here... #####
- rld_BLIND <- vst(ddsHTSeq, blind = TRUE)
- sampleDists <- dist(t(assay(rld_BLIND)))
- # This calculates the Eucledean distance, meaning the greater the distance the dissimilar the samples.
- sampleDistMatrix <- as.matrix(sampleDists)
- colors <- colorRampPalette( rev(brewer.pal(9, "Greens")) )(255)
- pheatmap(sampleDistMatrix, col=colors, cluster_rows=F, display_numbers = T, fontsize_number = 10, number_color = "black", border_color = "black", annotation_colors = "black", main = "Eucledean Distance of mRNA Gene Expression", cellwidth = 50, cellheight = 25, treeheight_col = 15)
- write.csv(sampleDistMatrix, file = "Eucledean_distance_mRNA.csv")
- # And a principal component plot:
- data <- plotPCA(rld_BLIND, intgroup=c("condition"), returnData = TRUE)
- percentVar <- round(100 * attr(data, "percentVar"))
- ggplot(data[,], aes(PC1, PC2, color=condition)) + geom_point(size=5) +
- xlab(paste0("PC1: ",percentVar[1],"% variance")) + ylab(paste0("PC2: ",percentVar[2],"% variance")) +
- scale_colour_brewer(type = "qual", palette="Set1") + theme_linedraw(base_size = 24) +
- theme(panel.grid = element_line(colour = "blue")) +
- labs(color = "", title = "Ribotag Males", subtitle = "All reps, batch corrected, no mitogenes") + geom_text_repel(aes(label = name), max.overlaps = 15)
- ggsave(filename = "PCA_M_batchCorrected_noMitoGenes.pdf", width = 8, height = 6, onefile = F)
- # Spearman correlations:
- data_table <- assay(rld_BLIND)
- spearman <- cor(data_table, method = "spearman")
- sampleDistMatrix <- as.matrix(spearman)
- colors <- colorRampPalette(brewer.pal(9, "Greens") )(255)
- pheatmap(sampleDistMatrix, col=colors, display_numbers = round(sampleDistMatrix, digits = 3), fontsize_number = 10, number_color = "black", border_color = "black", annotation_colors = "black", main = "Spearman Correlation of mRNA Gene Expression", treeheight_col = 20) #, cellwidth = 50, cellheight = 25, treeheight_col = 15)
- #### Differential expression analysis begins here... ####
- ddsHTSeq <- estimateSizeFactors(ddsHTSeq)
- sizeFactors(ddsHTSeq)
- countingData <- counts(ddsHTSeq, normalized = T)
- # Export the normalized counts table
- write.table(countingData, file = "Ale_M_normalizedReadCounts.csv",quote = F, col.names = T, row.names = F, sep = "\t", dec = ".")
- dds <- DESeq(ddsHTSeq, betaPrior = FALSE)
- res <- results(dds)
- summary(res)
- #library("IHW")
- # In the contrast option, write in the order of ratio, for instance if you want KD/Ctrl -> c("condition", "KD", "Ctrl")
- res1 <- results(dds, contrast = c("condition", "KD", "Ctrl"), pAdjustMethod = "BH", alpha = 0.1)
- summary(res1)
- liste <- list(res1) # If you have more than one comparison, this list helps running the code through all at once
- fileNameSuffix <- c("M_KDvCtrl")
- generalName <- "RunsCombined_noBatchCorrection_allGenes_someRemoved"
- ## Volcano plots
- for (i in 1:length(liste)) {
- toplot <- as.data.frame(liste[i])
- toplot$gene <- sapply(strsplit(rownames(toplot), "\\."), "[", 1)
- toplot <- merge(toplot, annotation, by = "gene")
- pvallim <- 0.01
- xlim <- c(-4, 4)
- ylim <- c(0,20) # If you have genes with very low pvals, use a sensible pval cutoff for the graph!
- top <- 50
- DE <- toplot[is.finite(toplot$log2FoldChange),]
- DE <- DE[order(DE$pvalue),]
- label <- DE[DE$pvalue < pvallim,ncol(DE)][1:top] # Pick genes to be labeled in the graph, only the top x
- label <- c(label, rep("", nrow(DE)-length(label))) # Fill the rest of the vector with empty strings
- col1 <- DE$pvalue < pvallim & DE$log2FoldChange < 0
- col1 <- ifelse(col1, "Down", "no.change")
- col2 <- DE$pvalue < pvallim & DE$log2FoldChange > 0
- col2 <- ifelse(col2, "Up", "ns")
- col <- ifelse(col1 == "Down", col1, col2)
- cols <- c(Up = "blue", Down = "red", ns = "black")
- labcol <- ifelse(col == "Down", "red", "blue")
- numup <- sum(col == "Up", na.rm = T)
- numdown <- sum(col == "Down", na.rm = T)
- # With labels
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim, "_withLabels",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(xlim)*.5, y = max(-log10(DE$pvalue)*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(xlim)*.5, y = max(-log10(DE$pvalue)*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim, "_noLabels",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # With labels, no xlim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim, "_withLabels_noxlim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels, no xlim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(DE$log2FoldChange)*.5, y = max(-log10(DE$pvalue)*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(DE$log2FoldChange)*.5, y = max(-log10(DE$pvalue)*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim,"__noLabels_noxlim" ,".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # With labels + ylim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) + ylim(ylim[1], ylim[2]) + theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim, "_withLabels_ylim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels + ylim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(pvalue), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) + ylim(ylim[1], ylim[2]) + theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(xlim)*.5, y = max(ylim*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(xlim)*.5, y = max(ylim*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_pval_",pvallim, "_noLabels_ylim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- ## Volcano Plots with padj < 0.1
- padjlim <- 0.1
- xlim <- c(-4, 4)
- ylim <- c(0,20) # If you have genes with very low pvals, use a sensible pval cutoff for the graph!
- top <- 50
- DE <- toplot[is.finite(toplot$log2FoldChange),]
- DE <- DE[order(DE$padj),]
- label <- DE[DE$padj < padjlim,ncol(DE)][1:top] # Pick genes to be labeled in the graph, only the top x
- label <- c(label, rep("", nrow(DE)-length(label))) # Fill the rest of the vector with empty strings
- col1 <- DE$padj < padjlim & DE$log2FoldChange < 0
- col1 <- ifelse(col1, "Down", "no.change")
- col2 <- DE$padj < padjlim & DE$log2FoldChange > 0
- col2 <- ifelse(col2, "Up", "ns")
- col <- ifelse(col1 == "Down", col1, col2)
- cols <- c(Up = "blue", Down = "red", ns = "black")
- labcol <- ifelse(col == "Down", "red", "blue")
- numup <- sum(col == "Up", na.rm = T)
- numdown <- sum(col == "Down", na.rm = T)
- # With labels
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_padj_",padjlim, "_withLabels",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(xlim)*.5, y = max(-log10(DE$padj)*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(xlim)*.5, y = max(-log10(DE$padj)*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_padj_",padjlim, "_noLabels",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # With labels, no xlim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_padj_",padjlim, "_withLabels_noxlim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels, no xlim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) +theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(DE$log2FoldChange)*.5, y = max(-log10(DE$padj)*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(DE$log2FoldChange)*.5, y = max(-log10(DE$padj)*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_",fileNameSuffix[i], "_padj_",padjlim,"__noLabels_noxlim" ,".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # With labels + ylim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) + ylim(ylim[1], ylim[2]) + theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") + geom_text_repel(label=label, col = labcol, size = 3, max.overlaps = 100)
- ggsave(filename = paste("VolcanoPlot_", generalName, "_", fileNameSuffix[i], "_padj_",padjlim, "_withLabels_ylim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # Without labels + ylim
- ggplot(data=DE, aes(x=log2FoldChange, y=-log10(padj), col = col)) +
- geom_point() +
- theme_grey() + labs(col = "", title = (fileNameSuffix[i])) +
- scale_color_manual(values=cols) + xlim(xlim[1], xlim[2]) + ylim(ylim[1], ylim[2]) + theme(text = element_text(size = 18)) + geom_vline(xintercept = 0, linetype = "dashed") +
- annotate("text", label= paste("Down: ", numdown), x = min(xlim)*.5, y = max(ylim*.95, na.rm = T), color = "red") +
- annotate("text", label= paste("Up: ", numup), x = -min(xlim)*.5, y = max(ylim*.95, na.rm = T), color = "blue")
- ggsave(filename = paste("VolcanoPlot_", generalName, "_" ,fileNameSuffix[i], "_padj_",padjlim, "_noLabels_ylim",".pdf", sep = ""), width = 8, height = 6, onefile = F)
- }
- ## Saving the results as tables
- fileNameSuffix <- c("M_KDvCtrl")
- generalName <- "RunsCombined_noBatchCorrection_allGenes_someRemoved"
- for (i in 1:length(liste)) {
- res <- liste[i]
- res <- as.data.frame(res)
- res_Ordered <- as.data.frame(res[order(res$pvalue),])
- res_Ordered$gene <- rownames(res_Ordered)
- res_Ordered$gene <- sapply(strsplit(rownames(res_Ordered), "\\."), "[", 1)
- res_merged <- merge(res_Ordered, annotation, by="gene")
- # res_merged <- res_Ordered
- # wt_kd_F_merged <- wt_kd_F_merged[,c(1,8,9,2,3,6,7)]
- res_merged <- res_merged[,c(7,1:6)]
- res_merged <- res_merged[,c(1,9,2:7)]
- res_merged <- res_merged[order(res_merged$pvalue, decreasing = F),]
- colnames(res_merged)[1] <- "Gene"
- colnames(res_merged)[2] <- "GeneSymbol"
- res_sig <- subset(res_merged, res_merged$pvalue < 0.05)
- res_padj <- subset(res_merged, res_merged$padj < 0.1)
- write.table(res_merged, file = paste(generalName, "_", fileNameSuffix[i], "_allChanges.csv", sep = ""),quote = F, col.names = T, row.names = F, sep = "\t", dec = ".")
- write.table(res_sig, file = paste(generalName, "_", fileNameSuffix[i], "_pval0.05.csv", sep = ""),quote = F, col.names = T, row.names = F, sep = "\t", dec = ".")
- write.table(res_padj, file = paste(generalName, "_", fileNameSuffix[i], "_padj0.1.csv", sep = ""),quote = F, col.names = T, row.names = F, sep = "\t", dec = ".")
- }
- ## Comparisons (i.e. Male vs Female DEGs)
- ## Define cutoffs for i.e. p-value, or fold change
- group1 <- subset(wt_kd_F_sig, wt_kd_F_sig$log2FoldChange > 0 & wt_kd_F_sig$padj < 0.1)
- group2 <- subset(wt_kd_M_sig, wt_kd_M_sig$log2FoldChange > 0 & wt_kd_M_sig$padj < 0.1)
- ## get the overlap between the groups.
- overlap <- group1[group1$GeneID %in% group2$external_gene_name,]
- ## or get the differences between groups.
- group1only <- group1[!group1$ID %in% group2$ID,]
- group2only <- group2[!group2$ID %in% group1$ID,]
- ## and draw the Venn diagrams
- require(VennDiagram)
- grid.newpage()
- draw.pairwise.venn(nrow(group1), nrow(group2), nrow(overlap), category = c("Female DEGs", "Male DEGs"), cat.pos = c(-10,-5), fill = c("cyan", "coral2"))
- ## Gene Heatmaps
- # Load in the mouse genome annotation, if you would like to convert Ensembl IDs into gene symbols
- annotation <- read.csv2("mouse_annotation_genesOnly.csv", header = T, sep = ";")
- countingData <- as.data.frame(countingData)
- countingData$V1 <- sapply(strsplit(rownames(countingData), "\\."), "[", 1) # Only needed if there are dots in the gene IDs
- countmat <- merge(countingData, annotation, by = "V1")# Get the gene names from annotation
- colnames(countsInUse)[1]
- countsInUse <- merge(countsInUse, annotation, by = "V1")
- # To draw the most highly changing genes (the example here is with the female genes)
- subs <- subset(countmat, (countmat$V3 %in% wt_kd_F_padj$V3))
- subs <- subs[!(str_detect(subs$V3, "Gm")),] # If you want to remove the unannotated genes
- subs <- subs[,-c(1,12:13)] # Get rid of non-number columns
- df <- scale(t(subs))
- rownames(df) <- paste(sapply(strsplit(rownames(df), "_"), "[", 1), sapply(strsplit(rownames(df), "_"), "[", 2), sapply(strsplit(rownames(df), "_"), "[", 3))
- library("RColorBrewer")
- col <- colorRampPalette(brewer.pal(10, "RdYlBu"))(256)
- library(ComplexHeatmap)
- Heatmap(df[,sample(1:ncol(df),100)], # Use t(df) to transpose and cluster genes instead of samples
- name = "z-score", #title of legend
- column_title = "Genes", row_title = "Samples", cluster_columns = T, cluster_rows = F, show_column_dend = T, show_column_names = T,
- row_names_gp = gpar(fontsize = 10), column_names_gp = gpar(fontsize = 5), col = col, km = 2)
- # To get the genes/samples belonging to kmeans clusters
- km <- kmeans(t(df), centers = 2)
- kmdf <- as.data.frame(km$cluster)
- kmdf
- ##### GSEA #####
- # Helper functions
- # Arrange the DE tables in a way that can be parsed by the GSEA function
- tableCleanUp <- function(table) {
- flag <- NULL
- # Find the column with the gene names
- for (i in 1:ncol(table)) {
- if ((is.character(table[,i])) & (length(unique(table[,i])) == nrow(table))) {
- geneCol <- i
- }
- if ((is.numeric(table[,i]) & any(table[,i] < 0))) {
- log2Col <- i
- }
- if ((is.numeric(table[,i])) & all(table[,i] > 0) & all(table[,i] <= 1)) {
- flag <- c(flag, i)
- }
- }
- minMeans <- min(colMeans(table[,flag]))
- for (j in flag) {
- if (round(minMeans, digits = 3) == round(mean(table[,j]), digits = 3)) {
- pvalCol <- j
- }
- }
- padjCol <- flag[flag != pvalCol]
- clean <- table[,c(geneCol, log2Col, pvalCol, padjCol)]
- colnames(clean) <- c("Gene", "avg_log2FC","pvalue", "padj")
- return(clean)
- }
- # Main GSEA function
- cP_GSEARun <- function(DE, name, customList = tibble(), customListName = "customGeneList", ont = "BP",OrgDb = "org.Mm.eg.db", pAdjustMethod = "BH", by = "classic", cutoff = 0.5) {
- if (by == "wald") {
- geneList <- DE$stat
- }
- if (by == "classic") {
- geneList <- -log10(DE$pvalue) * sign(DE$log2FoldChange)
- }
- names(geneList) <- DE$Gene
- geneList = sort(geneList, decreasing = TRUE)
- de <- names(geneList) # Take all the DEGs
- ##Get the Entrez gene IDs associated with those symbols
- if (OrgDb == "org.Mm.eg.db") {
- EG_IDs = mget(de, revmap(org.Mm.egSYMBOL),ifnotfound=NA)
- }
- if (OrgDb == "org.Rn.eg.db") {
- EG_IDs = mget(de, revmap(org.Rn.egSYMBOL),ifnotfound=NA)
- }
- if (nrow(customList) == 0) {
- names(geneList) <- (EG_IDs)
- gL <- geneList
- nodups <- gL[!(duplicated(names(gL)))]
- gse <- gseGO(geneList=nodups,
- ont = ont,
- keyType = "ENTREZID",
- pvalueCutoff = cutoff,
- OrgDb = OrgDb,
- pAdjustMethod = pAdjustMethod, nPermSimple = 10000,
- verbose = F)
- name <- paste(ont, "_", name, sep = "")
- }
- else {
- gL <- geneList
- nodups <- gL[!(duplicated(names(gL)))]
- gse <- GSEA(nodups, TERM2GENE = customList, nPermSimple = 10000,
- pvalueCutoff = cutoff, pAdjustMethod = pAdjustMethod)
- name <- paste(customListName, "_", name, sep = "")
- }
- results <- gse@result
- write.csv(results, file = paste("GSEAGO_", name, ".csv",sep = ""))
- if (nrow(results) == 0) {
- return()
- }
- clusterProfiler::dotplot(gse, showCategory=10, split = ".sign", font.size = 5, x = "NES") + facet_grid(.~.sign)
- ggsave(filename = paste("Dotplot_ActivatedSuppressed_", name, ".pdf", sep = ""), width = 8, height = 6, onefile = F)
- clusterProfiler::dotplot(gse, color = "p.adjust", x = "NES", showCategory=10, font.size = 5)
- ggsave(filename = paste("Dotplot_bypadj_", name, ".pdf", sep = ""), width = 8, height = 6, onefile = F)
- # simp <- clusterProfiler::simplify(gse, 0.7)
- #
- # clusterProfiler::dotplot(simp, showCategory=15, split = ".sign", font.size = 10) + facet_grid(.~.sign)
- # clusterProfiler::dotplot(gse, color = "NES", x = "p.adjust", showCategory=15)
- emp <- pairwise_termsim(gse)
- emapplot(emp, showCategory = 30)
- ggsave(filename = paste("EmapPlot_",name, ".pdf", sep = ""), width = 8, height = 6, onefile = F)
- count <- ifelse(nrow(results) < 10, yes = nrow(results), no = 10)
- for (j in 1:count) {
- pdf(file = paste("GSEAplot_","_Rank", j, "_", name, ".pdf", sep = ""))
- print(gseaplot2(gse, geneSetID = j, title = gse$Description[j], pvalue_table = T))
- dev.off()
- }
- }
- # Example run: Make sure that the DE list contains ALL assessed genes; no pval cutoffs should be utilized for GSEA!!
- clean <- tableCleanUp(DElist)
- cP_GSEARun(DE = clean, name = "M_KDvCtrl" , OrgDb = "org.Mm.eg.db", ont = "BP", pAdjustMethod = "BH", cutoff = 0.1, by = "classic")
Chioinoetal_2026_DESeq2_and_GSEA.R, under CC-BY-4.0 · at the source
Overview
- Laboratory of Behavioral Genetics, Brain Mind Institute, School of Life Sciences, Ecole Polytechnique Fédérale de Lausanne, Lausanne 1015, Switzerland
- Synapsy Center for Neuroscience and Mental Health Research, School of Life Sciences, Ecole Polytechnique Fédérale de Lausanne, Lausanne 1015, Switzerland
- Regeneration and Neurogenomics Laboratory, Brain Mind Institute, School of Life Sciences, Ecole Polytechnique Fédérale de Lausanne, Lausanne 1015, Switzerland
- Institut de Neurociències, Universitat Autònoma de Barcelona, Bellaterra 08193, Spain
- Departament de Biologia Cellular, Fisiologia i Immunologia, Universitat Autònoma de Barcelona, Barcelona 08193, Spain
- Focus Area for Human Metabolomics, Faculty of Natural and Agricultural Sciences, North-West University, Potchefstroom 2520, South Africa
Abstract
Effort-based motivation varies widely across individuals and affects well-being, yet the molecular and neuronal mechanisms that set motivational capacity remain incompletely understood. Mitochondrial function is emerging as a critical regulator of behavior, and mitofusin-2 (MFN2) is a key mediator of mitochondrial fusion and endoplasmic reticulum–mitochondria coupling. Here, we asked how downregulation of Mfn2 in dopamine receptor type-1-expressing medium spiny neurons (D1-MSNs) contributes to effort-based motivation and stress coping in male and female mice by integrating electrophysiology, neuronal and synaptic morphology, immunohistochemistry, mitochondrial readouts, RNA in situ hybridization, RiboTag, and behavioral analyses. MFN2 deficiency resulted in fragmented dendritic mitochondria and remodeled synaptic inputs in ventral striatal D1-MSNs, with no cellular impact in dorsomedial striatal D1-MSNs. Although MFN2 deficiency elicited sex-dependent synaptic and structural alterations, both sexes showed reduced recruitment of accumbal D1-MSNs during motivated behavior and impaired effort-based motivation and stress coping. Translatome profiling revealed shared depletion of mitochondrial pathways in both sexes, with more pronounced suppression of oxidative phosphorylation and TCA cycle programs in males. Strikingly, only males also exhibited coordinated downregulation of ribosomal programs together with enrichment of synaptic pathways, with high representation of genes regulating glutamate receptor cycling and PSD remodeling, providing a mechanistic framework for the observed synaptic alterations. Pathway-level network inference further supported coupling among mitochondrial, translational, and synaptic programs in males. These findings identify MFN2-dependent mitochondrial integrity in ventral striatal D1-MSNs as a critical determinant of motivational capacity and reveal sex-specific molecular and cellular responses through which mitochondrial dysfunction converges on similar motivational deficits.
Reproduced under the paper's license (CC BY), from the paper cited above.
Repository
Its files are read in the Code ↔ Paper reader above.
figshare 32252133
Availability: 1 check, the latest on 27 September 2026: the link answers (HTTP 200)
- 27 September 2026: the link answers (HTTP 200)
2 files
- Chioinoetal_2026_DESeq2_
and_GSEA.R — R, 460 lines - Chioinoetal_2026_Pathway
Networks.R — R, 612 lines
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;
- 2 scripts, each with its path and the digest of its content;
- no match between paragraphs and code yet;
- 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, Materials, and Software Availability
Source data for all figures, RiboTag sequencing data, full tables from the bioinformatics analyses, and the R scripts used for the analyses are publicly accessible in Figshare (https://
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, 9 authors, 3 keywords, 12 MeSH terms, 2 funders, 112 references, 1 integrity notice.
Cite
This paper
Chioino, A., Ulgen, D. H., Zanoletti, O., Guillot de Suduiraut, I., Maynard, A. M., Sanz, E., Quintana, A., Astori, S., & Sandi, C. (2026). Mitofusin-2 in ventral striatal D1 neurons regulates effort-based motivation through sex-specific mitochondrial-synaptic reprogramming. Proceedings of the National Academy of Sciences of the United States of America, 123(29), e2601657123. https://
BibTeX
@article{chioino2026mito
author = {Chioino, Alessandro and Ulgen, Dogukan H and Zanoletti, Olivia and Guillot de Suduiraut, Isabelle and Maynard, Ashley M and Sanz, Elisenda and Quintana, Albert and Astori, Simone and Sandi, Carmen},
title = {{Mitofusin-2 in ventral striatal D1 neurons regulates effort-based motivation through sex-specific mitochondrial-synaptic reprogramming}},
journal = {Proceedings of the National Academy of Sciences of the United States of America},
year = {2026},
month = jul,
volume = {123},
number = {29},
pages = {e2601657123},
publisher = {National Academy of Sciences},
issn = {0027-8424},
doi = {10.1073/
url = {https://
pmid = {42455671},
pmcid = {PMC13389689}
}
RIS
TY - JOUR
AU - Chioino, Alessandro
AU - Ulgen, Dogukan H
AU - Zanoletti, Olivia
AU - Guillot de Suduiraut, Isabelle
AU - Maynard, Ashley M
AU - Sanz, Elisenda
AU - Quintana, Albert
AU - Astori, Simone
AU - Sandi, Carmen
TI - Mitofusin-2 in ventral striatal D1 neurons regulates effort-based motivation through sex-specific mitochondrial-synaptic reprogramming
T2 - Proceedings of the National Academy of Sciences of the United States of America
J2 - Proc Natl Acad Sci U S A
PY - 2026
DA - 2026/
VL - 123
IS - 29
SP - e2601657123
SN - 0027-8424
PB - National Academy of Sciences
DO - 10.1073/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.1073/
"type": "article-journal",
"title": "Mitofusin-2 in ventral striatal D1 neurons regulates effort-based motivation through sex-specific mitochondrial-synaptic reprogramming",
"container-title": "Proceedings of the National Academy of Sciences of the United States of America",
"author": [
{
"family": "Chioino",
"given": "Alessandro"
},
{
"family": "Ulgen",
"given": "Dogukan H"
},
{
"family": "Zanoletti",
"given": "Olivia"
},
{
"family": "Guillot de Suduiraut",
"given": "Isabelle"
},
{
"family": "Maynard",
"given": "Ashley M"
},
{
"family": "Sanz",
"given": "Elisenda"
},
{
"family": "Quintana",
"given": "Albert"
},
{
"family": "Astori",
"given": "Simone"
},
{
"family": "Sandi",
"given": "Carmen"
}
],
"container-title-short":
"volume": "123",
"issue": "29",
"page": "e2601657123",
"DOI": "10.1073/
"PMID": "42455671",
"PMCID": "PMC13389689",
"ISSN": "0027-8424",
"publisher": "National Academy of Sciences",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
7,
15
]
]
}
}
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.1038/s42003-026-10957-8 [code]
- Brain defence by the extracellular matrix protein Cochlin.Journal: Communications biologyIn common: DESeq2, igraph, clusterProfiler, 5 other tools, mouse, cellular / molecular
- [2] doi:10.1002/imt2.70163 [code]
- Spatial multi-omics unveils sphingolipid metabolic reprogramming within the retinal pathological niche.Journal: iMetaIn common: DESeq2, igraph, clusterProfiler, 5 other tools, mouse, cellular / molecular
- [3] doi:10.1038/s41380-026-03629-w [code]
- Maternal fasting during early gestation induces epigenetic alterations and schizophrenia-related phenotypes.Journal: Molecular psychiatryIn common: DESeq2, igraph, clusterProfiler, 5 other tools, mouse, cellular / molecular
- [4] doi:10.1038/s41593-026-02367-0 [code]
- A reproducible three-dimensional model of human brain tissue to investigate physiological and disease-associated microglia phenotypes.Journal: Nature neuroscienceIn common: DESeq2, igraph, clusterProfiler, 5 other tools, cellular / molecular
- [5] doi:10.1038/s41386-026-02406-1 [code]
- Functional genomic profiling of schizophrenia-associated
genes reveals key microglial regulators. Journal: Neuropsychopharmacology : official publication of the American College of NeuropsychopharmacologyIn common: DESeq2, igraph, clusterProfiler, 4 other tools, cellular / molecular, 1 reference - [6] doi:10.1093/bioinformatics/btag592 [code]
- Network-based stratification of allele-specific expression reveals patient subgroups in Huntington's disease.Journal: Bioinformatics (Oxford, England)In common: DESeq2, igraph, clusterProfiler, 5 other tools
- [7] doi:10.1038/s44318-026-00806-z [code]
- Interspecific diversity in the neuronal composition of the mammalian cortex arises from heterochrony in neurogenesis.Journal: The EMBO journalIn common: DESeq2, igraph, clusterProfiler, 5 other tools
- [8] doi:10.1016/j.isci.2026.115657 [code]
- Integration of machine learning to develop a disulfidptosis model for predicting glioma prognosis, immunotherapy response, and drug.Journal: iScienceIn common: DESeq2, igraph, clusterProfiler, 5 other tools
- [9] doi:10.1038/s41593-026-02300-5 [code]
- Integrated single-cell and spatial transcriptomic profiling in ALS uncovers peripheral-to-central immune infiltration and reprogramming.Journal: Nature neuroscienceIn common: DESeq2, igraph, ComplexHeatmap, 4 other tools, cellular / molecular, 1 reference
- [10] doi:10.1371/journal.pcbi.1014573 [code]
- Cell-type-specific m1A dynamics are associated with microglial phenotypic transition and neuronal metabolic adaptation during spinal cord injury.Journal: PLoS computational biologyIn common: DESeq2, igraph, clusterProfiler, 4 other tools, mouse, cellular / molecular
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, 2 scripts, and 0 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:c185eb7616b42f07…
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.
