hicAdjustMatrix

This tool adjusts hic matrices by keeping, removing or masking a given list of regions or chromosmes.

usage: hicAdjustMatrix --matrix MATRIX --outFileName OUTFILENAME
                       [--chromosomes CHROMOSOMES [CHROMOSOMES ...] |
                       --regions REGIONS | --maskBadRegions MASKBADREGIONS]
                       [--action {keep,remove,mask}]
                       [--interIntraHandling {None,inter,intra}] [--help]
                       [--version]

Named Arguments

--chromosomes, -c

List of chromosomes to keep/remove.

--regions, -r

BED file which stores a list of regions to keep/remove.

--maskBadRegions, -mbr

Bad regions are identified and masked.

Required arguments

--matrix, -m

The Hi-C matrix to adjust. HiCExplorer supports the following file formats: h5 (native HiCExplorer format) and cool.

--outFileName, -o

File name to save the adjusted matrix.

Optional arguments

--action, -a

Possible choices: keep, remove, mask

Keep, remove or mask the list of specified chromosomes/regions. keep/remove: These options keep/remove bins of matrix by deleting them. This may cause issue plotting the matrix if several parts of a single chromosome are going to be deleted. In that case, one may consider using the mask option (Default: “keep”).

Default: “keep”

--interIntraHandling, -iih

Possible choices: None, inter, intra

Remove the inter- or intra-chromosomal contacts of the given chromosomes. (Default: None).

--version

show program’s version number and exit

hicAdjustMatrix can mask, remove or keep defined regions from a BED file or given chromosomes. This can be useful to create a smaller Hi-C matrix of a single chromosome for e.g. testing purposes or to remove repetitive chromosome ends before calculating A/B compartments using hicPCA.

Example usages

$ hicAdjustMatrix -m matrix.cool --action keep --chromosomes chr1 -o matrix_chr1.cool
$ hicAdjustMatrix -m matrix.cool --action mask --regions mask_regions.bed -o matrix_masked.cool

mask_regions.bed

chr1    10  30
chr1    50  300