Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No loops detected using balanced matrix #921

Open
davidecarnevali opened this issue Jan 23, 2025 · 5 comments
Open

No loops detected using balanced matrix #921

davidecarnevali opened this issue Jan 23, 2025 · 5 comments

Comments

@davidecarnevali
Copy link

Hi,
I'm having problems detecting loops with hicDetectLoops
When running it using a cool matrix, converted from HicPro raw matrix, many loops are detected. However when running hicDetectLoops on the same cool matrix but balanced with cooler, I got no loops at all.
Here what I did:

First I converted the HiCPro raw matrix to cool format using hicConvertFormat:

hicConvertFormat -m sample1_10kb.matrix --bedFileHicpro sample1.bed --inputFormat hicpro --outputFormat cool -o sample1_10kb.cool

Then I calculated and added the 'weight' column without changing the counts values:

cooler balance sample1_10kb.cool

Running hicDetectLoops on the balanced cool file yelds me no loops at all

Any hint?

Thank you

@joachimwolff
Copy link
Collaborator

joachimwolff commented Jan 23, 2025 via email

@davidecarnevali
Copy link
Author

Cooler does not scale the values back. The KR correction transforms all
values to the 0-1 range.

In HiCExplorer we expect the data to be in the original data range. If you
use our hicCorrectMatrix, we scale the values back. Absolutely no need to
use cooler for this.

Davide @.***> schrieb am Do. 23. Jan. 2025 um 14:10:

Thank you.
So, since hicCorrectMatrix only works on h5 files, I guess I need first to convert raw hicpro matrices to .h5 then run hicCorrectMatrix applying the desired correction *and then convert them to .cool
No need to use firs hicNormalize as suggested right?

Thx

@joachimwolff
Copy link
Collaborator

joachimwolff commented Jan 23, 2025 via email

@davidecarnevali
Copy link
Author

Why do you think it works only for h5?! It works for the cool-format of course too. Whole HiCExplorer supports for ALL its tools the cool format natively.

Beacuse that's what the documentation says: "--matrix, -m: Name of the Hi-C matrix to correct in .h5 format."

Normalization is to adjust for different read coverages. If you don’t have
multiple matrices, this doesn’t matter.

Got it.
Thank you

Davide @.***> schrieb am Do. 23. Jan. 2025 um 15:03:

@joachimwolff
Copy link
Collaborator

joachimwolff commented Jan 24, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants