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.

What's wrong with multibib?

multibib lets me split up my bibliography. But I have to specify manually (by \citeabc or \citedef), which bibliography entry belongs to which section. Also, it's not (really) compatible with LyX.

What do I want?

I want to create a book including natbib's author-date cites and bibliography using LyX.

My \bibliography should be splitted into 2 parts:

  • @ELECTRONIC (Electronical resources)
  • non-@ELECTRONIC (Books, jornals etc.)

I don't want to do this by hand because it's error-prone on big bibliographies and just redundant.

My Question:

What's the best way to automatically split up a natbib bibliography into an @ELECTRONIC and a non-@ELECTRONIC section (by the entrytype of the .bib file)?

Thanks for your ideas, for your answers. - If my question isn't clear this way, please write a comment to inform me about that.

An Example:

% file.bib

@ELECTRONIC{Lundmaier,
  %...
}

@ARTICLE{Lundstein,
  %...
}

@BOOK{Lundberg,
  %...
}


% file.tex

\citep{Lundberg, Lundstein, Lundmaier}
\bibliography{file}

should result in:

== Bibliography ==
= Books and Jornals =
Lundberg, Ulla-Lena ...
Lundstein, Hannah ...

= Electronical Resources =
Lundmaier, Tina ...
share|improve this question
3  
have you already considered switching to biblatex? It should provide all the features of natbib as well as a mechanism where you can put bibliography entries to different bibliographies depending on various criteria (also entry type if I remember correctly). –  Benedikt Bauer Jan 8 '13 at 21:40
    
Thanks for your suggestion (my first upvote ever ;-) ). - I don't know much about biblatex, so I'll try to get some informations about biblatex and comment again later on. –  fdj815 Jan 8 '13 at 22:03
    
I created my own .bst using custom-bib's makebst and I really need that style. - Do you know: Is there any way to port/convert/use .bsts for biblatex? (Or at least: Is there a nice toolkit for style creation like makebst for biblatex?) –  fdj815 Jan 9 '13 at 0:29
    
Unfortunately it looks like there isn't any such tool yet. Compare Is there a WYSIWYG editor for biblatex styles? –  Benedikt Bauer Jan 9 '13 at 7:41
    
@BenediktBauer Thanks, I'm going to take a look at that... –  fdj815 Jan 9 '13 at 9:32
show 2 more comments

1 Answer

up vote 2 down vote accepted

My solution based on the biblatex package looks as follows:

\begin{filecontents}{minimal.bib}
@electronic{electronic1,
author = {A. Author},
title = {Funny website},
urldate = {2013-01-09},
url = {http://www.example.org},
},
@book{book1,
author = {B. Bthor},
title = {A Book of whatever},
date = {2012},
},
@article{article1,
author = {C. Cthor and D. Dthor},
title = {Writing interesting articles},
journaltitle = {The Journal of References},
date = {2010-12-01},
}
\end{filecontents}

\documentclass{book}
\usepackage[
    natbib=true,                    % natbib compatibility mode
    ]{biblatex}
\addbibresource{minimal.bib}
\begin{document}
\nocite{*}
\printbibheading                    % print heading for all bibliographies
\printbibliography[
    nottype = online,               % Put here verything that is NOT of the type "online".
                                    % The "electronic" type is just an alias to "online" 
    title={Books and Journals},     % title of the subbibliography
    heading=subbibliography         % make bibliography go one sectioning level lower
    ]
\printbibliography[
    type=online,                    % Put only references of the type "online" here.
    title={Electronic Ressources},
    heading=subbibliography
    ]
\end{document}

enter image description here

As I have never used LyX I cannot tell how to integrate this into the LyX workflow. But as you told that you managed to create a suitable biblatex style I guess that you already managed to get biblatex working in LyX.

share|improve this answer
    
Very thanks - That's what I needed. –  fdj815 Jan 9 '13 at 20:54
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.