Genetic Drift Simulator

Simulates random allele frequency change using a Wright–Fisher model. This version keeps the app Yola-compatible and uses an internal table scrollbar so users can move across every calculation column.

Drift model: X ~ Binomial(2N, p)
Expected A alleles: E[X] = 2Np   |   Variance: Var(X) = 2Np(1 − p)
p(next) = X / 2N

Inputs

Enter values and run the simulation.

Each generation samples 2N allele copies. A random draw less than p is counted as allele A. The sampled A count becomes p(next).

Results

Starting p
Starting q
2N
Seed Used
Final p
Final q
Final p(next)
Generations Displayed
Interpretation

Use the horizontal scrollbar below to see columns after q², including E[A next], variance, sampled A, p(next), and random draw preview.

Gen p q A count a count 2pq 2N E[A next] Var[A next] SD[A next] Sampled A Sampled a p(next) Random draw preview
No simulation yet.