I have a SAM file which I got it from bwa mem (whole genome Data). My next step is to annotate the repeats using Repeat masker and to identify microstatellites using misa. For both MISA and Repeat Masker, I need fasta format. I tried to convert bam file to fasta format. But the result is not a continuous stretch of fasta. How can I get the continuous fasta file.