synthpop.modules.age

Submodules

Classes

Age

The Age base class.

Package Contents

class synthpop.modules.age.Age(sun: types.ModuleType = None, coord_trans: types.ModuleType = None, logger: types.ModuleType = None, **kwargs)

Bases: abc.ABC

The Age base class.

age_func_name = 'None'
sun = None
coord_trans = None
logger = None
abstract draw_random_age(N: int = None) np.ndarray or float

Generate a random age from the distribution

Parameters

Nint, None, optional

if N is set to an integer, an array with N random ages is returned

Returns

random_agendarray or float [Gyr]

array of random ages

abstract average_age() float

Returns the average age of the distribution

abstract get_maximum_age() float

Returns the maximum age generated by the distribution if there is no maximum, it should return None.