r3fang / SnapATAC

Analysis Pipeline for Single Cell ATAC-seq
GNU General Public License v3.0
301 stars 125 forks source link

Troubles while creating snap file with bam #253

Open HieuNg1598 opened 1 year ago

HieuNg1598 commented 1 year ago

I am trying to create snap file using possorted.bam but I have got this problem during dealing with header sam file. Do you know what is the problem ? ERROR: cat <( cat possorted.header.sam )\

<( samtools view possorted_bam.bam | awk '{for (i=12; i<=NF; ++i) { if ($i ~ "^CB:Z:"){ td[substr($i,1,2)] = substr($i,6,length($i)-5); } }; printf "%s:%s\n", td["CB"], $0 }' ) \ | samtools view -bS -> tbi_possorted.snap.bam cat: /dev/fd/63/dev/fd/62: Not a directory [main_samview] fail to read the header from "-".

Hope to hear from you soon