Berger-parker dominance is traditionally calculated as the proportional abundance of the most abundant type. In kmer abundance this is highly sensitive to noise.
The original berger_parker_d function has been altered to get the kmer count of highest abundance with the option of passing a parameter for a noise_floor e.g. user could pass 2 (or more) as the noise floor and ignore all the counts of 1.
In order to compensate for the sensitivity an alternative metric has also been added to calculate the area under the curve of a kmer frequency "hump" . This also carries a noise floor parameter, and aims to ignore a peak that is just at count of 1 (high diversity). The metric initially finds the highest peak after noise floor, and measures the peak area of that.
The result is a metric that is higher for samples with a high peak, indicating dominance of a particular set of kmer coverages.
Berger-parker dominance is traditionally calculated as the proportional abundance of the most abundant type. In kmer abundance this is highly sensitive to noise.
The original berger_parker_d function has been altered to get the kmer count of highest abundance with the option of passing a parameter for a noise_floor e.g. user could pass 2 (or more) as the noise floor and ignore all the counts of 1.
In order to compensate for the sensitivity an alternative metric has also been added to calculate the area under the curve of a kmer frequency "hump" . This also carries a noise floor parameter, and aims to ignore a peak that is just at count of 1 (high diversity). The metric initially finds the highest peak after noise floor, and measures the peak area of that.
The result is a metric that is higher for samples with a high peak, indicating dominance of a particular set of kmer coverages.