# Bibliography Style per Information Source

I'm currently in the process of writing my thesis with LaTeX, but I'm having some difficulties with the bibliography style.

I'm basically looking how to make style templates for all the different information sources I'm using (journal article, book, site, ...). Eg: format journal articles as:

John M, Schmidt J and Wieneke U, 1988. Transmembrane orientation and receptor-like structure of the Rhizobium meliloti common nodulation protein NodC. The EMBO Journal. 7 (3), 583–588.

And sites like:

CAZy - GT2, http://www.cazy.org/GT2.html, accessed 8 March 2018

Previously, I used Word and EndNote for citations, and I remembered I could make these templates in EndNote, EN would then apply them and they would be displayed like that in Word.

I've managed to do the same in Mendeley, just using the citation style option and then further adjusting the settings for the different information sources to my liking. However, I then realized that LaTeX doesn't take these citations literally from Mendeley, but rather does it itself from a library provided by Mendeley.

I've tried to look into packages like natbib, biblatex and makebst, but they didn't offer what I was looking for (or at least not according to my limited knowledge).

My tutor has suggested I could just remove unnecessary information from all my citations and abbreviate all author names, and that my bibliography would be okay then. But I think it's understandable that 100 citations in, I don't really feel like doing that. Additionally, the citations for books and sites would still look wrong in the article template, so the problem isn't really solved.

So my question is: is there a way bibliography style can be literally used from Mendeley (I suspect there's not). Alternatively, how can I achieve the same using LaTeX?

This is what my document currently looks like, I left out the commands that aren't related to bibliography:

\usepackage[numbers, square, sort&compress]{natbib}

\begin{document}

text \cite{<Mendeley Citation Key>}

\bibliographystyle{plainnat}
\bibliography{directory}

\end{document}

• You are looking for biblatex and biber. – Johannes_B Jul 10 '18 at 9:53
• The makebst utility (not "package"...) should let you create a highly customized bibliography style that satisfies all of your formatting requirements. – Mico Jul 10 '18 at 10:44

(too long for a comment, hence posted as an answer)

Assuming you wish to stick with BibTeX and the natbib citation management package, you should most definitely look into using the makebst utility (part of custom-bib package) to create a custom .bst (bibliography style) file. The makebst utility is entirely menu driven, and it provides a long list of questions along with multiple-choice answers. At the end, you'll be asked if you wish to create a .bst file; you should answer y ("yes"). To fire up the utility, open a command window and type latex makebst at the command prompt.

In your posting, you only posted enough formatting-related information for entries of type @article. And even for this entry type, the instructions aren't complete. E.g., it's not clear how multiple given names should be formatted: Should it be Granger C W J ("C W J" is short for "Clive William John" -- yes, this author (now deceased) was British, the name "Clive" being a dead give-away...) or Granger CWJ? Anyway, disregarding this unresolved issue for now, I ran the utility and created a prototype bst file (called lverm.bst, for lack of a compelling alternative) that generates the following formatted output:

Other than a comma instead of a period (aka "full stop") having been placed between the journal and volume fields, the result would seem to be spot-on. And, who knows, your tutor may actually prefer the comma to the period. Or, he/she may not care at all, or he/she simply not notice...

Finally, here's the code that gives rise to the screenshot posted above. Observe that I encased two words in the title field in curly braces to prevent BibTeX from converting them to lowercase letters.

\RequirePackage{filecontents}
\begin{filecontents}{mybib.bib}
@article{jsw:88,
author       = "John, M. and Schmidt, J. and Wieneke, U.",
title        = "Transmembrane orientation and receptor-like structure of
the {Rhizobium} meliloti common nodulation protein {NodC}",
journal      = "The EMBO Journal",
year         = 1988,
volume       = 7,
number       = 3,
pages        = "583-588",
}
\end{filecontents}

\documentclass{article}
\usepackage[numbers,square,sort&compress]{natbib}
\bibliographystyle{lverm} % created with "makebst" utility

\begin{document}
\nocite{*}
\bibliography{mybib}
\end{document}

• The comma instead of full stop is not much of a problem. The goal is just to get a consistent and orderly style. There is no obligated style, so I just tried to based mine of what I had to use for previous tasks. I have already tried makebst previously, copied the bst file into the folder, changed the settings as you illustrated above and the document wouldn't generate at all then. Also, while it allowed to generate the journal article citations close to what I'd like, I didn't really feel I had much control over how the site citations would come out. – LVerm Jul 10 '18 at 12:34
• @LVerm - Well, I hope that this answer demonstrates that it's indeed entirely feasible to run the makebst utility successfully, i.e., to generate a bespoke bibliography style file that fully satisfies a given set of formatting requirements. – Mico Jul 10 '18 at 14:22
• Although I do agree that 'makebst' is flexible enough for my needs (maybe apart from the site citations), I still have the problem that the pdf file fails to generate. I followed the instructions of this video (youtube.com/watch?v=05yVud1EHjw). I made the 'makebst' file, pasted it into my folder, changed 'bibliographystyle' with the file name and consequently got an error message. Are the instructions at the end of the video incomplete? Or anything else I'm doing wrong? – LVerm Jul 11 '18 at 9:07
• @LVerm - Sorry, I'm not familiar with this video. What I'm familiar with is the set of instructions provided by the utility itself. IMHO the instructions are rather clear. I honestly can't imagine what, if anything, could be mentioned in an instructional video that's not already evident from the utility's own instructions. In my experience, the BibTeX code produced by the makebst utility is not just robust, it's bullet-proof. If you're getting error messages, something very odd must have happened. Could you maybe elaborate on the error messages you're getting? – Mico Jul 11 '18 at 10:51