Skip to content

Puhti and Mahti computing services have been decommissioned. Puhti and Mahti login nodes and storage services will remain available until 15 October 2026, but are no longer covered by service contracts. Please clean up and migrate your data to Roihu ASAP. See Roihu data migration guide for instructions.

Structure

Structure is a software package for using multi-locus genotype data to investigate population structure. Its uses include inferring the presence of distinct populations, assigning individuals to populations, studying hybrid zones, identifying migrants and admixed individuals, and estimating population allele frequencies in situations where many individuals are migrants or admixed.

It can be applied to most of the commonly-used genetic markers, including SNPS, microsatellites, RFLPs and AFLPs.

License

Structure is free to use. Source code is available from the upstream website, but no explicit open-source license is specified.

Available

  • Roihu: 2.3.4, via the bio-apps module.

Usage

Structure is part of the bio-apps collection on Roihu. Load the bio-apps module tree and then the Structure module:

module load bio-apps/v202603
module load structure/2.3.4

Structure reads its run settings from mainparams and extraparams files in the working directory. Prepare these files (along with your genotype data file), then run Structure with:

structure

You can also point Structure at specific files and options on the command line, for example:

structure -m mainparams -e extraparams -K 3 -i infile -o outfile

Structure runs are single-core and can be long, so real analyses should be run as batch jobs. Below is a simple example batch job script:

#!/bin/bash
#SBATCH --job-name=structure
#SBATCH --account=<project>
#SBATCH --output=output_%j.txt
#SBATCH --error=errors_%j.txt
#SBATCH --partition=small
#SBATCH --time=12:00:00
#SBATCH --nodes=1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=1
#SBATCH --mem=4G

module load bio-apps/v202603
module load structure/2.3.4

structure

Replace <project> with your CSC project (for example project_2001234).

See creating a batch job script for Roihu for more information about running batch jobs.

Automating Structure and post-processing

Related tools for running and post-processing Structure analyses are available as separate modules in bio-apps:

  • StrAuto (strauto) — automate Structure across a range of K values and replicate runs, and chain the results into the Evanno ΔK analysis.
  • structureharvester — StructureHarvester, for parsing Structure results and applying the Evanno ΔK method.
  • clumpp — CLUMPP, for aligning replicate cluster assignments across runs.

Support

CSC Service Desk

More information