minimap2 -a -x map-ont -t 8 ./nCoV-2019/V1/nCoV-2019.reference.fasta res_all-NB04.fastq | samtools view -bS - | samtools sort -o res.sorted.bam -
samtools index res.sorted.bam
align_trim --start --normalise 100 ./nCoV-2019/V1/nCoV-2019.scheme.bed --report res.alignreport.txt < res.sorted.bam 2> res.alignreport.er | samtools view -bS - | samtools sort -T res - -o res.trimmed.sorted.bam
align_trim --normalise 100 ./nCoV-2019/V1/nCoV-2019.scheme.bed --report res.alignreport.txt < res.sorted.bam 2> res.alignreport.er | samtools view -bS - | samtools sort -T res - -o res.primertrimmed.sorted.bam
samtools index res.trimmed.sorted.bam
samtools index res.primertrimmed.sorted.bam
medaka consensus res.primertrimmed.sorted.bam res.hdf
medaka snp ./nCoV-2019/V1/nCoV-2019.reference.fasta res.hdf res.primertrimmed.medaka.vcf
margin_cons_medaka --depth 20 --quality 10 ./nCoV-2019/V1/nCoV-2019.reference.fasta res.primertrimmed.medaka.vcf res.primertrimmed.sorted.bam > res.consensus.fasta 2> res.report.txt
