vibansal / HapCUT2

software tools for haplotype assembly from sequence data
BSD 2-Clause "Simplified" License
208 stars 36 forks source link

generate fasta of haplotype #49

Closed conchoecia closed 6 years ago

conchoecia commented 6 years ago

Hi All,

Just curious if you have a tool to easily generate a fasta file of phased haplotype blocks using a reference and the output of HapCUT2? I haven't been able to find one in your docs and wanted to ask before writing something to do this.

Thanks, Darrin

conchoecia commented 6 years ago

edited title to be more clear

pjedge commented 6 years ago

Unfortunately, there isn't a single-step way to do this. But, you can convert the output of hapcut2 to VCF (see HapCutToVcf, in the fgbio suite) and then use bcftools consensus to generate the phased fasta using the VCF and fasta reference.

conchoecia commented 6 years ago

Thank you-