votes up 1

Layout of (nrows)x(ncols) must be larger than required size (nplots)

Package:
pandas
github stars 30911
Exception Class:
ValueError

Raise code

 ncols == -1 and nrows > 0:
            layout = nrows, ncols = (nrows, ceil(nplots / nrows))
        elif ncols <= 0 and nrows <= 0:
            msg = "At least one dimension of layout must be positive"
            raise ValueError(msg)

        if nrows * ncols < nplots:
            raise ValueError(
                f"Layout of {nrows}x{ncols} must be larger than required size {nplots}"
            )

        return layout

    if layout_type == "single":
        return (1, 1)
    elif lay
😲  Walkingbet is Android app that pays you real bitcoins for a walking. Withdrawable real money bonus is available now, hurry up! 🚶

Ways to fix

votes up 2 votes down

df_to_plot.plot(subplots=True, layout=(4,4), kind='box', figsize=(50,6), patch_artist=True)

plt.subplots_adjust(wspace=0.5);

Nov 25, 2022 znrkaradayi answer
votes up 2 votes down

df_to_plot.plot(subplots=True, layout=(4,4), kind='box', figsize=(50,6), patch_artist=True)

plt.subplots_adjust(wspace=0.5);

Nov 25, 2022 znrkaradayi answer

Add a possible fix

Please authorize to post fix