I am writing a Journal Paper which wants datasets to be listed in the reference as

[dataset] Authors; Year; Dataset title; Data repository or archive; Version (if any); Persistent identifier (e.g. DOI),

where "[dataset]" at the beginning is literal. The type of other references (articles, books, etc) does not need to be prefixed in this way. I have already seen the solution given for it at the following link

Dataset reference style in BibLaTeX

But unable to understand. Please help me with working code. My code is available at


and my bibliography file name is mybibfile.bib with following contents

  author={Gross, Ralph and Matthews, Iain and Cohn, Jeffrey and Kanade, Takeo and Baker, Simon},
  journal={Image and Vision Computing},

my LaTex code is using bibtex. Please giive your suggestion. My LaTex code is

\cortext[mycorrespondingauthor]{Corresponding author}
\address{Research Scholar,}
\ead{[email protected]} 
jhjasvhjsh hjshjhjvhjsvh jjkjbkjbkjk jvkjvzjvkjvkj 
abc \sep xyz. 
Text-only mode can also be used for someone who is blind or hard of seeing and only needs the text read to them \citep{gross2010multi}.
  • 2
    The title of the question mentions BibTeX, but the question is tagged biblatex. Do you use BibTeX or biblatex? If you are submitting your paper to a journal chances are they won't accept biblatex submissions, but if you are lucky the provide a BibTeX bibliography style for you to use.
    – moewe
    Commented Apr 30, 2020 at 12:27
  • 1
    Note that the code in the answer to the question you mention (tex.stackexchange.com/q/532449/35864) is working and produces exactly the output shown in the image with an up-to-date system. It may not be useful to you, though, if you use BibTeX and not biblatex.
    – moewe
    Commented Apr 30, 2020 at 12:36
  • It would be ideal if you could show us a short example document of how you produce your bibliography and citations at the moment. That helps us understand whether you use BibTeX or biblatex and also tells us what style you use. A solution will depend crucially on all of these variables. We will probably not be able to help you with code that "just works" unless we know exactly how you produce your bibliography.
    – moewe
    Commented Apr 30, 2020 at 12:37
  • Please do not share your code only on Overleaf: Make it into a truly minimal example document with only the relevant code and post it here directly. Overleaf links may go stale after a while or may get changed. They sometimes also require registration. As far as I can see, the code you posted does not use biblatex at all, so I'm retagging your question
    – moewe
    Commented Apr 30, 2020 at 13:47

2 Answers 2


I had the same issue. I had to edit the bibliography style to get it to work. Here is what I did:

Edit: In this case, I used the model5-names.bst from Elsevier journals. (I believe it's the one for APA citations, if I am not mistaken).

First I created a bbl function to print "[Dataset]". You can just copy an existing one and edit it, for me this worked:

FUNCTION {bbl.datasetbracket}
{ "[Dataset]" }

Secondly, I checked the type of reference I had for my data-sets. In this case, it was an article.

I looked for the block called FUNCTION{article}, duplicated it, and renamed it to datasetype. Finally, I added my bbl.datasetbracket function to it.

FUNCTION {datasetype}
{ "%Type = Article" write$
  format.authors "author" output.check
  author format.key output
  format.date "year" output.check
  format.title "title" output.check
  crossref missing$
      "journal" bibinfo.check
      "journal" output.check
      ", " *
      format.vol.num.pages output
    { format.article.crossref output.nonnull
      format.pages output
  print.url output
  print.doi output
  print.eprint output
  print.pubmed output
  format.note output

Now I just call the reference on my bib file as @datasetype{blabla, ...}


Inspired by user2434449, here is a slightly smaller version which worked better for me. It avoided the BibTex error: "the literal stack isn't empty".

  1. There is no need to create a FUNCTION {bbl.datasetbracket}, just output the text in FUNCTION {datasetype} directly, followed by write$.
  2. I suggest to use FUNCTION {misc} instead of FUNCTION{article} as a starting one to clone, that avoids warnings about missing journal.
  3. Beware that Overleaf seems to cache Bibtex results, I had to comment/uncomment the whole \bibliographystyle command, and Recompile in-between to make changes from the .bst-file appear.

Thus, my recipe is as follows:

  1. Open the appropriate .bst-file, I use the Harvard-style \bibliographystyle{model2-names.bst} for the Elsevier Medical Image Analysis journal.
  2. Go to the function FUNCTION {misc} and copy the block to a new function FUNCTION {datasettype} (I avoid the name dataset to not potentially clash with existing stuff in BibLatex.)
  3. Add "[dataset] " write$ after the first output.bibitem, see example below.
  4. Use @datasettype{...} in your .bib-file.
  5. And yes, I definitely think that Elsevier needs to update their templates to address and document this issue properly!
FUNCTION {datasettype}
{ "%Type = Dataset" write$
  "[dataset] " write$ 
  format.authors output
  author format.key output
  format.date "year" output.check
  format.title output
  howpublished "howpublished" bibinfo.check output
  print.url output
  print.doi output
  print.eprint output
  print.pubmed output
  format.note output

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .