bandhic.band_hic_matrix.set_values#
- band_hic_matrix.set_values(row_idx, col_idx, values)[source]#
Set values at specified row and column indices.
- Parameters:
row_idx (array-like of int) – Row indices where values will be set.
col_idx (array-like of int) – Column indices where values will be set.
values (scalar or array-like) – Values to assign.
- Return type:
None
Examples
>>> import bandhic as bh >>> mat = bh.zeros((3,3), diag_num=2, dtype=int) >>> mat.set_values([0,1], [1,2], [4,5]) >>> mat[0,1] 4
Notes
Writing to masked positions will update the underlying data but will not clear the mask.