I have multiple bib files. I would like to use different text colors for all the references mentioned in different bib files. Secondly, I would like a custom prefix for each bib file.

Please let me know how can I do it?

The result should be similar to as follows:

[R1] uses [O1] and [R2] is based on [O2].


[R1] .....

[R2] .....

Other References

[O1] ....

[O2] ....

The color of references mentioned in section "References" should be black, where as color of references mentioned in section "Other references" should be blue.

Any example should work with the elsarticle class such as

  • I guess it would make sense to remove the biblatex tag since elsarticle is incompatible with biblatex. (For those interested: the biblatex answer to the question is at tex.stackexchange.com/q/470852/35864) – moewe Jan 19 at 19:36
  • That said: I see only one reason to use elsarticle, namely when you submit to an Elsevier journal. In that case it is unlikely that you will be able to use any of the (quite likely) tricky solutions that one might come up with to achieve what you want. As I wrote in tex.stackexchange.com/q/468152/35864, if a publisher class can't do what you want, ask the editor how to do it or don't do it at all. If, on the other hand, you don't plan to submit to Elsevier I would not use elsarticle at all. – moewe Jan 19 at 19:39
  • Actually, I need to submit the paper to Elsevier journal, and for this purpose, I cannot avoid elsarticle. If there is any solution for the above mentioned problem which can also work with elsarticle, that will be great. – Muhammad Hammad Jan 19 at 19:44
  • Firstly, not everything that is theoretically possible is a good idea when you want to submit a paper to a publisher. I suppose they have quite strict guidelines on their bibliographies and I doubt that they allow for split references with colours and such. Have you ever seen the scheme you have in mind in the journal you want to publish with? It is possible to change the entire text colour to red and the font to Comic Sans MS, but Elsevier will probably not like that. So even if it can be done chances are it goes against policy or style guides of your journal. – moewe Jan 19 at 20:39
  • Secondly, it might be tricky to get exactly what you want within the limits that your document class imposes. elsarticle uses natbib, which is nice, but you would probably have to load multibib or a similar package and would have to hack quite a few commands. Those technicalities make it not only difficult to implement something, it also makes it less likely that the workflow on the Elsevier side will be compatible with what you have to conjure up. – moewe Jan 19 at 20: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.