renamed class method
This commit is contained in:
parent
c489fad6ba
commit
37f9292c39
@ -243,7 +243,7 @@ class PDFDictionary(object):
|
|||||||
|
|
||||||
for station, phases in pdf_picks.items():
|
for station, phases in pdf_picks.items():
|
||||||
for phase, values in phases.items():
|
for phase, values in phases.items():
|
||||||
phases[phase] = ProbabilityDensityFunction.fromPick(
|
phases[phase] = ProbabilityDensityFunction.from_pick(
|
||||||
values['epp'],
|
values['epp'],
|
||||||
values['mpp'],
|
values['mpp'],
|
||||||
values['lpp'],
|
values['lpp'],
|
||||||
|
@ -181,8 +181,8 @@ class ProbabilityDensityFunction(object):
|
|||||||
self._x = np.array(x)
|
self._x = np.array(x)
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def fromPick(self, lbound, barycentre, rbound, incr=0.001, decfact=0.01,
|
def from_pick(self, lbound, barycentre, rbound, incr=0.001, decfact=0.01,
|
||||||
type='gauss'):
|
type='gauss'):
|
||||||
'''
|
'''
|
||||||
Initialize a new ProbabilityDensityFunction object.
|
Initialize a new ProbabilityDensityFunction object.
|
||||||
Takes incr, lbound, barycentre and rbound to derive x0 and the number
|
Takes incr, lbound, barycentre and rbound to derive x0 and the number
|
||||||
@ -323,8 +323,8 @@ class ProbabilityDensityFunction(object):
|
|||||||
:return:
|
:return:
|
||||||
|
|
||||||
'''
|
'''
|
||||||
# >>> manu = ProbabilityDensityFunction.fromPick(0.01, 0.3, 0.5, 0.54)
|
# >>> manu = ProbabilityDensityFunction.from_pick(0.01, 0.3, 0.5, 0.54)
|
||||||
# >>> auto = ProbabilityDensityFunction.fromPick(0.01, 0.3, 0.34, 0.54)
|
# >>> auto = ProbabilityDensityFunction.from_pick(0.01, 0.3, 0.34, 0.54)
|
||||||
# >>> manu.commonlimits(0.01, auto)
|
# >>> manu.commonlimits(0.01, auto)
|
||||||
# (
|
# (
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user