I have a dataframe in R, one column of which contains bibtex citation commands, such as the following
\\cite[265]{delbarrio2014a}, \\cite[423--429]{nieto2009}, \\cite[188, 191, 196--197]{bile1988a}, \\cite[188--189]{bartonek2003}, \\cite[193]{thompson2010}, \\cite{skelton2015}
I want to make an HTML document with these citations in R Markdown. To do that, they need to be in the format @author, page number
(if there is a page number). How do I convert the strings above into this format? For instance, \\cite[265]{delbarrio2014a}
should become @delbarrio2014a, 265
.