macpie.AnchoredList#

class macpie.AnchoredList(primary: Dataset | None = None, secondary: BasicList | None = None)#

A collection of Datasets where one is considered the primary or anchor Dataset, and the rest are considered secondary Datasets.

Parameters:
primaryDataset

The primary anchor Dataset of the collection.

secondaryBasicList

The secondary Datasets of the collection.

__init__(primary: Dataset | None = None, secondary: BasicList | None = None)#

Methods

__init__([primary, secondary])

add_secondary(dset)

Append dset to AnchoredList.secondary.

get_dataset_history_info()

Contruct and return an macpie.DictLikeTablibDataset object containing all macpie.Dataset.history information.

keep_fields(selected_fields[, ...])

Keep specified fields (and drop the rest).

to_excel(excel_writer[, write_excel_dict])

Write AnchoredList to an Excel file by calling macpie.Dataset.to_excel() on AnchoredList.primary and AnchoredList.secondary.

to_excel_dict()

Convert the AnchoredList to a dictionary.

Attributes

all_fields

A list of all macpie.Dataset.all_fields contained in this AnchoredList.

key_fields

A list of all macpie.Dataset.key_fields contained in this BasicList.

primary

The primary anchor Dataset of the collection.

secondary

The secondary Datasets of the collection.

sys_fields

A list of all macpie.Dataset.sys_fields contained in this AnchoredList.

tag_anchor

Tag that gets added to the primary Dataset

tag_secondary

Tag that gets added to all the secondary Datasets