plk / biblatex-apa

APA style for BibLaTeX
90 stars 48 forks source link

Incorrect treatment of dataset identifier number as numeric data rather than a character string #242

Open npearlmu opened 2 months ago

npearlmu commented 2 months ago

An identifier for a dataset reference (in the "number" field of a @dataset .bib file entry) should appear as is within parentheses following the dataset's title, preceding the dataset's type (from the "entrysubtype" field) and the title-element's ending period, as in examples 10.9:75a and 10.9:75b (but w/o a version number) in the biblatex-apa-test.pdf file; or below (the "LDC2005T35" element):

Baayen, R. H. (1995). CELEX2 (LDC2005T35) [Text]. Linguistic Data Consortium.

I don't think there is ever a reason to include "No." before the identifier; nor to interpret the text in the .bib file's "number" field as a numeric value rather than a literal string (at least for dataset cases).

But something along these lines is definitely happening. Having "number = {LDC2005T35}" in the dataset's .bib entry yields the reference entry shown above (which is correct).

But "number = {LDC2005X35}" in the .bib entry yields an incorrectly-inserted "No.":

Baayen, R. H. (1995). CELEX2 (No. LDC2005X35) [Text]. Linguistic Data Consortium.

And "number = {XC}" in the .bib entry (entertainingly) yields:

Baayen, R. H. (1995). CELEX2 (No. 90) [Text]. Linguistic Data Consortium.

So it looks like if the "number" field contains only characters individually interpretable as Arabic or Roman numerals, the entire string is interpreted as a number and printed as such, including being preceded by "No.". (The "T" in the identifier in the first (and correct) example prevents this interpretation.)

I have no idea at what point in processing this undesired parsing is happening, but ultimately whatever .bib entry field is used by biblatex-apa to store the identifier value for a dataset should presumably be handled as a (formattable) string, whether or not it could potentially be interpreted as a numeric value.