Skip to content

Can't create histogram (AttributeError: '_process_plot_var_args' object has no attribute 'color_cycle') #96

Description

@demidovakatya

Hey there!

fig, axes = plt.subplots(1)
ppt.hist(axes, df.hour)

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-201-26997647cd59> in <module>()
      1 fig, axes = plt.subplots(1)
----> 2 ppt.hist(axes, df.hour)

/usr/local/lib/python3.6/site-packages/prettyplotlib/colors.py in wrapper(*args, **kwargs)
     33     def wrapper(*args, **kwargs):
     34         with mpl.rc_context(rc=rcParams):
---> 35             return func(*args, **kwargs)
     36     return wrapper
     37 

/usr/local/lib/python3.6/site-packages/prettyplotlib/_hist.py in hist(*args, **kwargs)
     16     ax, args, kwargs = maybe_get_ax(*args, **kwargs)
     17 
---> 18     color_cycle = ax._get_lines.color_cycle
     19     # Reassign the default colors to Set2 by Colorbrewer
     20     if iterable(args[0]):

AttributeError: '_process_plot_var_args' object has no attribute 'color_cycle'

When I try to make the barplot, everything's the same :\

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions