Entering edit mode
                    10.5 years ago
        deepue
        
    
        ▴
    
    160
    Hi,
I have tried to use the below pipeline based on the suggestion in this post.
$BWAPATH/bwa mem $REFPATH/hg19 $DATPATH/R1.fastq.gz $DATPATH/R2.fastq.gz | $SAMPATH/samtools view -Sb - | $SAMPATH/samtools sort - sorted && $SAMPATH/samtools index - > $DATPATH/sorted.bam
The subsequent step is failing with error message sorted.bam is not coordinate sorted.
To my surprise, though the above step has completed successfully, it created an empty file.
Could you please help me understand what might be the reason?