rr1859 / R.4Cker

MIT License
16 stars 15 forks source link

unable to map using bowtie and generate bedGraph #42

Closed dotaa closed 6 years ago

dotaa commented 6 years ago

Hi, I have downloaded both kent and bedtools2 and theyre in $PATH as well. however it fails to load using module in reducedgenome.sh script. i see that only two commands from these packages each are required for running the script. I have put the path of fastaFromBed and oligoMatch in the script itself. i see that the files generated look fine. however, bowtie2 mapping stats is giving something like: 13166601 reads; of these: 13166601 (100.00%) were unpaired; of these: 13166601 (100.00%) aligned 0 times 0 (0.00%) aligned exactly 1 time 0 (0.00%) aligned >1 times 0.00% overall alignment rate it seems like its not mapping at all. bowtie-build command: bowtie2-build PATHtofolder/hg19_hindiii_flanking_sequences_35_unique_2.fa Pathtooutputfolder/hg19_hindiii_flanking_sequences_35_unique_2

bowtie2 command: bowtie2 -p 12 -N 0 -5 15 --un unaligned.sam -x PATHtofolder/hg19_hindiii_flanking_sequences_35_unique_2 -U sample.fastq -S aligned.sam

i think the files generated are no correct although they 'look' correct. i am not able to generate bedgraph either from the script sam_bedGraph.sh

Please help!

Thank you! Sanaa

rr1859 commented 6 years ago

Hi, Im not sure I understand where the problem is - how many lines do you have in the hg19_hindiii_flanking_sequences_35_unique_2.bed file?

dotaa commented 6 years ago

i have 1690727 lines in hg19_hindiii_flanking_sequences_35_unique_2.bed. the files look file but am unable to generate bedgraph from sam. It looks like this: 1 15971 16006 1 16012 16047 1 24535 24570 1 24576 24611 1 27945 27980 1 27986 28021 1 30393 30428 1 30434 30469 1 32117 32152 1 32158 32193 1 32738 32773 The sam file also looks okay. but mapping stats show that nothing is aligned. i dont understand what's going on. the total reads that i have are 1222571.

dotaa commented 6 years ago

oh i am sorry, total reads that i have are 14179421

dotaa commented 6 years ago

Hi, So i trimmed the NNN's at the end of the fastq file and the genome is aligned at 94% alignment rate. however, the sam file did not have chr in the beginning of $3 therefore, grep "^chr" wasnt working. upon removing that from the script, it was able to generate the bedgraph file.

Thank you so much!