DataAxis¶
-
class
gammapy.utils.nddata.
DataAxis
(nodes, name='Default', interpolation_mode='linear')[source]¶ Bases:
object
Data axis to be used with NDDataArray
Axis values are interpreted as nodes.
For binned data see
BinnedDataAxis
.Parameters: nodes :
Quantity
Interpolation nodes
name : str, optional
Axis name, default: ‘Default’
interpolation_mode : str {‘linear’, ‘log’}
Interpolation behaviour, default: ‘linear’
Attributes Summary
interpolation_mode
Interpolation mode nbins
Number of bins nodes
Evaluation nodes unit
Axis unit Methods Summary
find_node
(val)Find next node logspace
(vmin, vmax, nbins[, unit])Create axis with equally log-spaced nodes Attributes Documentation
-
interpolation_mode
¶ Interpolation mode
-
nbins
¶ Number of bins
-
nodes
¶ Evaluation nodes
-
unit
¶ Axis unit
Methods Documentation
-
classmethod
logspace
(vmin, vmax, nbins, unit=None, **kwargs)[source]¶ Create axis with equally log-spaced nodes
if no unit is given, it will be taken from vmax, log interpolation is enable by default.
Parameters: vmin :
Quantity
, floatLowest value
vmax :
Quantity
, floatHighest value
bins : int
Number of bins
unit :
UnitBase
, strUnit
-