I am trying to use adegent in R for calculating the Tajima's D. I have a DNA.bin object containing my sequences from different populations. The sequences are of varying length because of the SNP and indels in them. I get the following error when I run the tajima.test function:
Error in as.matrix.DNAbin(x) :
DNA sequences in list not of the same length.
How could one deal with calculating Tajima's D for sequences of different length?