MHCXGraph.core.subgraphs.extract_interface_subgraph¶
- MHCXGraph.core.subgraphs.extract_interface_subgraph(g: Graph, interface_list: list[str] | None = None, chain_list: list[str] | None = None, filter_dataframe: bool = True, update_coords: bool = True, recompute_distmat: bool = False, inverse: bool = False, return_node_list: bool = False) Graph | list[str] | None[source]¶
Select nodes at chain-chain interfaces.
- Parameters:
g (nx.Graph) – Input graph.
interface_list (list of str, optional) – Allowed chain pair labels (e.g., [“AB”,”BC”]). If None, any pairwise inter-chain contact qualifies.
chain_list (list of str, optional) – Restrict to interactions among these chains.
filter_dataframe – See
extract_subgraph_from_node_list().update_coords – See
extract_subgraph_from_node_list().recompute_distmat – See
extract_subgraph_from_node_list().inverse – See
extract_subgraph_from_node_list().return_node_list – See
extract_subgraph_from_node_list().
- Returns:
Subgraph or node list.
- Return type: