11112019, 03:43 AM
This program was written on my HP 34C and calculates allele frequencies and genotype frequencies, based on the assumptions of two alleles and HardyWeinberg equilibrium. It could be of interest to e.g. biology teachers.
LBL A
X><Y
÷
STO 5
√
STO 2
1

CHS
STO 1
X^2
STO 3
RCL 1
RCL 2
*
2
*
STO 4
RCL 2
RCL 1
RTN
Start off with entering the sample size (i.e. number of individuals studied) in the Y register and number of homozygous recessive individuals (e.g. individuals showing expression of a rare recessive genetic variant) in the X register.
E.g. if 100 individuals were investigated for a recessive genetic variant (allele), such as the inability to taste bitter substances, and this recessive trait was found in 15 individuals, you would key in 100 ENTER 15, and then run the program. The program places the dominant allele frequency (p) in the X register and in R1, and recessive allele frequency (q) in Y and in R2, homozygous dominant genotype frequency in R3, heterozygous in R4, and homozygous recessive genotype in R5. In the example above p=0.61 and q=0.39, heterozygous individuals carrying both alleles but not showing the recessive trait has frequency 0.47, or almost half the population. Frequency of individuals with dominant alleles only is in this case 0.38.
LBL A
X><Y
÷
STO 5
√
STO 2
1

CHS
STO 1
X^2
STO 3
RCL 1
RCL 2
*
2
*
STO 4
RCL 2
RCL 1
RTN
Start off with entering the sample size (i.e. number of individuals studied) in the Y register and number of homozygous recessive individuals (e.g. individuals showing expression of a rare recessive genetic variant) in the X register.
E.g. if 100 individuals were investigated for a recessive genetic variant (allele), such as the inability to taste bitter substances, and this recessive trait was found in 15 individuals, you would key in 100 ENTER 15, and then run the program. The program places the dominant allele frequency (p) in the X register and in R1, and recessive allele frequency (q) in Y and in R2, homozygous dominant genotype frequency in R3, heterozygous in R4, and homozygous recessive genotype in R5. In the example above p=0.61 and q=0.39, heterozygous individuals carrying both alleles but not showing the recessive trait has frequency 0.47, or almost half the population. Frequency of individuals with dominant alleles only is in this case 0.38.