Skip to content

records module

Classes for working with allocation records.


alloc_points_field_config ReadonlyConfig

Field config for AllocRanges.

ReadonlyConfig(
    dtype=np.dtype([
        ('id', 'int64'),
        ('col', 'int64'),
        ('alloc_idx', 'int64')
    ]),
    settings=dict(
        idx=dict(
            name='alloc_idx'
        ),
        col=dict(
            title='Group',
            mapping='groups',
            group_indexing=True
        ),
        alloc_idx=dict(
            title='Allocation Index',
            mapping='index'
        )
    )
)

alloc_ranges_field_config ReadonlyConfig

Field config for AllocRanges.

ReadonlyConfig(
    dtype=np.dtype([
        ('id', 'int64'),
        ('col', 'int64'),
        ('start_idx', 'int64'),
        ('end_idx', 'int64'),
        ('alloc_idx', 'int64'),
        ('status', 'int64')
    ]),
    settings=dict(
        idx=dict(
            name='alloc_idx'
        ),
        col=dict(
            title='Group',
            mapping='groups',
            group_indexing=True
        ),
        alloc_idx=dict(
            title='Allocation Index',
            mapping='index'
        )
    )
)

AllocPoints class

AllocPoints(
    wrapper,
    records_arr,
    col_mapper=None,
    **kwargs
)

Extends Ranges for working with allocation range records.

Superclasses

Inherited members


field_config property

Field config of AllocPoints.

HybridConfig(
    dtype=np.dtype([
        ('id', 'int64'),
        ('col', 'int64'),
        ('alloc_idx', 'int64')
    ]),
    settings=dict(
        id=dict(
            name='id',
            title='Id',
            mapping='ids'
        ),
        col=dict(
            name='col',
            title='Group',
            mapping='groups',
            as_customdata=False,
            group_indexing=True
        ),
        idx=dict(
            name='alloc_idx',
            title='Index',
            mapping='index'
        ),
        alloc_idx=dict(
            title='Allocation Index',
            mapping='index'
        )
    )
)

Returns AllocPoints._field_config, which gets (hybrid-) copied upon creation of each instance. Thus, changing this config won't affect the class.

To change fields, you can either change the config in-place, override this property, or overwrite the instance variable AllocPoints._field_config.


AllocRanges class

AllocRanges(
    wrapper,
    records_arr,
    open=None,
    high=None,
    low=None,
    close=None,
    **kwargs
)

Extends Records for working with allocation point records.

Superclasses

Inherited members


field_config property

Field config of AllocRanges.

HybridConfig(
    dtype=np.dtype([
        ('id', 'int64'),
        ('col', 'int64'),
        ('start_idx', 'int64'),
        ('end_idx', 'int64'),
        ('alloc_idx', 'int64'),
        ('status', 'int64')
    ]),
    settings=dict(
        id=dict(
            name='id',
            title='Range Id',
            mapping='ids'
        ),
        col=dict(
            name='col',
            title='Group',
            mapping='groups',
            as_customdata=False,
            group_indexing=True
        ),
        idx=dict(
            name='alloc_idx',
            title='Index',
            mapping='index'
        ),
        start_idx=dict(
            title='Start Index',
            mapping='index'
        ),
        end_idx=dict(
            title='End Index',
            mapping='index'
        ),
        status=dict(
            title='Status',
            mapping=RangeStatusT(
                Open=0,
                Closed=1
            )
        ),
        alloc_idx=dict(
            title='Allocation Index',
            mapping='index'
        )
    )
)

Returns AllocRanges._field_config, which gets (hybrid-) copied upon creation of each instance. Thus, changing this config won't affect the class.

To change fields, you can either change the config in-place, override this property, or overwrite the instance variable AllocRanges._field_config.