omfpandas.blockmodel.read_blockmodel_attributes
- omfpandas.blockmodel.read_blockmodel_attributes(blockmodel, attributes=None, query=None, index_filter=None)[source]
Read the attributes/variables from the BlockModel, including calculated attributes.
- Parameters:
blockmodel (BlockModel) – The BlockModel to read from.
attributes (list[str]) – The attributes to include in the DataFrame.
query (str) – The query to filter the DataFrame.
index_filter (list[int]) – List of integer indices to filter the DataFrame.
- Returns:
The DataFrame representing the attributes in the BlockModel.
- Return type:
pd.DataFrame
- Raises:
ValueError – If the attribute is not found in the BlockModel or if both query and index_filter are provided.