INNER CODE UNIT · Python
set_highlight_pos_by_ident_thr
moshi4/pyMSAviz · src/pymsaviz/msaviz.py:295
def set_highlight_pos_by_ident_thr(
self, min_thr: float = 0, max_thr: float = 100
) -> None:
"""Set highlight MSA positions by consensus identity threshold
Parameters
----------
min_thr : float, optional
Min identity threshold for highlight position selection
max_thr : float, optional
Max identity threshold for highlight position selection
"""
ident_list = self._get_consensus_identity_list()
highlight_positions: list[int] = []
for pos, ident in enumerate(ident_list):
if min_thr <= ident <= max_thr:
highlight_positions.append(pos)
self._highlight_positions = highlight_positions