Skip to content

How to fetch balanced cooler matrix? #139

Answered by robomics
bskubi asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, you can fetch normalized interactions like so:

f = hictkpy.File("test.cool")
sel = f.fetch(normalization="weight")  # this is the default name used by cooler when saving balancing weights
sel = f.fetch(normalization="KR")
sel = f.fetch(normalization="foobar")  # normalizations can in principle have any name. The name used is determined by the tool used to normalize the Cooler/.hic file

For a complete list of the arguments accepted by File.fetch() check out the relevant section in the API docs - link.
We also have some examples in the Quickstart section of the docs.

Unfortunately there is no reasonable way to select a default weight name given that the API is format agnostic.

Here are …

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@bskubi
Comment options

Answer selected by bskubi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
2 participants
Converted from issue

This discussion was converted from issue #138 on December 04, 2024 11:49.