This is a test version of Biostars. For the public version, visit https://www.biostars.org.
IGV Fasta Error: Uneven Line Lengths

I'm trying to import my reference genome into IGV so that I can view an alignment but IGV doesn't seem to like my reference fasta. I'm assuming IGV is upset over the fact that the fasta has line lengths of 100 bp which I know is not the fasta standard but I'm unsure of how to modify it to fit the 80 bp standard that IGV wants. Any help greatly appreciated!

genome igv

Ah I see. I was going off of information I found here but would the 100 bp line length is the issue or is this something IGV natively supports?

There is no restriction length however, all the sequences have to be the same length.

1 answer

are you able to index the reference with

samtools faidx  your.fa

? = do all your fasta lines have the same length ?

After checking, it turns out there are lines of varying length after all. Is there any way to compress each of the contigs into one large line and then split them evenly from there?

NormalizeFasta (Picard) https://software.broadinstitute.org/gatk/documentation/tooldocs/4.0.7.0/picard_reference_NormalizeFasta.php

Normalizes lines of sequence in a FASTA file to be of the same length.This tool takes any FASTA-formatted file and reformats the sequence to ensure that all of the sequence record lines are of the same length (with the exception of the last line).

https://software.broadinstitute.org/gatk/documentation/tooldocs/4.0.7.0/picard_reference_NormalizeFasta.php

Log in to answer this question.