2

I'm typing a linguistics Master's Thesis and have to use a custom class that our thesis office gives us. Then, I have to use the style that is set by the Linguistic Society of America for citations and references. The only problem is that I don't know the code well enough to see what I have to tweak to make everything work well with each other.

The custom thesis class code that I have to use for my thesis is here: https://copy.com/qgo0XqdfrGOryQp2

The custom bibtex style sheet (which is based off the Linguistic Society of America's style guide) code is the language.bst file on artstein dot org's website (sorry I don't have enough reputation to post more than two links, it's an easy search in google).

Basically I need to remove the comma after the Author name in the citation so it doesn't look like APA style and looks like LSA style (which I think the author of the language.bst) based his code off the APAcite code and so it still retains the comma. How can I remove it based on the code?

enter image description here

The biggest problem is the page that should have "References" as the header appears like this (the actual reference here is correct, I just need to get rid of Appendix C, the asterisk, and Bibliography and should have "References" centered at the top of the page):

enter image description here

In case you need to know, I get this error the first time after running BibTeX:

enter image description here

This is my .bbl file code:

\begin{thebibliography}{1}
\providecommand{\natexlab}[1]{#1}
\providecommand{\url}{\relax}
\providecommand{\urlprefix}{Online: }

\bibitem[{Levon(2007)}]{Levon07}
\textsc{Levon, Erez}. 2007.
\newblock {Sexuality in context}.
\newblock \emph{Language in Society} 36.533--554.

\end{thebibliography}

I'm at my wit's end. My department isn't LaTeX heavy and I can't find anyone to help me with this. The thesis office can't help as the code was given to them by some guy who made it back in 1994 and has retired since. I'm the first to attempt to type my thesis in LaTeX. I do NOT want to have to resort to having to use Word. Anyone out there who enjoys a challenge willing to help me?

Thank you so much in advance!

Here is a link to an MWE: https://copy.com/AdfVqGIIWqR6ed1u You will need to download all the files or it won't work. Just open up the MyThesis.tex file. I put the citation in the abstract.tex file.

  • Yes, I'm using the "Chicago" style guide, which just effects spacing and stuff as far as I know. If you need, the Chicago.clo file is in the new link I added to give you an MWE. – Derronsb Feb 4 '14 at 5:34
  • Well, I'm not sure how to make it minimal without all the files, as I'm afraid something might break and it wouldn't be helpful in the end. I'm sorry. You only really need to look at the MyThesis.tex and the abstract.tex (and maybe the .clo, .bib, and .bbl file). Ignore everything else, I'm just afraid it wouldn't compile if it wasn't all there. – Derronsb Feb 4 '14 at 5:43
  • I just tried to make a minimal version. It doesn't work. That's as minimal as I can get it. – Derronsb Feb 4 '14 at 5:47
1

The class has a definition for thebibliography which really can't be recommended (add a \usepackage{showframe} to see what I mean), and for some reason it is not getting used. However, if you add the following:

\def\thebibliography#1{%
 \ifrawbibliography
 \else
  \newpage
  \thispagestyle{empty}%
  \addcontentsline{toc}{chapter}{REFERENCES}%
% Switch singlespace to after the heading gets printed.
  \mainheading{REFERENCES}%
  \par\removelastskip\singlespace\par\removelastskip% GBG Oct 1993
  \fixmainheadingSKIP
 \fi
  \list{[\arabic{enumi}]}%
  {\settowidth\labelwidth{[#1]}\leftmargin%
     \labelwidth\advance\leftmargin\labelsep\usecounter{enumi}}%
  \def\newblock{\hskip .11em plus .33em minus -.07em}%
  \sloppy\clubpenalty4000\widowpenalty4000%
  \sfcode`\.=1000\relax
}

to your document, the error about \newblock not being defined will go away. You can add it to the main file as in the example below, or put the above definition into your own .sty (called, say, languagebstfix.sty) and load it with \usepackage.

\documentclass[11pt,Chicago]{uuthesis}

% to make a self-contained example, we can use this package, which
% lets us create a bibliography file with the same name (except for
% the '.bib' extension) as the main file.
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{Levon07,
author = {Levon, Erez},
title = {{Sexuality in context}},
journal = {Language in Society},
year = {2007},
volume = {36},
pages = {533--554},
}
\end{filecontents}

\usepackage{thesis}% required by .cls
\usepackage{natbib}

%%% TAKEN FROM uuthesis2e.cls
\def\thebibliography#1{%
 \ifrawbibliography
 \else
  \newpage
  \thispagestyle{empty}%
  \addcontentsline{toc}{chapter}{REFERENCES}%
% Switch singlespace to after the heading gets printed.
  \mainheading{REFERENCES}%
  \par\removelastskip\singlespace\par\removelastskip% GBG Oct 1993
  \fixmainheadingSKIP
 \fi
  \list{[\arabic{enumi}]}%
  {\settowidth\labelwidth{[#1]}\leftmargin%
     \labelwidth\advance\leftmargin\labelsep\usecounter{enumi}}%
  \def\newblock{\hskip .11em plus .33em minus -.07em}%
  \sloppy\clubpenalty4000\widowpenalty4000%
  \sfcode`\.=1000\relax
}

\begin{document}

A citation: \citep{Levon07}


\bibliographystyle{language}
\bibliography{\jobname}

\end{document}

Note also that there is a similar .cls called uuthesis2e.cls. The differences seem superficial, but maybe it represents the 'preferred' version..?

As for this: ---

Basically I need to remove the apostrophe comma after the Author name in the citation so it doesn't look like APA style and looks like LSA style (which I think the author of the language.bst) based his code off the APAcite code and so it still retains the apostrophe. How can I remove it based on the code?

--- with recent versions of natbib, and as in the updated answer below, you can simply write:

\setcitestyle{aysep={}} 
% with older versions (< version 8), you need to leave 
% the 5th argument of `\bibpunct` empty; e.g.,
% \bibpunct{(}{)}{;}{a}{}{;}

Updated answer

Given the very custom spacing the class uses for its environments (all essentially localized versions of \list with different settings), I think it is better to forgo the class' \def of \thebibliography and use one based off of the report class, but tweaked for use with uuthesis.cls (still not sure why there is also a uuthesis2e.cls -- they seem at least mostly the same). So, here's how'd I do it:

\documentclass[11pt,Chicago,twoside]{uuthesis2e}
\usepackage{showframe}
% to make a self-contained example, we can use this package, which
% lets us create a bibliography file with the same name (except for
% the '.bib' extension) as the main file.
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{Levon07,
author = {Levon, Erez},
title = {{Sexuality in context context context context context context context context context context context context context context context}},
journal = {Language in Society},
year = {2007},
volume = {36},
pages = {533--554},
}
\end{filecontents}

\usepackage{thesis}% required by .cls
\newenvironment{thebibliography}{}{}% <-- keep natbib happy
\usepackage{natbib}
\setcitestyle{aysep={}}

%%% The following can be put into a .sty file and then loaded normally:
%%% FROM HERE:
% Set the 'hang' for the bibliography; length can be changed...
\newdimen\bibindent
\setlength\bibindent{1.5em}

% Set name for the 'thebibliography' environment
\renewcommand*{\bibname}{References}

\makeatletter % for the '@' in command names (not needed in a .sty file)

\newcommand\uuthesis@bibindent{% = \@openbib@code from natbib.sty
    \advance\leftmargin\bibindent
    \itemindent -\bibindent
    \listparindent \itemindent
    \parsep \z@
    }%
\def\newblock{\hskip .11em\@plus.33em\@minus.07em}

\renewenvironment{thebibliography}[1]
     {%
       \thispagestyle{empty}%
       \addcontentsline{toc}{chapter}{\bibname}% <-- prefix \MakeUpppercase for 'REFERENCES'
       \mainheading{\MakeUppercase\bibname}%   <-- uuthesis method
       \par\removelastskip\singlespace\par\removelastskip% GBG Oct 1993
       \fixmainheadingSKIP
       \list{}%
       {%
         \advance\leftmargin-\leftmargin
         \advance\leftmargin\bibindent
       }%
       \leftmargin\labelwidth
       \uuthesis@bibindent
       \sloppy
       \clubpenalty4000
       \@clubpenalty \clubpenalty
       \widowpenalty4000%
       \sfcode`\.\@m}
     {\def\@noitemerr
       {\@latex@warning{Empty `thebibliography' environment}}%
       \endlist}

\makeatother % make '@' inaccessible again (not needed in a .sty)
%%% TO HERE:

\begin{document}

\noindent
A citation: \citep{Levon07}


\bibliographystyle{language}
\bibliography{\jobname}

\end{document}

One thing you might want to consider, depending on how 'into' the TeX world you become, is creating your own thesis that adheres to your university's regulations. You don't need to make a whole .cls by any means, and by doing so, you will learn much more about how things fit together. Thesis requirements may often be draconian and typographically questionable, but they are usually quite easy to follow. (The difficulty is often managing to make the thing look nice despite the requirements for double-spacing, and so forth. And the danger is that it can become a sometimes-fun, sometimes-frustrating way to 'waste' time...)

  • Wow! Thank you Jon! Basically, what I mean is that the citation prints the following: (Author, Year). I need (Author Year), with NO comma. Do you know where the comma is being put it and how to remove it? Sorry, I used "apostrophe" when I meant comma. You can see how much my brain is fried from all of this! – Derronsb Feb 4 '14 at 8:16
  • Also, Jon, when I put in a longer reference it doesn't have hanging indentation. Do you know how I fix this? – Derronsb Feb 4 '14 at 9:22
  • @Derronsb -- I updated the answer. – jon Feb 4 '14 at 18:15
  • OMG!!! Thank you so so so so much! I wish I could take you out to lunch or something. This is so helpful! I like your suggestion at the end, but I just don't have enough time. I'm already behind as it is and I just don't have time to teach myself to do this stuff. I'll stick with it being ugly. At least it will look nicer than theses typed up in Word. Thanks again! – Derronsb Feb 5 '14 at 1:47
  • @Derronsb -- Glad it works. (I remember the end-of-thesis days, too, so I think you are right to focus on Getting Things Done!) – jon Feb 5 '14 at 1:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.