Error in chopping alignment files for each chromosome
I have some alignment files for different samples. I want to make one file for each of the chromosome from all the alignment files. For example, I want to combine
chromosome 1 from all alignment files for different samples and make one file. I tried:
while read i; do awk "chr'$i'$"' $(ls *.bam) | cut -f 1 | sort -V > chr1$i.part; done
However, the output file is empty. I will appreciate any help to fix it. Thank you!
• 44 views