Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

natbib, \citet, numerical references: spphys.bst

98 views
Skip to first unread message

Phillip Helbig (undress to reply)

unread,
May 16, 2021, 8:43:27 AM5/16/21
to
I'm using spphys because it is required by the journal. It has
numerical references in the order in which they were cited. I want to
use it with natbib. Everything else works fine, including \citep, but
\citet complains

! Package natbib Error: Bibliography not compatible with author-year
citations.(natbib) Press <return> to continue in numerical citation style.

See the natbib package documentation for explanation.


Package natbib Warning: Author undefined for citation`FAdams19a'
(natbib) on page 2 on input line 148.

A typical bibitem is

\bibitem{FAdams19a}
F.C. Adams, Phys. Rep. \textbf{807}, 1 (2019)

I've used such a scheme before (i.e. numerical citations ordered by
citation order, but with superscripts in the text), with a .bst I
created with custom-bib; in that case, a typical bibitem is

\bibitem[{Hubble(1929)}]{EHubble29a}
E.~P. Hubble, {\it Proc. Natl. Acad. Sci. USA\/}, {\bf 15}, 168, 1929.

The .bst is also made with custom-bib (but not by me):

%% This is file `spphys.bst',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% merlin.mbs (with options:
`seq-no,vonx,nm-init,ed-au,yr-par,xmth,jtit-x,jttl
-rm,thtit-a,vol-bf,volp-com,jpg-1,pgsep-c,num-xser,ser-vol,ser-ed,jnm-x,pub-date
,pre-pub,doi,edpar,edby,fin-bare,pp,ed,abr,ord,jabr,xand,url,url-blk,nfss,')

I guess that the journal didn't intend people to use \citet.

I don't want to change the .tex source.

What are my options?

Generate my own .bst which would be essentially the same so that it
works with \citet. As I mentioned, I have done this before, but it is
not clear to me while my own worked out of the box with natbib and
\citet and spphys.bst doesn't.

Generate the bibliography with another style (say, unsrtnat?) then
process it with LaTeX.

I thought that the idea of natbib was that one could use \citet and
\citep with either numerical or author-year styles and both would come
out looking OK.

Any other ideas?

Phillip Helbig (undress to reply)

unread,
May 16, 2021, 9:00:40 AM5/16/21
to
In article <s7r41a$1m1g$1...@gioia.aioe.org>,
hel...@asclothestro.multivax.de (Phillip Helbig (undress to reply))
writes:

> Generate the bibliography with another style (say, unsrtnat?) then
> process it with LaTeX.

Works after a fashion. Generates some strange errors, but finally
finishes. I then have to replace the .bbl used to get the authornames
to \citet with the original ones.

So, ugly, but it works.

But surely there must be a better way?

0 new messages