Skip to content

Commit

Permalink
pep8 and docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
JrtPec committed Apr 23, 2018
1 parent 7e979e6 commit 07f9715
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions opengrid/library/analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ def load_factor(ts, resolution=None, norm=None):
Parameters
----------
ts : Pandas Series
ts : pandas.Series
timeseries
resolution : str, optional
interval over which to calculate the ratio
Expand All @@ -124,14 +124,14 @@ def load_factor(ts, resolution=None, norm=None):
Returns
-------
Pandas Series
pandas.Series
"""
if norm is None:
norm = ts.max()

if resolution is not None:
ts = ts.resample(rule=resolution).mean()

lf = ts/norm
lf = ts / norm

return lf

0 comments on commit 07f9715

Please sign in to comment.