Skip to content

Commit 2642a8a

Browse files
committed
allow for passing in figsize model plots
1 parent f9b6e7e commit 2642a8a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

fooof/plts/fg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def plot_fg(fg, save_fig=False, file_name=None, file_path=None, **plot_kwargs):
4343
if not fg.has_model:
4444
raise NoModelError("No model fit results are available, can not proceed.")
4545

46-
fig = plt.figure(figsize=PLT_FIGSIZES['group'])
46+
fig = plt.figure(figsize=plot_kwargs.pop('figsize', PLT_FIGSIZES['group']))
4747
gs = gridspec.GridSpec(2, 2, wspace=0.4, hspace=0.25, height_ratios=[1, 1.2])
4848

4949
# Apply scatter kwargs to all subplots

fooof/plts/fm.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ def plot_fm(fm, plot_peaks=None, plot_aperiodic=True, plt_log=False, add_legend=
6262
the y-axis (power) is plotted in log spacing by default.
6363
"""
6464

65-
ax = check_ax(ax, PLT_FIGSIZES['spectral'])
65+
ax = check_ax(ax, plot_kwargs.pop('figsize', PLT_FIGSIZES['spectral']))
6666

6767
# Log settings - note that power values in FOOOF objects are already logged
6868
log_freqs = plt_log

0 commit comments

Comments
 (0)