Skip to content

Conceptual question regarding norm vector rescaling #19

@dmalzl

Description

@dmalzl

Hi,

First of all thank you for this amazing implementation.
I have a rather conceptual question regarding the code. From using this tool and from what I found how it is used in the HiCExplorer hicCorrectMatrix I found that there are two main results that can be returned:

  1. a norm vector and a rescaled norm vector with kr.get_normalisation_vector(True/False)
  2. a normalized matrix with rescaled and nonrescaled norm vector with kr.get_normalised_matrix(True/False)

My question now is: Why the rescaling?

I get that the nonrescaled results balances the matrix to rowsum/colsum of 1, but is it better to use the rescaled result instead of the unrescaled?

Also a line in the hicCorrectMatrix script is a little bit misleading in this sense:

732            # set it to False since the vector is already normalised
733            # with the previous True
734            # correction_factors = np.true_divide(1, kr.get_normalisation_vector(False).todense())
735            correction_factors = kr.get_normalisation_vector(False).todense()

However, there is no previous True. I mean for the h5 format it does not matter since you anyway store the normalised rescaled matrix but if you use it in cooler this will get you the nonrescaled vector or am I wrong here?

Thank you for the answer in advance,
Best regards,
Daniel

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions