Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am trying to figure out how to make author's name and year show up every time I make a reference.

For example:

my_bibtex.bib has this entry:

@article{Franklin1999,

author = {Franklin Allen and Risto Karjalainen},
title = {Using genetic algorithms to find technical trading rules},
year = {1999},
volume = {51},
pages = {245-271},
journal = {Journal of Financial Economics}

}

If in my_paper.tex I use this line:

Important result has been found by \cite{Franklin1999}

My output looks like:

Important result has been found by [1]

But I want it too look like:

Important result has been found by Franklin 1999

I there a way to do it?

My bibliographystyle is set to plain

\bibliographystyle{plain}

\bibliography{my_bibtex}
share|improve this question
4  
The plain bibliography style isn't easily adapted to authoryear-style citations. Better to use the plainnat bibliography style, the natbib package (load it with option authoryear), and commands such as \citet and \citep ("textual" and "parenthetical" citations -- macros provided by the natbib package). –  Mico Sep 29 '13 at 18:44
2  
Probably »biblatex« would be a suitable option here. –  Thorsten Donig Sep 29 '13 at 18:50
add comment

2 Answers

up vote 2 down vote accepted

Here's a solution that uses the natbib citation management package and the plainnat bibliography style. (Note that the plain bibliography style is not well-suited for authoryear-style citations.) As always, run latex, bibtex, and latex twice more to generate the bibliography and compile the document.

enter image description here

\documentclass{article}
\usepackage[round]{natbib}   % omit 'round' option if you prefer square brackets
\bibliographystyle{plainnat}
\begin{document}
\citet{Franklin1999}
\bibliography{my_bibtex}
\end{document}
share|improve this answer
    
Thank for your answer, for some reason when I run your code. I get this error: ! Package natbib Error: Bibliography not compatible with author-year, I asked another question about it, about the same time you posted this answer: citations.tex.stackexchange.com/questions/135668/… –  Akavall Sep 29 '13 at 20:13
    
@Akavall - When switching from one bibliography style to another, e.g., from plain to plainnat, it's prudent to wipe out all auxiliary files (including the .aux and .bbl files) prior to rerunning latex/bibtex/latex/latex. Please check if deleting the previous batch of auxiliary files does the trick. –  Mico Sep 29 '13 at 20:17
    
Yes. It did the trick! Thank You very much! –  Akavall Sep 29 '13 at 20:21
add comment

What you probably want is something like the authoryear citation style of the biblatex package. If you are trying to follow a particular citation style, it would be best to say which in your original question; a biblatex style likely exists for it.

To compile this example, run

pdflatex my_paper
biber my_paper
pdflatex my_paper
pdflatex my_paper

my_paper.tex:

\begin{filecontents*}{my_bibtex.bib}
@article{Franklin1999,
        author = {Allen Franklin and Karjalainen Risto},
         title = {Using genetic algorithms to find technical trading rules},
          year = 1999,
        volume = 51,
         pages = {245--271},
  journaltitle = {Journal of Financial Economics}
}
\end{filecontents*}
\documentclass{article}
\usepackage[style=authoryear]{biblatex}

\addbibresource{my_bibtex.bib}

\begin{document}
Important result found by~\cite{Franklin1999}.
\printbibliography
\end{document}

output

share|improve this answer
    
Is there a ready-made biblatex style that emulates the "classic" plain (or plainnat) bibliography style? –  Mico Sep 29 '13 at 20:10
    
@Mico I believe just leaving the style as the default (numeric) does this, but I would take a look at tex.stackexchange.com/questions/14045/… as well (in case I don't understand what you're asking) –  Sean Allred Sep 29 '13 at 20:28
    
Thanks. I've checked out the answers you've linked to. It would appear that the option FirstInits=true, stated in the second answer, may not be a correct implementation of the plainnat style. By the way, the default look of biblatex's authoryear setup doesn't look all that close to that of plainnat either. (For the record, I actually prefer the look produced by biblatex!) –  Mico Sep 29 '13 at 20:43
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.