Skip to content

Commit e68aed7

Browse files
jhlegarretaeffigies
authored andcommitted
DOC: Add missing parameter documentation to carpet plot function
Add missing parameter documentation to carpet plot function. Avoid using ``None`` as the default value for the font size parameter, and set it to the default value that is effectively used in the function body.
1 parent 0f34531 commit e68aed7

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

nireports/reportlets/nuisance.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ def plot_carpet(
239239
sort_rows="ward",
240240
drop_trs=0,
241241
legend=True,
242-
fontsize=None,
242+
fontsize=24,
243243
):
244244
"""
245245
Plot an image representation of voxel intensities across time.
@@ -278,7 +278,14 @@ def plot_carpet(
278278
:obj:`scipy.cluster.hierarchy.linkage`.
279279
Any other value that Python evaluates to ``True`` will use the
280280
default clustering, which is :obj:`sklearn.cluster.ward_tree`.
281-
281+
drop_trs: :obj:`int`, optional
282+
Number of initial timepoints ("dummy scans"”" / non–steady-state volumes)
283+
to ignore at the beginning of a timeseries when computing display
284+
scaling and potentially other plot-derived stats.
285+
legend : :obj:`bool`, optional
286+
``True`` to plot the legend.
287+
fontsize : :obj:`int`, optional
288+
Font size.
282289
"""
283290
if segments is None:
284291
segments = {"whole brain (voxels)": list(range(data.shape[0]))}
@@ -346,8 +353,6 @@ def plot_carpet(
346353
ax.get_xaxis().set_visible(False)
347354
ax.get_yaxis().set_visible(False)
348355

349-
fontsize = fontsize or 24
350-
351356
# Length before decimation
352357
n_trs = data.shape[-1]
353358

0 commit comments

Comments
 (0)