iced.utils.downsample_resolution

iced.utils.downsample_resolution(counts, lengths, factor=2, normalize=False)

Downsamples the resolution of a matrix

Parameters

counts : ndarray (N, N)

contact counts matrix to downsample

lengths : ndarray (L, )

chromosomes lengths

coef : int, optionnal, default: 2

downsample resolution of the counts matrix by coef

Returns

target_counts, target_lengths : ndarray