Text Formatting ⇒ equivalent onlinecite for non-revtex document-class
equivalent onlinecite for non-revtex document-class
I am writing an article in the ACS latex format, documentclass=achemso. Citations are in superscript, but sometimes it is handy to have in-text citations such as "It was shown in Ref. [..]..".
Revtex has the command \onlinecite{..} for this. Anybody knows how to do this in another documentclass such as achemso?
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
-
- Site Moderator
- Posts: 814
- Joined: Tue Jul 01, 2008 2:19 pm
Re: equivalent onlinecite for non-revtex document-class
Re: equivalent onlinecite for non-revtex document-class
a new command
\newcommand{\onlinecite}[1]{\hspace{-1 ex} \nocite{#1}\citenum{#1}}
This gives pretty the same result as \onlinecite in revtex. Only multiple citation like "...in Refs. [1-4]"
I need to adapt manually to get the appropriate result
"..in Refs. [\onlinecite{ref1}- \nocite{ref2,ref3} \onlinecite{ref4}]"
but this is ok for small documents
-
- Site Moderator
- Posts: 814
- Joined: Tue Jul 01, 2008 2:19 pm