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.

8.10.23. nilearn.plotting.plot_design_matrix

nilearn.plotting.plot_design_matrix(design_matrix, rescale=True, ax=None, output_file=None)

Plot a design matrix provided as a DataFrame

Parameters:

design matrix : pandas DataFrame,

Describes a design matrix.

rescale : bool, optional

Rescale columns magnitude for visualization or not.

ax : axis handle, optional

Handle to axis onto which we will draw design matrix.

output_file : string or None, optional,

The name of an image file to export the plot to. Valid extensions are .png, .pdf, .svg. If output_file is not None, the plot is saved to a file, and the display is closed.

Returns:

ax: axis handle

The axis used for plotting.