grenaud / schmutzi

Maximum a posteriori estimate of contamination for ancient samples
20 stars 2 forks source link

schmutzi.pl - cannot read reference base... #24

Closed asli1-han closed 6 months ago

asli1-han commented 6 months ago

Hi,

I am trying to run schmutzi.pl after contDeam.pl and contDeam works however I keep getting errors from schmutzi.

contDeam.pl --library double --out outputdir/sample.bam refs/human_MT.fa bam/sample.bam

schmutzi.pl --uselength --ref refs/human_MT.fa --out outpudir/sample_mtcont schmutzi/alleleFreqMT/eurasian/ outputdir/sample.bam

FASTA error: invalid position specified: 16570 bamtools convert ERROR: pileup conversion - could not read reference base from FASTA file at chr 0 position 16570 system cmd /sw/bioinfo/schmutzi/20160424/milou/endoCaller -seq outputdir/sample_mtcont_1_endo.fa -log outputdir/sample_mtcont_1_endo.log -name MT -qual 0 -logindel 50 -deamread -deam5p outputdir/sample_mtcont_1_endo.5p.prof -deam3p outputdir/sample_mtcont_1_endo.3p.prof -cont 0.19 -deam5pc outputdir/sample_mtcont_1_cont.5p.prof -deam3pc outputdir/sample_mtcont_1_cont.3p.prof -single -seqc outputdir/sample_mtcont_1_cont.fa -logc outputdir/sample_mtcont_1_cont.log -namec MTc -l 16569 refs/human_MT.fa outputdir/sample.bam failed: 256 at /sw/bioinfo/schmutzi/20160424/rackham/schmutzi.pl line 372.

grenaud commented 6 months ago

Hello! Are you supplying the same reference as the one you used for mapping? You mapped against refs/human_MT.fa?

asli1-han commented 6 months ago

Thank you for your quick reply. We used rCRS.MT.fasta in both of these steps and for the mapping I believe. It works for my supervisor but I am receiving erros so I tried with the given reference human_MT.fa but received errors again.

grenaud commented 6 months ago

Please be 100% sure, a lot of people map to the nuclear+mt and extract the mt aDNA fragments and try to run schmutzi. This will not work. You need to map to refs/human_MT.fa (beware of mapping to a different rCRS as the chromosome names might not be the same).

asli1-han commented 6 months ago

Understand thank you so much for your help and time.