[Rd] tiny bib glitch in src/librar/stats/man/spectrum.Rd

Sebastian Meyer @eb@meyer @end|ng |rom |@u@de
Sun Mar 29 01:02:03 CET 2026


Am 28.03.26 um 23:09 schrieb Ben Bolker:
> R/src/library/stats/man/spectrum.Rd has the line:
> 
>     \bibcitep{e.g.,|R:Bloomfield:1976|} or 1 and range
> 
> When running code to parse this I'm getting the warning
> 
> Warning: spectrum.Rd:66: Could not find bibentries for the following keys:
>     ‘e.g.’

Thanks for testing. I'm not sure what you mean by "running code to parse 
this". This warning would appear when using the above \bibcitep 
expression from r89703 with R < r89703.

> 
> I think this is because the comma after "e.g." means that the arguments
> of bibcitep are being interpreted as a comma-separated list of bibtex
> keys: from WRE,
> 
>   > Textual and parenthetical citations are obtained via, respectively,
> \bibcitet and \bibcitep (the naming follows that of \citet and \citep in
> the LaTeX natbib package (Daly 2010). These single-argument macros both
> take either a comma-separated list of one or more keyspecs or a single
> citespec of the form before|keyspec|after with both ‘|’ mandatory and
> before and after possibly empty text to be inserted before and after the
> citation if not empty.

Right and it is intended that "e.g.,|R:Bloomfield:1976|" works as a 
single 'citespec' where the 'before' part contains a comma as part of 
the text. Commas are needed relatively often in such pre/post-notes, and 
the restriction to a single annotated key avoids more cumbersome syntax 
variants that would require non-Rd-style escapes for commas.

	Sebastian Meyer



More information about the R-devel mailing list