diffHic: How to remove extra chromosomes like chrUn_gl00* from pairParam object
Entering edit mode
Last seen 4.9 years ago

How to remove extra chromosomes like chrUn_gl00* from pairParam object.

Error in preparePairs("/Users/thimmamp/temp_tobe_deleted/HiCMapped/Dicer1_presplit_out_fixmate.bam",  :
  conversion table should have length equal to the number of chromosomes
> str(hs.param)
Formal class 'pairParam' [package "diffHic"] with 4 slots
  ..@ fragments:Formal class 'GRanges' [package "GenomicRanges"] with 6 slots
  .. .. ..@ seqnames       :Formal class 'Rle' [package "S4Vectors"] with 4 slot

diffHic • 726 views
Entering edit mode

For future reference, please post the code that you ran to generate this error. Also, are you using the latest version? Check out the posting guide FAQ for the usual information you should put in a post.

Entering edit mode
Aaron Lun ★ 27k
Last seen 1 hour ago
The city by the bay

You can remove extra chromosomes in pairParam fairly easily by just removing them in the GRanges object containing the restriction fragment coordinates. For example, to keep only chromosomes 1-19 and X and Y (for the mouse genome, but you get the general idea), you could do something like this:

frags <- mm.param$fragments # where mm.param is a pairParam object
frags <- frags[seqnames(frags) %in% paste0("chr", c(1:19, "X", "Y"))]
mm.param <- reform(mm.param, fragments=frags)

This is only necessary for the release version of diffHic. In the development version, preparePairs is more tolerant of extra chromosomes in the fragment list that aren't in the BAM file, and these will just get ignored (no harm, no foul). In general, though, it's better to construct your fragment list from the same sequences you used for alignment, just to avoid these annoying gotchas. cutGenome should work on one or more FASTA files as well.

Entering edit mode
tidecrepep • 0
Last seen 4.9 years ago

In my view, Trisomy, the presence of a third copy of one chromosome, is deleterious and results in invitable or defective progeny if passed through the germ line, with fei2. Using a novel intron-based genetic assay to identify rare homology-independent DNA rearrangements associated with repair of a chromosomal DSB in S. cerevisiae might hele.  Hope it's helpful for you! 


Login before adding your answer.

Traffic: 303 users visited in the last hour
Help About
Access RSS

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6