Skip to content

Commit

Permalink
parse pars better
Browse files Browse the repository at this point in the history
  • Loading branch information
martinvonk committed Mar 28, 2024
1 parent 9fa5949 commit dd90727
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/spei/dist.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def cdf(self) -> Series:
"""Compute cumulative density function of a Scipy Continuous Distribution"""
if self.pars is not None:
cdf = self.dist.cdf(
self.data.values, self.pars, loc=self.loc, scale=self.scale
self.data.values, *self.pars, loc=self.loc, scale=self.scale
)
else:
cdf = self.dist.cdf(self.data.values, loc=self.loc, scale=self.scale)
Expand All @@ -117,7 +117,7 @@ def pdf(self) -> Series:
data_pdf = self.data.sort_values()
if self.pars is not None:
pdf = self.dist.pdf(
data_pdf.values, self.pars, loc=self.loc, scale=self.scale
data_pdf.values, *self.pars, loc=self.loc, scale=self.scale
)
else:
pdf = self.dist.pdf(data_pdf.values, loc=self.loc, scale=self.scale)
Expand Down

0 comments on commit dd90727

Please sign in to comment.