TimeseriesExtractor.visualize_bold#
- TimeseriesExtractor.visualize_bold(subj_id, run=None, roi_indx=None, region=None, show_figs=True, output_dir=None, filename=None, as_pickle=False, **kwargs)[source]#
Plot the Extracted Subject Timeseries.
Visualize the extracted BOLD timeseries data of nodes (Region-of-Interests [ROIs]) or regions (anatomical regions/networks) for a specific subject and run.
- Parameters:
subj_id (
strorint) – The ID of the subject.run (
int,str, orNone, default=None) – The run ID of the subject to plot. Must be specified if multiple runs exist for a given subject.roi_indx (
int,str,list[int],list[int]orNone, default=None) – The indices of the parcellation nodes to plot. See “nodes” inself.parcel_approachfor valid nodes.region (
strorNone, default=None) – The region of the parcellation to plot. If not None, all nodes in the specified region will be averaged then plotted. See “regions” inself.parcel_approachfor valid region.show_figs (
bool, default=True) – Display figures.output_dir (
strorNone, default=None) – Directory to save plot as png image. The directory will be created if it does not exist. If None, plot will not be saved.filename (
strorNone, default=None) – Name of the file without the extension.as_pickle (
bool, default=False) –When
output_diris specified, plots are saved as pickle file, which can be further modified, instead of png images.Added in version 0.26.5.
**kwargs –
Keyword arguments used when saving figures. Valid keywords include:
dpi:
int, default=300 – Dots per inch for the figure.figsize:
tuple, default=(11, 5) – Size of the figure in inches.bbox_inches:
strorNone, default=”tight” – Alters size of the whitespace in the saved image.
- Returns:
self
Note
Parcellation Approach: the “nodes” and “regions” subkeys are required in
parcel_approach.