Note
This page is a reference documentation. It only explains the function signature, and not how to use it. Please refer to the user guide for the big picture.
nilearn.datasets.fetch_adhd¶
- nilearn.datasets.fetch_adhd(n_subjects=30, data_dir=None, url=None, resume=True, verbose=1)[source]¶
Download and load the ADHD resting-state dataset.
- Parameters:
- n_subjects
int, default=30 The number of subjects to load from maximum of 40 subjects. By default, 30 subjects will be loaded. If None is given, all 40 subjects will be loaded.
- data_dir
pathlib.Pathorstror None, optional Path where data should be downloaded. By default, files are downloaded in a
nilearn_datafolder in the home directory of the user. See alsonilearn.datasets.utils.get_data_dirs.- url
stror None, default=None URL of file to download. Override download URL. Used for test only (or if you setup a mirror of the data).
- resume
bool, default=True Whether to resume download of a partly-downloaded file.
- verbose
boolorint, default=1 Verbosity level (
0orFalsemeans no message).
- n_subjects
- Returns:
- data
sklearn.utils.Bunch Dictionary-like object, the interest attributes are :
- ‘func’:
Paths to functional resting-state images
- ‘phenotypic’: pd.dataframe
explanations of preprocessing steps
- ‘confounds’:
CSV files containing the nuisance variables
- ‘t_r’:
float Repetition time of the functional data.
- ‘t_r’:
- data
Notes
If the dataset files are already present in the user’s Nilearn data directory, this fetcher will not re-download them. To force a fresh download, you can remove the existing dataset folder from your local Nilearn data directory.
For more details on how Nilearn stores datasets.
See Nitrc ADHD resting-state dataset[1].
References