uravu.axis

The Axis class controls the organisation of axes in the uravu code, including the evaluation of an axis-level multidimensional kernal density estimate.

class uravu.axis.Axis(values: Union[list, uravu.distribution.Distribution])[source]

Bases: object

The Axes class is a flexible storage option for both numerical (numpy.ndarray) and distribution (uravu.distribution.Distribution) arrays.

Parameters:values – Array of values.
ci(ci_points: List[float] = [2.5, 97.5]) → numpy.ndarray[source]
Returns:Uncertainties from 95 % confidence intervals for axis.
classmethod from_dict(my_dict: dict) → uravu.axis.Axis[source]

Class method to produce from a dictionary.

Parameters:my_dict – Input dictionary
Returns:Axis from dictionary.
kde

Multi-dimensional kernel density estimation for the axis.

Type:return
logpdf(x: numpy.ndarray) → numpy.ndarray[source]

” Get the natural log probability density function for all of the distributions in the axes.

Parameters:x – Values to return natural log probability of.
Returns:Natural log probability.
mode

Values that maximise the probability for axis.

Type:return
n

Medians for axis.

Type:return
pdf(x: numpy.ndarray) → numpy.ndarray[source]

” Get the probability density function for all of the distributions in the axes.

Parameters:x – Values to return probability of.
Returns:Probability.
s

Standard deviation of axis values.

Type:return
shape

Shape of axis.

Type:return
size

Size of axis.

Type:return
to_dict() → dict[source]
Returns:Dictionary of Axis.
values

Array of values.

Type:return