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.
Methods
__init__([primary, secondary])add_secondary(dset)Append dset to
AnchoredList.secondary.get_dataset_history_info()Contruct and return an
macpie.DictLikeTablibDatasetobject containing allmacpie.Dataset.historyinformation.keep_fields(selected_fields[, ...])Keep specified fields (and drop the rest).
to_excel(excel_writer[, write_excel_dict])Write
AnchoredListto an Excel file by callingmacpie.Dataset.to_excel()onAnchoredList.primaryandAnchoredList.secondary.to_excel_dict()Convert the AnchoredList to a dictionary.
Attributes
all_fieldsA list of all
macpie.Dataset.all_fieldscontained in thisAnchoredList.key_fieldsA list of all
macpie.Dataset.key_fieldscontained in thisBasicList.primaryThe primary anchor Dataset of the collection.
secondaryThe secondary Datasets of the collection.
sys_fieldsA list of all
macpie.Dataset.sys_fieldscontained in thisAnchoredList.tag_anchorTag that gets added to the primary Dataset
tag_secondaryTag that gets added to all the secondary Datasets