I'm new to this, so please be gentle!
I have loaded natbib
, babel
and url
in the preamble. I am using BibTeX and a modified vancouver
style.
When I type \cite{Smith2013}
it inserts a superscript number for that reference.
Is there a command that will insert the author's name or the year of the paper into the text, rather than the actual reference number?
Best Answer
I'm surprised you didn't get an error like this:
pdflatex> ! Package natbib error: Bibliography not compatible with author-year citations.
the
vancouver
style is not compatible withnatbib
. Now, you have two possibilities:1) Use
natbib
and try to find a bibliography style that somewhat resemblesvancouver
2) Simply remove
\usepackage{natbib}
of your code and you'll be able to use\bibliographystyle{vancouver}
.Example by following 2):
refs.bib
file looks like this:And the output should look like this:
If you want to use author-year citations, you could load the
natbib
package along with a bibliography style of your choice (e.g.IEEEtranSN
):The output will look something like this: