The MeAnd23W_AncestryCompSummary table holds the summary side of 23andMe’s Ancestry Composition. Each row is one population (an ancestry region such as a broad continental group or a more specific country-level group) at one confidence threshold, along with how much of the profile’s ancestry that population accounts for.
23andMe reports Ancestry Composition as a tree of populations at several confidence thresholds. Broad populations sit at the top and narrower populations hang beneath them; the parent_id column captures that parent/child hierarchy. The painted chromosome segments behind each population are stored separately in the MeAnd23W_AncestryCompSegments table, joined back to this table by population_id and threshold.
| Column | Type | Description |
|---|---|---|
| Id | int (PK) | Auto-incrementing primary key |
| psid | string | The 23andMe profile ID being gathered |
| threshold | string | The confidence threshold this population tree was reported at. The same population appears once per threshold. |
| population_id | string | Identifier of the population (ancestry region). Used to join to the segments table. |
| label | string | Human-readable name of the population (e.g. a region or country name) |
| parent_id | string | The population_id of this population’s parent in the tree, building the broad-to-specific hierarchy. Empty for top-level populations. |
| totalPercent | string | The percentage of ancestry assigned to this population, as reported by 23andMe |
| totalProportion | double | The same assignment expressed as a proportion (0–1) |
| hap1Percent | string | Percentage assigned to this population on the first haplotype (one parent’s copy) |
| hap2Percent | string | Percentage assigned to this population on the second haplotype (the other parent’s copy) |
| is_trace | int | 1 if this is a trace-level population, 0 otherwise |
| is_broad | int | 1 if this is a broad population, 0 otherwise |
| color | string | The display color 23andMe uses for this population |
| metadata | string | JSON blob of extra descriptive fields packed together — description, demonym, highlight countries, IBD countries, and reference ethnicities — when present |
| created_date | string | When this record was created |
When the Ancestry Composition result is gathered for a profile, 23andMe returns a set of population trees keyed by threshold. The app walks each threshold’s tree from the root down:
population_id, label, parent_id (the node it descended from), totalPercent / totalProportion, the two haplotype percentages, the is_trace and is_broad flags, and color.metadata JSON string when 23andMe supplies them.population_id down as their parent_id.psid are deleted first, then the freshly gathered rows are written. This keeps a profile’s Ancestry Composition consistent rather than accumulating stale rows across gathers.population_id + threshold.