Emotion regulation success involves systematic gradient-based reconfigurations of large-scale activation patterns in the human brain.
One block of code here has a permanent identifier (oscr:b:…), listed with the matches below: citable for good, with a page of its own. Select a match and press Cite to copy it. What a block identifier is.
The 2 matches
- [1] § Materials and methods › Neurosynth functional decoding ↔ Code/Neurosynth_Decoding/Neurosynth_Functional_Decoding.ipynb, lines 35 to 50 · score 0.60 · Neurosynth database, functional decoding, NiMARE · Report a mismatch
- [2] § Materials and methods › Gradient analysis › Out-of-sample predictions. ↔ Code/LMM/Cross-sample_Validation.R, lines 1 to 52 · score 0.60 · cross sample, joint sample, validation, lmer, trained, correlating · block
oscr:b:ZDE55F06K5M3A-7· Report a mismatch
Paper
Loaded from Europe PMC by your browser; OSCR does not store it: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
Jupyter notebook · 211 lines · 6.8 KB · no license · 1 match
- # %% [markdown]
- # ## ER gradient Neurosynth Meta-Analytic Functional Decoding
- # %%
- import os
- import pickle
- import pandas as pd
- import numpy as np
- from wordcloud import WordCloud
- import matplotlib.pyplot as plt
- from matplotlib import font_manager as fm
- from pprint import pprint
- from nimare.extract import download_abstracts, fetch_neurosynth
- from nimare.io import convert_neurosynth_to_dataset
- from nimare import decode, meta
- out_dir = os.path.abspath("")
- os.makedirs(out_dir, exist_ok=True)
- # %% [markdown]
- # ### Downlaod Neurosynth database
- # %%
- # Fetch Neurosynth with *just* the LDA50 features
- files = fetch_neurosynth(
- data_dir=out_dir,
- version="7",
- overwrite=True,
- source="abstract",
- vocab="LDA50", # LDA 100, 200 , or term
- )
- neurosynth_db = files[0]
- pprint(neurosynth_db)
- # %% [markdown]
- # ### Convert Neurosynth database to NiMARE dataset file
- # %%
- # Get the Dataset object
- neurosynth_dset = convert_neurosynth_to_dataset(
- coordinates_file=neurosynth_db["coordinates"],
- metadata_file=neurosynth_db["metadata"],
- annotations_files=neurosynth_db["features"],
- )
- neurosynth_dset.save(os.path.join(out_dir, 'neurosynth',"neurosynth_dataset_LDA50.pkl.gz"))
- print(neurosynth_dset)
- neurosynth_dset = download_abstracts(neurosynth_dset, "[email hidden]")
- neurosynth_dset.save(os.path.join(out_dir, 'neurosynth' ,"neurosynth_dataset_LDA50_with_abstracts.pkl.gz"))
- # %% [markdown]
- # ### Feature selection
- # %%
- id_cols = ["id", "study_id", "contrast_id"]
- frequency_threshold = 0.001
- cols = neurosynth_dset.annotations.columns
- cols = [c for c in cols if c not in id_cols]
- df = neurosynth_dset.annotations.copy()[cols]
- n_studies = df.shape[0]
- feature_counts = (df >= frequency_threshold).sum(axis=0)
- target_features = feature_counts.between(n_studies * 0.1, n_studies * 0.9)
- target_features = target_features[target_features]
- target_features = target_features.index.values
- print(f"{len(target_features)} features selected.", flush=True)
- # %% [markdown]
- # ### Decoding continuous map
- # %%
- corr_decoder = decode.continuous.CorrelationDecoder(
- frequency_threshold=0.001,
- meta_estimator = meta.cbma.mkda.MKDAChi2(),
- features=target_features)
- corr_decoder.fit(neurosynth_dset)
- # save the correlation decoder
- with open(os.path.join(out_dir, 'neurosynth',"corr_decoder.pkl"), "wb") as file:
- pickle.dump(corr_decoder, file)
- # %%
- map = {'er_beta': "../Data/Unthresholded_Tmaps/RS_Covariate_unthresholded_Tmap.nii.gz",
- 'grad1' : "../Gradients_Map/volume.all.0.nii.gz",
- 'grad2' : "../Gradients_Map/volume.all.1.nii.gz",
- 'grad3' : "../Gradients_Map/volume.all.2.nii.gz",
- 'grad4' : "../Gradients_Map/volume.all.3.nii.gz",
- 'grad5' : "../Gradients_Map/volume.all.4.nii.gz"}
- with open(os.path.join(out_dir, 'neurosynth',"corr_decoder.pkl"), "rb") as file:
- corr_decoder = pickle.load(file)
- corr_df = {}
- for i in map.keys():
- corr_df[i] = corr_decoder.transform(map[i])
- lda50_keys = pd.read_csv(os.path.join(out_dir, 'neurosynth', 'LDA50_keys.csv')).loc[:,['idx','key']]
- def match_corr_df(corr_df, lda_keys):
- ## Sort the df based on r score
- corr_df_sorted = corr_df.reindex(corr_df["r"].abs().sort_values(ascending=False).index)
- corr_df_sorted['feature'] = corr_df_sorted.index
- corr_df_sorted = corr_df_sorted.reset_index(drop=True)
- for index, row in corr_df_sorted.iterrows():
- idx = row['feature'].split('_')[4]
- corr_df_sorted.loc[index,'idx'] = int(idx)
- ## merge the correlation df with the keywords
- dff = pd.merge(corr_df_sorted, lda_keys, on='idx')
- ## Delete the rows with the method-related keywords
- dff = dff.dropna().reset_index(drop=True)
- return dff
- dff_dict = {}
- for i in corr_df.keys():
- dff_dict[i] = match_corr_df(corr_df[i], lda50_keys)
- dff_dict[i].to_csv(os.path.join(out_dir, f'{i}_decoding_frequency.csv'), index=False)
- # %%
- key_list = pd.read_csv(os.path.join(out_dir, 'neurosynth', 'LDA50_keys_4table.csv'))['key'].to_list()
- dff_list = []
- for i in dff_dict.keys():
- df = dff_dict[i].loc[:,['r','key']]
- df = df.set_index('key')
- df = df.rename(columns={"r": f"{i}_r"})
- dff = df.reindex(key_list)
- dff_list.append(dff)
- df_all = pd.concat(dff_list, axis=1)
- df_all.to_csv(os.path.join(out_dir, 'functional_decoding_summary.csv'), index=True)
- # %% [markdown]
- # ## Radar plot
- # %%
- df1 = dff_dict['grad1'].loc[:,['key','r']]
- df1.columns = ['key', 'grad1_r']
- df2 = dff_dict['er_beta'].loc[:,['key','r']]
- df2.columns = ['key', 'er_r']
- dff = pd.merge(df1, df2, on='key')
- key_radar = dff['key'].to_list()
- dff_list = []
- for i in dff_dict.keys():
- df = dff_dict[i].loc[:,['r','key']]
- df = df.set_index('key')
- df = df.rename(columns={"r": f"{i}_r"})
- dff = df.reindex(key_radar)
- dff_list.append(dff)
- df_radar = pd.concat(dff_list, axis=1)
- # %%
- def decoding_radar_plot(df_decoding, map1, map2, map1_legend, map2_legend, label=True):
- categories=df_decoding.index.to_list()
- N = 25
- # We are going to plot the first line of the data frame.
- # But we need to repeat the first value to close the circular graph:
- value1=df_decoding[map1].to_list()
- value1 += value1[:1]
- value1
- value2=df_decoding[map2].to_list()
- value2 += value2[:1]
- value2
- # What will be the angle of each axis in the plot? (we divide the plot / number of variable)
- angles = [n / float(N) * 2 * np.pi for n in range(N)]
- angles += angles[:1]
- # Initialise the spider plot
- plt.figure(figsize=(8, 8))
- fig, ax = plt.subplots(figsize=(6, 6), subplot_kw=dict(polar=True))
- # Plot two map
- ax.fill(angles, value1, color='#7F7F7F', alpha=0.5, label=map1_legend)
- ax.plot(angles, value1, color='#4A4A4A', alpha=0.6, linewidth=1)
- ax.fill(angles, value2, color='#9ACD32', alpha=0.6, label=map2_legend)
- ax.plot(angles, value2, color='#6B8E23', alpha=0.6,linewidth=1)
- # Draw one axe per variable + add labels
- if label:
- plt.xticks(angles[:-1], categories, color='black', size=8,fontdict={'family':'Arial', 'size':10} )
- else:
- plt.xticks(angles[:-1], [], color='black', size=8,fontdict={'family':'Arial', 'size':10} )
- # Draw ylabels
- ax.set_rlabel_position(0)
- plt.yticks([-0.5,0,0.5], ['','0',''], color="grey", size=7)
- plt.ylim(-0.5,0.5)
- legend_font = fm.FontProperties(family='Arial', size=15)
- ax.legend(loc='center left', bbox_to_anchor=(1, 1.05), prop=legend_font)
- # Show the graph
- #plt.show()
- return fig
- # %%
- decoding_radar_plot(df_radar, 'grad1_r', 'er_beta_r', 'Gradient 1 Map', 'Regulatory success (RS)\ncovariate map', True)
- # %%
- for i in [1,2,3,4,5]:
- fig = decoding_radar_plot(df_radar, f'grad{str(i)}_r', 'er_beta_r', f'Gradient {str(i)} Map', 'RS covariate map', False)
- fig.savefig(f'D:/0_ER_Gradient/Manuscript/plots/raw/func_decoding_rada_grad{str(i)}.png',bbox_inches='tight',dpi=900,pad_inches=0.1,transparent=False)
Neurosynth_Functional_Decoding.ipynb, no license · at the source
Overview
- Department of Psychology, Queen’s University, Kingston, Canada
- Institut des Sciences Cognitives Marc Jeannerod, UMR-5229 CNRS, Bron, France
- Department of Psychology, University of Innsbruck, Innsbruck, Austria
- Center for Neuroscience Studies, Queen’s University, Kingston, Canada
Abstract
Emotion regulation is essential for well-being and mental health, yet individuals vary widely in their emotion regulation success. Why? Traditional neuroimaging studies of emotion regulation often focus on localized neural activity or isolated networks, overlooking how large-scale brain organization relates to the integration of distributed systems and sub-processes supporting regulatory success. Here, we applied a novel system-level framework based on spatial gradients of macroscale brain organization to study variance in emotion regulation success. Using two large functional magnetic resonance imaging (fMRI) datasets (n = 358, n = 263), we projected global activation patterns from a laboratory emotion regulation task onto principal gradients derived from independent resting-state fMRI data from the Human Connectome Project. These gradients capture low-dimensional patterns of neural variation, providing a topographical framework within which complex mental phenomena, such as emotion regulation, emerge. In both datasets, individual differences in regulation success were associated with systematic reconfiguration along Gradient 1—a principal axis differentiating unimodal and heteromodal brain areas. This gradient-based neural reconfiguration also associates with lower negative affect in daily life, as measured via smartphone-based experience sampling in a subset of participants (n = 55). Meta-analytic decoding via Neurosynth revealed that Gradient 1 and regulation success align with multiple psychological processes, including social cognition, memory, attention, and negative emotion, suggesting this gradient reflects diverse, integrative demands during effective emotion regulation. These findings introduce a gradient-based perspective on emotion regulation success that is biologically grounded in well-established large-scale brain organization and ecologically valid through its links with real-world emotional experience. Such gradient-based dynamics may serve as predictive biomarkers of regulatory success and inform targeted interventions in clinical populations.
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 yk85c
Availability: 1 check, the latest on 28 September 2026: the link answers (HTTP 200)
- 28 September 2026: the link answers (HTTP 200)
5 files
- Code/
Gradient/ , Jupyter, 302 linesGradient_Analysis.ipynb - Code/
Gradient/ , Python, 128 linesgradient_utilities.py - Code/
LMM/ , R, 142 lines, 1 matchCross-sample_Validation. R - Code/
LMM/ , R, 149 linesLMM_Gradient_ReapraisalS uccess.R - Code/
Neurosynth_Decoding/ , Jupyter, 211 lines, 1 matchNeurosynth_Functional_De coding.ipynb
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;
- 5 scripts, 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
Datasets cited
- github.com/
neurosynth/ , at github.com; found in the text, “Neurosynth functional decoding”neurosynth-data - neurovault.org/
collections/ , at neurovault.org; found in the text, “MRI data analysis”16266
Data Availability
Relevant data and analysis code supporting the key findings of this study have been made available on the Open Science Framework (OSF, 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, 28 September 2026: the first record
Recorded: type, language, journal, volume, issue, pages, dates, 4 authors, 11 MeSH terms, 2 funders, 96 references, 1 integrity notice.
Cite
This paper
Wang, R., Janet, R., Morawetz, C., & Tusche, A. (2026). Emotion regulation success involves systematic gradient-based reconfigurations of large-scale activation patterns in the human brain. PLoS biology, 24(4), e3003666. https://
BibTeX
@article{wang2026emotion
author = {Wang, Ruien and Janet, Remi and Morawetz, Carmen and Tusche, Anita},
title = {{Emotion regulation success involves systematic gradient-based reconfigurations of large-scale activation patterns in the human brain}},
journal = {PLoS biology},
year = {2026},
month = apr,
volume = {24},
number = {4},
pages = {e3003666},
publisher = {PLOS},
issn = {1544-9173},
doi = {10.1371/
url = {https://
pmid = {41926350},
pmcid = {PMC13046165}
}
RIS
TY - JOUR
AU - Wang, Ruien
AU - Janet, Remi
AU - Morawetz, Carmen
AU - Tusche, Anita
TI - Emotion regulation success involves systematic gradient-based reconfigurations of large-scale activation patterns in the human brain
T2 - PLoS biology
J2 - PLoS Biol
PY - 2026
DA - 2026/
VL - 24
IS - 4
SP - e3003666
SN - 1544-9173
PB - PLOS
DO - 10.1371/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.1371/
"type": "article-journal",
"title": "Emotion regulation success involves systematic gradient-based reconfigurations of large-scale activation patterns in the human brain",
"container-title": "PLoS biology",
"author": [
{
"family": "Wang",
"given": "Ruien"
},
{
"family": "Janet",
"given": "Remi"
},
{
"family": "Morawetz",
"given": "Carmen"
},
{
"family": "Tusche",
"given": "Anita"
}
],
"container-title-short":
"volume": "24",
"issue": "4",
"page": "e3003666",
"DOI": "10.1371/
"PMID": "41926350",
"PMCID": "PMC13046165",
"ISSN": "1544-9173",
"publisher": "PLOS",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
4,
2
]
]
}
}
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/s41467-026-70708-5 [code]
- Common and distinct neurofunctional signatures of dynamic naturalistic emotion regulation strategies.Journal: Nature communicationsIn common: seaborn, pandas, Matplotlib, neurovault.org/collections/16266, cognitive, 17 references
- [2] doi:10.1162/imag_a_00081 [code]
- Methods for decoding cortical gradients of functional connectivity.Journal: Imaging neuroscience (Cambridge, Mass.)In common: NiMARE, Nilearn, NiBabel, 6 other tools, github.com/neurosynth/neurosynth-data, fMRI, 11 references
- [3] doi:10.1038/s44271-025-00184-y [code]
- Self-reports map the landscape of task states derived from brain imaging.Journal: Communications psychologyIn common: easystats, emmeans, lmerTest, 12 other tools, fMRI, cognitive, 7 references
- [4] doi:10.1038/s41598-023-48857-0 [code]
- Experience sampling reveals the role that covert goal states play in task-relevant behavior.Journal: Scientific reportsIn common: easystats, emmeans, lmerTest, 12 other tools, cognitive, 7 references
- [5] doi:10.1038/s41467-024-48015-8 [code]
- Information-based TMS to mid-lateral prefrontal cortex disrupts action goals during emotional processing.Journal: Nature communicationsIn common: emmeans, lmerTest, Nilearn, 10 other tools, 7 references
- [6] doi:10.1162/netn_a_00382 [code]
- Comparison of different group-level templates in gradient-based multimodal connectivity analysis.Journal: Network neuroscience (Cambridge, Mass.)In common: NiMARE, Nilearn, statsmodels, 7 other tools, 8 references
- [7] doi:10.1038/s41598-025-86762-w [code]
- Individual differences in wellbeing are supported by separable sets of co-active self- and visual-attention-related
brain networks. Journal: Scientific reportsIn common: NiMARE, Nilearn, statsmodels, 7 other tools, fMRI, cognitive, 6 references - [8] doi:10.1093/scan/nsad050
- Unpacking reappraisal: a systematic review of fMRI studies of distancing and reinterpretation.Journal: Social cognitive and affective neuroscienceIn common: fMRI, cognitive, 12 references
- [9] doi:10.1002/advs.202504956 [code]
- Spatiotemporal Characterization of the Functional MRI Latency Structure with Respect to Neural Signaling and Brain Hierarchy.Journal: Advanced science (Weinheim, Baden-Wurttemberg, Germany)In common: NiMARE, Nilearn, statsmodels, 7 other tools, fMRI, 6 references
- [10] doi:10.1073/pnas.2116673119 [code]
- Adolescent development of multiscale structural wiring and functional interactions in the human connectome.Journal: Proceedings of the National Academy of Sciences of the United States of AmericaIn common: Nilearn, statsmodels, NiBabel, 8 other tools, 7 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, 5 scripts, 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:1659a8c4b462aa18…
Add the badge to the code's README
If you are an author or a maintainer of this paper's code, you can add this badge. It says what OSCR knows of the paper (its code, its validated tracing map) and links the code to this page. Paste one of these snippets under the README's title. Keep the two marks around it, so that the badge can be replaced in place and is never added twice. OSCR changes nothing in your repository.
Markdown
<!-- oscr-badge:start -->
[](https://openscicode.org/badge/doi/10.1371/journal.pbio.3003666)
<!-- oscr-badge:end -->reStructuredText
.. oscr-badge:start
.. image:: https://openscicode.org/badge/doi/10.1371/journal.pbio.3003666.svg
:target: https://openscicode.org/badge/doi/10.1371/journal.pbio.3003666
:alt: OSCR
.. oscr-badge:endHTML
<!-- oscr-badge:start -->
<a href="https://openscicode.org/badge/doi/10.1371/journal.pbio.3003666"><img src="https://openscicode.org/badge/doi/10.1371/journal.pbio.3003666.svg" alt="OSCR"></a>
<!-- oscr-badge:end -->If you choose to, you can have the badge kept up to date for you, with oscr badge --write from the command line or with the GitHub Action in your repository's workflows. Every other form and option (a card, AsciiDoc, LaTeX, shields.io) is on the badge page.
Request its removal
To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).
Discussion, reproductions, activity
Discussion: code errors and mismatches between the code and the paper about this paper and its code, from readers and its authors, beside the paper and its tracing map.
Report a mismatch between the code and the paper · Report a code error (signed in)
Reproductions: reports from readers who ran the authors' code and did not get the paper's result, what they ran, with which environment, commit and data.
Report a reproduction failure (signed in)
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
