Number-span elision

Number spans (such as page ranges) are often abbreviated – for example, 42–43 as 42–3 and 123–128 as 123–8. This is known as number-span elision, abbreviating (or condensing) inclusive numbers, number abbreviation, and, more informally, as digit-dropping.

Not only are there different names for this custom, there are different styles too. The scripts described on this page deal with the styles set out in the style guides of Chicago University Press (The Chicago Manual of Style, pp. 759–60) and Oxford University Press (New Hart's Rules: The Oxford Style Guide, pp. 590–1). The CMS rules are widely used, the OUP style is more popular in Britain. The differences between the two are best summarised by the following table (examples based on those in the CMS, some added to show OUP style):

Example CMS OUP
3–10
12–18
71–72
96–117
100–104
1100–1113
101–108
808–833
1103–1104
321–328
498–532
1013–1019
1087–1089
1496–1500
11564–11615
12991–13001
3–10
12–18
71–72
96–117
100–104
1100–1113
101–8
808–33
1103–4
321–28
498–532
1013–19
1087–89
1496–1500
11564–615
12991–13001
3–10
12–18
71–2
96–117
100–4
1100–13
101–8
808–33
1103–4
321–8
498–532
1013–19
1087–9
1496–1500
11564–615
12991–3001

The general idea is that in the OUP style as many digits as possible are dropped but teens are maintained (11–17, not 11–7). The CMS stipulates that digits are dropped only when the first number is greater than 100; no digits are dropped when the first number is a multiple of 100; in ranges 101–109, 201–209, etc. only the changed part is used (101–8, 1203–4); ranges of 110 through 199, 210 through 299, etc., two or more digits remain: 321–28, 1087–89. All styles stipulate that spans that cross centuries aren't abbreviated (1997–2002).

The scripts

The scripts are set up in such a way that they target a particular paragraph style, namely, Running Header. The main reason for restricting the scope of the scripts is that they often cannot be used indiscriminately; for example, number ranges are usually not abbreviated in titles and headings; dates that cross the boundary of a century aren't elided (1992–2004); and spans in years BC are not abbreviated in order to avoid ambiguity.

To target a different character style, change line 4 of the script, where it now says

var pstyleName = 'Running Head';

Replace 'Running Head' with the name of the style you want to target.

To run the script indiscriminately anyway, in an index, for instance, simply make sure that the paragraph style coded in the scipt is not in the document.

You can use plain dashes and en rules in number ranges, the scripts match both.


Version history

8 Jan. 2023: Fixed some errors in the description (thanks to Marc Autret for spotting them).

29 Nov. 2020: Fixed a bug in the CMS version.

9 Sept. 2017: First posted.


Useful script? Saved you lots of time?

Consider making a donation. To make a donation, please press the button below. This is Paypal's payment system; you don't need a Paypal account to use it: you can use several types/brands of credit and debit card.

Peter Kahrel's paypal account

To download a script, right-click the link, then select Save Link/Target As.

OUP-style script: drop_digits_OUP.jsx

CMS-style script: drop_digits_CMS.jsx

Safari users: the downloaded file will get the .txt extension, as in drop_digits_OUP.jsx.txt. Simply remove that extension so that you get drop_digits_OUP.jsx and InDesign recognises the script.


Back to script index

Installing and running scripts

Questions, comments? Get in touch