Skip to content

Main content

Public Census Field Width Tool

Inspect one supplied public census field against an explicit character/code-unit width budget.

Loading tool…

Description

Return census-field length and maximum excess.

Historical and archival records distinguish source labels, local grid conventions, edition numbers and validity periods. A parsed token or geometric area term cannot establish provenance, historical identity or land rights. Date endpoints, text-counting units and numbering origins must match the original record.

Return census-field length and maximum excess.

When to use this tool

Use Public Census Field Width when checking the stated archival record, grid, edition or validity-period convention.

How to use the tool and how it works

  1. Enter field, countCodePoints, suppliedMaximum. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read length, excess. Use the output convention below.

Return census-field length and maximum excess. Require nonnegative whole suppliedMaximum; count Unicode code points or UTF-16 code units by policy, excess = max(0,length-maximum).1

Unicode code points and UTF-16 code units are different counting units. Neither alone measures user-perceived grapheme clusters or rendered text width.2

Input fieldMeaning and unitsAccepted input
fieldFieldRequired. Text; maximum UTF-16 length 8192.
countCodePointsCount Code PointsRequired. Boolean.
suppliedMaximumSupplied MaximumRequired. Safe integer; minimum 0.
Output fieldInterpretationReturned shape
lengthLengthRequired. Safe integer.
excessExcessRequired. Safe integer.
json
{
  "input": {
    "field": "Town A",
    "countCodePoints": true,
    "suppliedMaximum": 5
  },
  "output": {
    "length": 6,
    "excess": 1
  }
}

Limitations and assumptions

  • Neither unit guarantees grapheme/display width; no census schema, historical wording or actual record validity is determined.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
  • Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.

Alternative or Complementary methods

Consult the original archive, survey and applicable authority for historical interpretation, provenance or actual property rights.

References

  1. Calculation and input contract: american-studies/public-census-field-width — tool.io

  2. Unicode 17.0: core specification, encoding forms — Unicode Consortium

Similar or alternative tools