ID fals > Articole > How to Audit a Name-Frequency Dataset

Acest articol nu a fost încă tradus în Română — citești originalul în English. Disponibil și în:Deutsch, English, Українська

How to Audit a Name-Frequency Dataset

Every weighted name dataset makes a claim about a country, whether or not its authors realise it. Somewhere in the file, one surname is the most common and one is the rarest, and the ratio between their weights asserts something about how that population is actually shaped.

The hard part of auditing such a file is not finding errors. It is telling the difference between "this data is broken" and "this country is actually like that." From inside the file, those look identical. Norway's top ten surnames cover 6.0% of the population; Vietnam's cover about 71%. A flat curve is a fact in one place and a defect in the other, and no amount of staring at the weights will tell you which one you hold.

What follows is the set of tools we built while auditing name corpora for 63 locales against national registries, on 17 July 2026. Two are arithmetic and answer the question directly. Most of the rest are about what does not answer it — because the intuitive signals, the ones everyone reaches for first, are all wrong, and each cost us real work before we noticed.

The setup

Assume a dataset of value → integer weight, the weight assigned from a real frequency source by

w = round(255 × c / c_top1)      // clamped to a minimum of 1

c is the bearer count of the entry, c_top1 the count of the most common entry, and 255 is the scale ceiling (one unsigned byte). Substitute your own constants — the algebra survives. What matters is that the weight is a ratio to the top entry, and that there is a floor below which the scale cannot go. That floor is where nearly every defect in this article lives.

Tool 1: claimed coverage

Weight 1 is not a vague label meaning "rare". It is a quantitative claim. If the top entry's weight corresponds to its real share of the population, one unit of weight is worth exactly share_top1 / max_weight of that population — so the file, by summing its own weights, states how much of the country it believes it describes:

claimed coverage = Σ(weights) × real_share_of_top1 / max_weight

Compare that to the corpus's real coverage — the summed real shares of the entries actually present. This is the only diagnostic here falsifiable by arithmetic alone: a file cannot describe 114% of a country.

DatasetClaimed coverageReal coverageRatioWhat it meant
zh_CN (before)114% of China~91%Tail objectively overweighted. Arithmetically impossible
es_ES (before)200% of SpainTail overweighted twofold; 53% of entries lighter than weight 1
fr_FR (before)54.2%25.6%2.11×Overstated by more than double
fr_FR (after)1.001×Corrected
no_NO29.2%30.1%0.97×Healthy — never touched
lv_LV27.03%~27.3%~0.99×Healthy despite 57% of entries at weight 1
sv_SE surnames57.29%53.17%1.077×Healthy
zh_TW (after)109.8%99.61%1.10×Healthy for a concentrated locale

The zh_TW row is a measurement of the 8-bit build and no longer describes the shipped file. On 18 July 2026 that locale moved to verbatim registry counts: 2,707 surnames, claimed coverage 99.98%, ratio 1.00×. The whole "phantom floor mass" effect below is a property of relative scales, so it does not apply to a corpus storing real counts — the ratio there is 1.00× by construction, and a reading above 1.0 would be a genuine defect rather than a normal overhang. Read this section as the method for auditing ceiling-scaled corpora, which is still 52 of our 64 surname files and 56 of 64 on the given-name side.

The healthy band is roughly 1.0–1.1×. Two things to understand about it.

Exceeding 100% is not automatically a defect. Entries whose real share falls below the value of one weight unit still weigh 1 — the scale has no smaller number. That surplus is phantom floor mass, and on a concentrated locale it legitimately adds a few percent: after correction zh_CN sits at 100.7%, vi_VN at 103.2%, ko_KR at 108.4%, zh_TW at 109.8%. Around 110% on a concentrated file is normal. 114% under a scale ceiling of 100 was not — that was the tail claiming a country that does not exist.

It is a test, not a plausibility check. Run it as a reductio and it produces absurdities on demand. Sweden's entire surname registry — all 411,798 entries — would yield a file claiming 3,360%: thirty-five Swedens. Taiwan's full 2,730-entry registry would claim 212%: two Taiwans. Vietnam's full top-300 would claim 125.4%. Those are not "suspicious" numbers; they are impossible ones, and impossibility is what you want from an audit tool.

Trap: positions versus bearers

In countries where a person carries two surnames, the shares of all surnames sum to ~200%, not 100%. Feed the formula a bearer share and it screams about a defect that isn't there.

pt_PT with Silva at 9.44% of bearers yields a claimed coverage of 145.4% — an alarm. With the same surname at 4.72% of positions, it yields 72.7%, entirely plausible for a 411-surname corpus. Same file, same formula, opposite verdicts. Spanish locales carry the same hazard, though the registry there publishes first-surname, second-surname and both-surname columns separately: GARCÍA is 1,446,937 as a first surname and 2,915,761 across both positions.

Trap: claimed coverage does not choose your depth

On a hyper-concentrated locale, claimed coverage settles the depth question outright: Vietnam's top-300 hits 125.4% and is thereby excluded. So it is tempting to use it as the depth criterion everywhere.

It does not work on a flat locale, for an arithmetic reason: an honest entry is ratio-neutral. It adds w × share_top1 / max_weight to the claimed side and c / POP to the real side — the same number — so it moves the ratio only through rounding near the floor. For Swedish surnames the ratio held at 1.055× on 1,150 entries and 1.051× on 1,261, breaking only at top-3000 (1.139×). It simply does not answer "which depth is better."

Claimed coverage is a ceiling, not a target. For depth you need a different tool.

Tool 2: the depth threshold — divide by 510, not 255

How deep should a corpus go? Not "as deep as we have data for," and definitely not by eye. Compute the rank at which weight 1 stops being honest:

threshold = count_of_top1 / 510        ← not /255

The /510 is the whole point, and the error we made first. Since w = round(255 × c / c_top1), the clamp engages where round() returns 0 — where 255 × c / c_top1 < 0.5, i.e. c < c_top1 / 510. The /255 formula instead gives the point where the honest weight equals 1.0, which is not where it disappears. It truncates the corpus twice too early; in Spain that error would have cost us 320 real surnames.

Any entry below the threshold is overstated by the clamp. What lies below it is not a curve; it is an invented floor.

DatasetOne weight unit is worthThresholdBehaviour at the boundary
vi_VN0.0598% of populationrank 66Lường at 0.061% — the last honest entry
sv_SE surnames424.5 bearersrank 2130Snygg 425; next is Abdulkadir 424 → honest weight exactly 0.50
es_ES5,717.2 positionsrank 1743Victoria 5,720; next is Fabregas 5,714 → exactly 0.500
sv_SE names ♂160.3 bearersrank 2008WASSIM 161 → 0.502; next BASIL 160 → 0.499
sv_SE names ♀189.1 bearersrank 1850WINNIE 190 → 0.502; next AIKATERINI 189 → 0.500

Five times the boundary landed exactly on the rounding step — a remarkable coincidence, unless the rule is computing rather than guessing.

The stronger evidence is the spread. One criterion returned rank 66 for Vietnam and rank 2,130 for Sweden. A rule producing similar depths everywhere would be suspect; a rule returning a 32-fold difference between a hyper-concentrated country (Nguyễn ≈31%) and a flat one (Andersson 2.06%) is tracking something real. One rule, different answers.

What does not prove anything

This is the section that matters most, because every signal below is intuitive, widely used, and worthless on its own.

"A huge share of entries sit at the minimum weight"

The most seductive one. It looks exactly like a squashed tail, and sometimes it is. But uk_UA has 80% of its corpus at weight 1 while its top-10 share is entirely normal — 29.4%, inside the 20–35% band. Latvian surnames have 57% at weight 1, and the coverage formula clears the file at ~0.99×.

Mass at the floor is a fact about the weight curve, not about the composition of the list. Our own backlog once demanded cleaning "~1,900 artificial Ukrainian surnames," a figure derived from "1,902 entries at weight 2." A random sample of 25 found zero artificial entries; the demonstrably artificial count in the whole file was about 2 to 10, out of 2,209. Don't guess — compute the claimed coverage.

"The head is pinned at the scale ceiling"

Also seductive, also worthless alone. no_NO had a peak weight of exactly 100 under the old ceiling of 100 — and was correct: top-10 at 19.87% against an honest target of 20.03%, claimed/real coverage 0.97×. Norway's natural top-to-floor ratio is 87:1, which fits under 100 with room to spare. The peak sat at the ceiling by coincidence, not by compression.

lv_LV makes the mirror point with a peak of 40, which also proves nothing: Latvia is simply flat, its top surname covering 0.60% of the population. A peak of 40 is right there in the same way a peak of 100 is right in Norway.

What is diagnostic is the conjunction: a peak at the ceiling and more than 25% of the corpus at weight 1. That pair identified 52 datasets that had genuinely run out of scale. Either half alone identified nothing.

Circular verification

The hardest trap in this article, and we walked into it twice independently in a single day. The temptation is irresistible: our number matched an independent source, therefore we didn't fit it. Before accepting that, check whether the source is independent.

Our Hungarian ethnonym surnames account for 8.20% of the file's weight. The academic estimate — Farkas — puts the ethnonym stock at "7–8%." That reads like textbook external validation. It is nothing of the kind. Our weights were calibrated to registry shares (Tóth at 2.192% against the registry's 2.19%), and Farkas draws his figures from the same registry. One dataset counted twice, not two measurements.

A second flavour: the check "top-10 share × claimed coverage = share of population." On Spanish data it converges to within 0.00 percentage points. It is also, for the head of the distribution, very nearly a tautology — all it demonstrates is that rounding error is negligible. The substantive comparison in that file was claimed coverage (73.2%) against real (67.55%), and that one showed a problem.

The rule: if your weights were calibrated from source X, then any comparison against X — or against a paper that cites X — is a consistency check, not confirmation. Consistency checks are useful; they catch arithmetic slips. Just call them what they are.

What a real independent check looks like. Vietnam has no state surname registry, but it has two large samples with opposite regional biases: VNTH01 (n = 1,682,729, north-weighted 63:37) and SG01 (n = 241,000, Ho Chi Minh City). They converge on Nguyễn ≈ 31% — 30.5% and 31.5% respectively. A third, peer-reviewed sample (Nguyen Viet Khoa, Genealogy 8(1):16, 2024, n = 883,835) lands at 31.57% and independently confirms the direction of VNTH01's northern skew. Different methodology, different populations, biases pointing opposite ways, same answer. That is confirmation — and it demolished the number everyone cites, since Nguyễn = 38% traces back to a single 1992 sample, repeated everywhere not because it is good but because it was the only one published.

The other shape of a genuine check is a prediction that could have failed. Our Icelandic corpus was built by people who believed ~10% of Icelanders carry an inherited family name rather than a patronymic; they expected the file to under-deliver by half. The file measures 4.15% (97 of 2,335) and the national statistics office measures 4%. The match is real precisely because the builders expected it to fail.

The defect that only two metrics can see together

Before correction, our Swedish male given-name file exceeded its honest top-10 target — 22.02% against 18.31% — while simultaneously under-claiming coverage at 0.874×.

Read either metric alone and you conclude the file is fine, or at worst that the peak is a bit low. Read them together and the diagnosis is unambiguous: this is not a scale problem, it is a head that was built separately from the middle. The top 10 were too peaked and ranks 11–317 were too light. Nothing but the pair of metrics reveals it.

The target moves

The last tool, and the one that most often gets a correct fix reverted.

After we deepened the Swedish surname corpus from 1,150 to 2,445 entries, its top-10 share fell from 28.83% to 21.62% — apparently a catastrophic regression. It is not. The honest target is real_top10 / real_coverage, and coverage went from 40.73% to 53.17%, so the target itself moved from 30.40% to 23.28%:

MetricBeforeAfter
Entries1,1502,445
Top-10 in file28.83%21.62%
Honest target30.40%23.28%
Shortfall1.57 pp1.66 pp
Real coverage40.73%53.17%
Claimed / real1.055×1.077×
Missing from top-300440

The shortfall is identical at both depths. Depth cost nothing in accuracy and bought +12.4 points of real coverage. The fall in top-10 share is denominator mechanics, not regression — the tail adds mass to the denominator. Same effect, weights untouched throughout: Italian surnames 556 → 1,340 entries moved top-10 from 12.2% to 6.9%; Russian 701 → 1,303 moved 10.08% → 6.36%; Polish 689 → 1,272 moved 9.50% → 6.43%.

The related error is comparing a share inside the file with a share in the population. The top 10 US surnames cover 4.90% of Americans; our 1,864-surname corpus covers 42.29% of Americans; inside that file the top 10 therefore measure 4.90 / 42.29 = 11.59%, and that is correct. Same reality, different denominators. Do not "fix" it.

And some shortfalls should never be closed. Korean surnames run from at 21.5% of the population down to with 7 bearers — 1,527,138:1 against a scale offering 255:1. One weight unit there is worth 41,921 people, so ~130 ultra-rare surnames sit on a floor overstated by three orders of magnitude, adding ~8% phantom mass to the denominator. The file tops out at 60.6% against a real 65.8%, and closing that gap would mean deleting 65 real surnames. A shortfall of a few points on such a locale is the correct answer, not a defect.

The checklist

  1. Compute claimed coverage before forming any opinion. Σ(w) × share_top1 / max_weight. Above ~110% on a concentrated locale, or ~100% on a flat one, the tail is overweighted — objectively, not arguably.
  2. Check your unit first. Positions vs bearers, births vs living bearers, one script vs another. The wrong unit fabricates defects and hides real ones.
  3. Compute the depth threshold as count_of_top1 / 510. Not /255. Verify the boundary lands on the rounding step; if it doesn't, your source and your divisor disagree.
  4. Use claimed coverage as a ceiling, not a target. It won't choose your depth on a flat locale — honest entries are ratio-neutral.
  5. Never conclude from floor mass alone. 80% at weight 1 is compatible with a perfectly healthy file.
  6. Never conclude from a peak at the ceiling alone. Require the conjunction: ceiling peak and >25% at the floor.
  7. Read two metrics together. A file over its target and under-claiming coverage has a head detached from its middle — invisible to either alone.
  8. Interrogate every agreement. If the weights came from X, agreement with X is consistency, not confirmation. Ask what result would have falsified the check.
  9. Recompute the target after changing depth. A falling top-10 share after deepening is arithmetic, not regression.
  10. Accept shortfalls the scale imposes. Reaching a target by deleting real entries is fitting — the very thing you were auditing for.

Data as of 2026-07-17

All figures were measured on 17 July 2026 while building and auditing weighted name corpora for 63 locales against national registries. ⚠ The corpus held 63 locales when these figures were measured; en_IE was added on 18 July 2026 and it holds 64 today. Shares describe the population unless the text says "in file" or "positions"; where figures come from a sample rather than a registry, the text says so. The Hungarian, Spanish and Icelandic examples are reported as we found them, including the cases where our own reasoning was wrong.

Sources:

  • Taiwan, Ministry of the Interior — surname rankings and counts, 30 June 2023: data.gov.tw/dataset/126774
  • Spain, INE — surnames with ≥20 bearers, census of 1 January 2025: ine.es/dyngs/INEbase/operacio…?…
  • France, INSEE — Fichier des noms de famille, births 1891–2000: insee.fr/fr/statistiques/353663…
  • Sweden, SCB — surnames (411,798 entries, 96.1% of the population) and tilltalsnamn given names, 31 December 2022: scb.se
  • Norway, SSB — surname statistics, StatBank table 12891: ssb.no/statbank/table/12891
  • Denmark, Danmarks Statistik — name statistics: dst.dk/da/Statistik/emner/bor…
  • Latvia, CSP — 2021 census, surnames of 1,893,223 permanent residents: stat.gov.lv
  • South Korea, KOSTAT — 2015 Population and Housing Census, surname statistics: kostat.go.kr
  • China, Ministry of Public Security — 2007 top-100 surname tabulation
  • Vietnam — hoten.org VNTH01 (n = 1,682,729) and SG01 (n = 241,000) frequency datasets, CC BY 4.0 as declared in the page text; Nguyen Viet Khoa, "Vietnamese Family Names", Genealogy 8(1):16 (2024): doi.org/10.3390/genealogy80100…
  • Iceland, Hagstofa Íslands — surnames and patronymics, 1 January 2017: hagstofa.is

← Articole