I cannot get my citations to work using natbib, compiling the entire document gives an error

Package natbib Error: Bibliography not compatible with author-year citations.

My preamble is the following:

\usepackage[top=1in, bottom=1in, right=1in, left=1.5in]{geometry}  % set the margins to 1in on all sides  
\usepackage{graphicx}              % to include figures  
\usepackage{amsmath}               % great math stuff  
\usepackage{amsfonts}              % for blackboard bold, etc  
\usepackage{amsthm}                % better theorem environments  

And at the bottom:


When I run tex, everything comes out more or less as expected (meaning the references appear at the end), but with numbers where I use \cite rather than author-year.

All of my references have the authors and years, so that shouldn't be a problem.

The only idea I have is when I run the .bib on its own, I get lots of overfull \hbox warnings. For example,

Overfull \hbox (7.13487pt too wide) in paragraph at lines 17--26 []\tenrm @articlearcidiacono2004ability, ti-tle=Ability sort-ing and the re-tur ns to col-lege ma-jor, au-thor=Arcidiacono|

Which makes no sense to me, since this shouldn't be an issue. The lines it is referencing:

    title={Ability sorting and the returns to college major},  
    author={Arcidiacono Peter},  
    journal={Journal of Econometrics},  

I have no longer URLS or anything like that, I have also tried using cleveref instead of natbib (which causes other problems), plain and AER bib styles, changing the indentation of everything in the references a few different ways, and everything outlined in the "similar questions" on this cite.

Any ideas?

  • Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. – Ruben Apr 6 '14 at 3:56
  • Compiling a document with the code you've provided doesn't lead to any error. Please add a minimal (non) working example (M(N)WE) – karlkoeller Apr 6 '14 at 5:37
  • Welcome to the TeX.SX! Yes, please, make it a working example, it is so time consuming to even start working on your problem. One single block of all your codes will do this job and it will help solvers tremendously. – Malipivo Apr 6 '14 at 6:41
  • Please indicate, at the very least, which document class you use, how the natbib package is loaded, and how the entry with key arcidiacono2004ability is cited. (The overfull line warning you get sure makes it sound like you're including the contents of the bib file directly, rather than via \cite commands and a call to BibTeX.) – Mico Apr 6 '14 at 6:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.