Skip to content

Commit

Permalink
add pandas to install requires
Browse files Browse the repository at this point in the history
  • Loading branch information
MRossol committed May 14, 2020
1 parent 911f56f commit 727f20c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 11 deletions.
13 changes: 4 additions & 9 deletions plotting/dataframes.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
Plotting dataframe data with seaborn and pandas
"""
import itertools
import matplotlib.pyplot as plt
import pandas as pd
import seaborn as sns
from plotting.base import plotting_base
Expand Down Expand Up @@ -249,16 +248,14 @@ def plot_func(axis, df, x, y, stack, order=None, **kwargs):
plotting_base(plot_func, df, x, y, stack, **kwargs)


def df_scatter(df, colorbar=False, **kwargs):
def df_scatter(df, **kwargs):
"""
scatter plot based on pandas.plot.scatter
Parameters
----------
df : pandas.DataFrame
Seaborn compliant (long style) DataFrame
colorbar : bool, optional
Flag to add colorbar, by default False
kwargs : dict
kwargs for pandas.DataFrame.plot.scatter and plotting_base
Expand All @@ -268,12 +265,10 @@ def df_scatter(df, colorbar=False, **kwargs):
plotting.base.plotting_base : plotting base
"""
def plot_func(axis, df, colorbar=False, **kwargs):
c = df.plot.scatter(ax=axis, **kwargs)
if colorbar:
plt.colorbar(c)
def plot_func(axis, df, **kwargs):
df.plot.scatter(ax=axis, **kwargs)

plotting_base(plot_func, df, colorbar=colorbar, **kwargs)
plotting_base(plot_func, df, **kwargs)


def df_line_plot(df, **kwargs):
Expand Down
2 changes: 1 addition & 1 deletion plotting/version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""
plotting version number
"""
__version__ = "0.0.5"
__version__ = "0.0.6"
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def run(self):
develop.run(self)


install_requires = ["matplotlib", "seaborn"]
install_requires = ["matplotlib", "seaborn", "pandas"]

setup(
name="plotting",
Expand Down

0 comments on commit 727f20c

Please sign in to comment.