# Remove question mark following period for reference title in PDF, using Vancouver.bst

I am using LyX with a slightly modified vancouver.bst file. In the PDF output, reference titles that end with a question mark have a period also printed. This occurs only for those references that use the "misc" entry type. For example, one output is:

U. S. Geological Survey. Forecasting California’s Earthquakes—What Can We Expect in the Next 30 Years?. 2008.

Note the "?." following the title.

The entry for this reference is:

@Misc{USG08,
Author         = {{U.S. Geological Survey}},
Title          = {Forecasting {C}alifornia's {E}arthquakes---{W}hat
{C}an {W}e {E}xpect in the {N}ext 30 {Y}ears?},
year           = 2008
}


You can find the modified version of vancouver.bst on PasteBin.

I have read the responses to a similar question "remove comma after title ending with questionmark." But I could not get any of the ideas there to work, or I did not implement them properly. I do not understand bst files very well.

Can anyone offer hacks to the .bst file that would remove the extra periods?

• bibtex can't process "backwards", so unless the question mark is input in a special way that will "redirect" bibtex, a change in the .bst file isn't likely to be practical. you might attack this from the tex angle: define \newcommand{\killpunct}[1]{} and add \killpunct immediately after the ?. (\nopunct is already defined in a way that won't work here, and \@gobble contains an @ that isn't practical in normal input.) not tested. – barbara beeton May 30 '14 at 13:49
• Thanks. The information is helpful, but the approach did not appear to work for me. I added "\newcommand{\killpunct}[1]{}" to the LaTeX preamble, and added "\killpunct" immediately after a question mark in my .bib file. But I received errors on trying to compile. I also tried adding "{\killpunct}" after a question mark in the .bib file, but that also gave errors. Am I missing something here? – John B May 30 '14 at 15:43

here's a hack that does raise some warnings in bibtex, but appears to produce the desired output.

in this test file, i added a definition for \killpunct, to ignore the next token in the input, which will be the (inserted by bibtex) period.

\documentclass{article}
\newcommand{\killpunct}[1]{}
\begin{document}
This is a citation for \cite{USG08}.

\bibliographystyle{modified_vancouver}
\bibliography{bibpunct}
\end{document}


i made one change to the bib entry -- adding \killpunct after the question mark in the title -- and called the file bibpunct.bib:

@Misc{USG08,
Author         = {{U.S. Geological Survey}},
Title          = {Forecasting {C}alifornia's {E}arthquakes---{W}hat
{C}an {W}e {E}xpect in the {N}ext 30 {Y}ears?\killpunct},
year           = 2008
}


note that there are no extra braces around \killpunct.

here is the output:

the bibtex run did raise some warnings:

Warning--empty author and editor in USG08
Warning--missing publisher in USG08


i didn't explore modified_vancouver.bst to see what might be causing this; there's nothing wrong that i can see with the author field in the .bib input. if this were my project, i would look for documentation on the .bst file, or try to ask its author what is expected from a @misc entry.