Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions news/param-dep.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
**Added:**

* Added ``is_constant`` method to ``Parameter``.
* Added ``bound_range`` method to ``Parameter``.
* Added ``bound_window`` method to ``Parameter``.

**Changed:**

* <news item>

**Deprecated:**

* Deprecated ``isConst`` method of ``Parameter``. Use ``is_constant`` instead.
* Deprecated ``boundRange`` method of ``Parameter``. Use ``bound_range`` instead.
* Deprecated ``boundWindow`` method of ``Parameter``. Use ``bound_window`` instead.

**Removed:**

* <news item>

**Fixed:**

* <news item>

**Security:**

* <news item>
6 changes: 3 additions & 3 deletions src/diffpy/srfit/equation/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ def __eval_binary(self, other, OperatorClass, onleft=True):

Other can be an BaseBuilder or a constant.

Attributes
Parameters
----------
onleft
Indicates that the operator was passed on the left side
Expand Down Expand Up @@ -666,7 +666,7 @@ def __call__(self, *args):

This creates a new builder that encapsulates the operation.

Attributes
Parameters
----------
args
Arguments of the operation.
Expand Down Expand Up @@ -730,7 +730,7 @@ def wrapOperator(name, op):
def wrapFunction(name, func, nin=2, nout=1):
"""Wrap a function in an OperatorBuilder instance.

Attributes
Parameters
----------
name
The name of the function
Expand Down
2 changes: 1 addition & 1 deletion src/diffpy/srfit/equation/equationmod.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ class Equation(Operator):
def __init__(self, name=None, root=None):
"""Initialize.

Attributes
Parameters
----------
name
A name for this Equation.
Expand Down
2 changes: 1 addition & 1 deletion src/diffpy/srfit/equation/literals/argument.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def getValue(self):
def set_value(self, val):
"""Set the value of the Literal.

Attributes
Parameters
----------
val
The value to assign
Expand Down
2 changes: 1 addition & 1 deletion src/diffpy/srfit/equation/literals/operators.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def __init__(self, op):

Arguments

Attributes
Parameters
----------
op
A numpy ufunc
Expand Down
4 changes: 2 additions & 2 deletions src/diffpy/srfit/equation/visitors/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
def getArgs(literal, getconsts=True):
"""Get the Arguments of a Literal tree.

Attributes
Parameters
----------
getconsts
If True (default), then Arguments designated as constant
Expand All @@ -50,7 +50,7 @@ def getArgs(literal, getconsts=True):
def getExpression(literal, eqskip=None):
"""Get math expression string from the Literal tree object.

Attributes
Parameters
----------
eqskip
regular expression pattern for Equation objects that should
Expand Down
2 changes: 0 additions & 2 deletions src/diffpy/srfit/equation/visitors/printer.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@
class Printer(Visitor):
"""Printer for printing a Literal tree.

Attributes:

Attributes
----------
eqskip
Expand Down
2 changes: 1 addition & 1 deletion src/diffpy/srfit/equation/visitors/swapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Swapper(Visitor):
def __init__(self, oldlit, newlit):
"""Initialize.

Attributes
Parameters
----------
oldlit
The literal to be replaced.
Expand Down
8 changes: 4 additions & 4 deletions src/diffpy/srfit/fitbase/fitcontribution.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def __init__(self, name):
def set_profile(self, profile, xname=None, yname=None, dyname=None):
"""Assign the Profile for this FitContribution.

Attributes
Parameters
----------
profile
A Profile that specifies the calculation points and that
Expand Down Expand Up @@ -227,7 +227,7 @@ def add_profile_generator(self, gen, name=None):
Calling addProfileGenerator sets the profile equation to call the
calculator and if there is not a profile equation already.

Attributes
Parameters
----------
gen
A ProfileGenerator instance
Expand Down Expand Up @@ -278,7 +278,7 @@ def set_equation(self, eqstr, ns={}):
for this FitContribution. The equation will be usable within
set_residual_equation as "eq", and it takes no arguments.

Attributes
Parameters
----------
eqstr
A string representation of the equation. Any Parameter
Expand Down Expand Up @@ -353,7 +353,7 @@ def getEquation(self):
def set_residual_equation(self, eqstr):
"""Set the residual equation for the FitContribution.

Attributes
Parameters
----------
eqstr
A string representation of the residual. If eqstr is None
Expand Down
12 changes: 5 additions & 7 deletions src/diffpy/srfit/fitbase/fithook.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def precall(self, recipe):
"""This is called within FitRecipe.residual, before the
calculation.

Attributes
Parameters
----------
recipe
The FitRecipe instance
Expand All @@ -69,7 +69,7 @@ def postcall(self, recipe, chiv):
"""This is called within FitRecipe.residual, after the
calculation.

Attributes
Parameters
----------
recipe
The FitRecipe instance
Expand All @@ -88,8 +88,6 @@ class PrintFitHook(FitHook):
This FitHook prints out a running count of the number of times the residual
has been called, or other information, based on the verbosity.

Attributes

Attributes
----------
count
Expand Down Expand Up @@ -127,7 +125,7 @@ def precall(self, recipe):
"""This is called within FitRecipe.residual, before the
calculation.

Attributes
Parameters
----------
recipe
The FitRecipe instance
Expand All @@ -141,7 +139,7 @@ def postcall(self, recipe, chiv):
"""This is called within FitRecipe.residual, after the
calculation.

Attributes
Parameters
----------
recipe
The FitRecipe instance
Expand Down Expand Up @@ -237,7 +235,7 @@ def postcall(self, recipe, chiv):

Find data and plot it.

Attributes
Parameters
----------
recipe
The FitRecipe instance
Expand Down
2 changes: 1 addition & 1 deletion src/diffpy/srfit/fitbase/fitrecipe.py
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ def _new_parameter(self, name, value, check=True):
def __get_var_and_check(self, var):
"""Get the actual variable from var.

Attributes
Parameters
----------
var
A variable of the FitRecipe, or the name of a variable.
Expand Down
8 changes: 4 additions & 4 deletions src/diffpy/srfit/fitbase/fitresults.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ class FitResults(object):
def __init__(self, recipe, update=True, showfixed=True, showcon=False):
"""Initialize the attributes.

Attributes
Parameters
----------
recipe : FitRecipe
The recipe containing the results.
Expand Down Expand Up @@ -733,7 +733,7 @@ class ContributionResults(object):
def __init__(self, con, weight, fitres):
"""Initialize the attributes.

Attributes
Parameters
----------
con
The FitContribution
Expand Down Expand Up @@ -829,7 +829,7 @@ def resultsDictionary(results):
This reads the results from file and stores them in a dictionary to be
returned to the caller. The dictionary may contain non-result entries.

Attributes
Parameters
----------
results
An open file-like object, name of a file that contains
Expand Down Expand Up @@ -865,7 +865,7 @@ def initializeRecipe(recipe, results):
free) in the recipe to the results values. Note that the recipe has to be
configured, with variables. This does not reconstruct a FitRecipe.

Attributes
Parameters
----------
recipe
A configured recipe with variables
Expand Down
Loading
Loading