calculate_Fws
calculate_Fws(snpdata)
calculate_Fws is a function that calculates the within-host genetic diversity (Fws). Note that the Fws is obtained using the moimix R package
snpdata: an object of class SNPdata
a SNPdata object with 2 additional columns in the meta
data frame:
1. Fws: the Fws across all samples
2. COI: the complexity of infection. 1 for Fws>0.95; 2 for Fws<=0.95