EvaluationSpace1D
- class sherpa.models.regrid.EvaluationSpace1D(x=None, xhi=None)[source] [edit on github]
Bases:
objectClass for 1D Evaluation Spaces.
An Evaluation Space is a set of data axes representing the data space over which a model can be evaluated. A 1D Evaluation Space has only one axis.
- Parameters:
- xarray_like or
None,optional The data array, or the low end of the data bins if the dataset is “integrated”
- xhiarray_like or
None,optional The high end of the data bins for integrated datasets.
- xarray_like or
- Attributes:
endThe end (highest value) of the space.
gridThe grid representation of the space.
is_ascendingIs the space ascending?
is_emptyIs the space empty (the x axis has no elements)?
is_integratedIs the space integrated?
midpoint_gridThe mid-points of the space.
startThe start (lowest value) of the space.
Methods
overlaps(other)Check if this evaluation space overlaps with another.
Returns zeroes for each element of the space.
Attributes Summary
The end (highest value) of the space.
The grid representation of the space.
Is the space ascending?
Is the space empty (the x axis has no elements)?
Is the space integrated?
The mid-points of the space.
The start (lowest value) of the space.
Methods Summary
overlaps(other)Check if this evaluation space overlaps with another.
Returns zeroes for each element of the space.
Attributes Documentation
- end
The end (highest value) of the space.
- grid
The grid representation of the space.
- Returns:
tupleA tuple representing the x axis. The tuple will contain two arrays if the dataset is integrated, one otherwise.
- is_ascending
Is the space ascending?
- is_empty
Is the space empty (the x axis has no elements)?
- is_integrated
Is the space integrated?
- midpoint_grid
The mid-points of the space.
For non-integrated spaces this returns the X axis.
- Returns:
arrayReturn the average point of the bins of integrated axes, for each bin, or the non-integrated x axis array.
- start
The start (lowest value) of the space.
Methods Documentation
- overlaps(other)[source] [edit on github]
Check if this evaluation space overlaps with another.
- Parameters:
- other
EvaluationSpace1D The space to compare to.
- other
- Returns:
- bool
True if they overlap, False if not
- zeros_like()[source] [edit on github]
Returns zeroes for each element of the space.
- Returns:
arrayA one-dimensional array.