Popgen Tools

Configuration File: popgen_tools.json Tool Type: Local Tools Count: 4

This page contains all tools defined in the popgen_tools.json configuration file.

Available Tools

PopGen_fst (Type: PopGenTool)

Calculate simplified Weir-Cockerham Fst between two populations given allele frequencies and samp…

PopGen_fst tool specification

Tool Information:

  • Name: PopGen_fst

  • Type: PopGenTool

  • Description: Calculate simplified Weir-Cockerham Fst between two populations given allele frequencies and sample sizes. Fst quantifies genetic differentiation: <0.05 little, 0.05-0.15 moderate, 0.15-0.25 great, >0.25 very great differentiation. Useful for measuring population structure and divergence at individual loci.

Parameters:

  • operation (string) (required) Operation type

  • p1 (number) (required) Allele frequency in population 1 [0, 1]

  • p2 (number) (required) Allele frequency in population 2 [0, 1]

  • n1 (integer) (required) Sample size (number of individuals) for population 1

  • n2 (integer) (required) Sample size (number of individuals) for population 2

Example Usage:

query = {
    "name": "PopGen_fst",
    "arguments": {
        "operation": "example_value",
        "p1": "example_value",
        "p2": "example_value",
        "n1": 10,
        "n2": 10
    }
}
result = tu.run(query)

PopGen_haplotype_count (Type: PopGenTool)

Estimate distinct haplotypes after recombination across generations for a region with multiple bi…

PopGen_haplotype_count tool specification

Tool Information:

  • Name: PopGen_haplotype_count

  • Type: PopGenTool

  • Description: Estimate distinct haplotypes after recombination across generations for a region with multiple biallelic SNPs. Reports maximum theoretical haplotypes (2^n), expected crossovers per gamete, probability of at least one recombination event, and estimated haplotype diversity based on LD decay. Useful for understanding recombination impact on genetic variation.

Parameters:

  • operation (string) (required) Operation type

  • n_snps (integer) (required) Number of biallelic SNP loci in the region

  • generations (integer) (optional) Number of generations of random mating (default 1)

  • recomb_rate (number) (optional) Per-adjacent-interval recombination rate [0, 1] per generation (default 0.5)

Example Usage:

query = {
    "name": "PopGen_haplotype_count",
    "arguments": {
        "operation": "example_value",
        "n_snps": 10
    }
}
result = tu.run(query)

PopGen_hwe_test (Type: PopGenTool)

Test Hardy-Weinberg equilibrium for a biallelic locus given observed genotype counts (AA, Aa, aa)…

PopGen_hwe_test tool specification

Tool Information:

  • Name: PopGen_hwe_test

  • Type: PopGenTool

  • Description: Test Hardy-Weinberg equilibrium for a biallelic locus given observed genotype counts (AA, Aa, aa). Computes allele frequencies, expected genotype counts under HWE, chi-square statistic with 1 df, and p-value. Reports whether the locus is in HWE (p > 0.05) and, if not, whether heterozygote excess or deficit is observed. Useful for detecting selection, inbreeding, assortative mating, or genotyping error at individual loci.

Parameters:

  • operation (string) (required) Operation type

  • obs_AA (integer) (required) Observed count of homozygous dominant (AA) genotypes

  • obs_Aa (integer) (required) Observed count of heterozygous (Aa) genotypes

  • obs_aa (integer) (required) Observed count of homozygous recessive (aa) genotypes

Example Usage:

query = {
    "name": "PopGen_hwe_test",
    "arguments": {
        "operation": "example_value",
        "obs_AA": 10,
        "obs_Aa": 10,
        "obs_aa": 10
    }
}
result = tu.run(query)

PopGen_inbreeding (Type: PopGenTool)

Compute inbreeding coefficient F for a known pedigree type over one or more generations. Supports…

PopGen_inbreeding tool specification

Tool Information:

  • Name: PopGen_inbreeding

  • Type: PopGenTool

  • Description: Compute inbreeding coefficient F for a known pedigree type over one or more generations. Supports: self, full-sib, half-sib, first-cousin, double-first-cousin, uncle-niece, aunt-nephew, half-first-cousin, second-cousin. Uses the recurrence F_t = base_F + (1-base_F)*F_{t-1} for iterated inbreeding. Reports F per generation, cumulative F, and retained heterozygosity.

Parameters:

  • operation (string) (required) Operation type

  • pedigree (string) (required) Pedigree type (e.g., ‘half-sib’, ‘first-cousin’, ‘full-sib’)

  • generations (integer) (optional) Number of successive inbreeding generations (default 1)

Example Usage:

query = {
    "name": "PopGen_inbreeding",
    "arguments": {
        "operation": "example_value",
        "pedigree": "example_value"
    }
}
result = tu.run(query)