Hi Sarah,
This is a really good question. The bitwise.dist() function will calculate the fraction of alleles different between samples. Setting differences_only = TRUE will tell the function to calculate the fraction of genotypes different between the samples, making the distance calculation more coarse. Often, it is most appropriate to set differences_only = FALSE
For example, let's say you have four samples genotyped at one locus:
A/A
A/T
T/T
A/A
Your data is represented as the number of minor alleles observed:
0
1
2
0
The distance matrix calculated by bitwise.dist would look like this:
Looking at the first column, this is telling you that, when you compare samples 1 and 2, half of the alleles are different. When comparing samples 1 and 3, all of the alleles are different, but samples 1 and 4 are identical.
If you set differences_only = TRUE, the distance matrix turns out to be:
Again, this is asking the question of whether or not the genotype is the same. You can think of setting differences_only = TRUE as increasing the distance because it removes granularity.
I hope that helps. feel free to ask if you have any further questions!
Best,
Zhian