以特定格式打印参考书目

以特定格式打印参考书目

我想要显示如图所示的书目。 图1

我想在作者姓名后面直接显示年份,并且论文标题不带“。” 我可以在 .tex 文件的序言中输入什么命令来强制执行此操作?

\documentclass {article}   
 \usepackage[round]{natbib}   
 \bibliographystyle{apalike}

  \begin{document}
  \cite{Sampson1989}
  \bibliography{my_bibtex}
  \end{document}

我的文件 my_bibtex.bib

@article{Sampson1989,
author = {Sampson, R J and Groves, W B},
year = {1989},
title = {Community structure and crime: testing social-disorganization theory},
volume = {94},
number = {4},
journal = {Am J Soc},
pages = {774}
 }

我得到的是:

在此处输入图片描述

答案1

biblatex-apa以下是获取所需内容和一些补丁的方法:

\documentclass{article}
\usepackage[style=apa]{biblatex}
\usepackage[american]{babel}
\DeclareLanguageMapping{american}{american-apa}

\usepackage{filecontents}%
\begin{filecontents*}{apabibli1.bib}
@article{Sampson1989,
author = {Sampson, R J and Groves, W B},
year = {1989},
title = {Community structure and crime: testing social-disorganization theory},
volume = {94},
number = {4},
journal = {Am J Soc},
pages = {774}
}
\end{filecontents*}

\addbibresource{apabibli1.bib}

\renewcommand*{\labelnamepunct}{\addspace}

\usepackage{xpatch}

\xpatchbibmacro{author}
{%
\newunit\newblock
}
{%
\setunit{\addspace}\newblock
}{}{}

\xpatchbibmacro{name:apa:last-first}
{%
\addcomma\addlowpenspace\mkbibnamefirst{#3}\isdot
}
{%
\addlowpenspace\mkbibnamefirst{#3}\isdot
}{}{}

\renewbibmacro*{journal+issuetitle}{%
\usebibmacro{journal}%
\setunit*{\addspace\thinspace}%
\iffieldundef{series}
{}
{\newunit
 \printfield{series}
 \setunit{\addspace}}%
\printfield{volume}%
\printfield{number}%
\setunit{\addspace}\newblock
\usebibmacro{issuename}%
\newunit}

\DeclareCiteCommand{\parencite}[\mkbibparens]
  {\renewcommand{\finalnamedelim}{\ifnum\value{liststop}>2 \finalandcomma\fi\addspace and\space}%
   \usebibmacro{cite:init}%
   \usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {}
  {\usebibmacro{postnote}%
   \usebibmacro{cite:post}}

    \AtBeginBibliography{\renewcommand*{\finalnamedelim}{%
    \ifthenelse{\value{listcount}>\maxprtauth}
      {}
      {\ifthenelse{\value{liststop}>2}
         {\addcomma\space}%
         {\addcomma\space}}}}

    \renewcommand\bibinitperiod{}
\renewcommand\bibinitdelim{}
\renewcommand\bibpagespunct{\addcolon\space}


\DeclareFieldFormat{journaltitle}{#1}
\DeclareFieldFormat[article]{volume}{\apanum{#1}}

\setlength{\bibhang}{1.2em}
\let\cite\parencite

\usepackage{hyperref} \hypersetup{ colorlinks = true, citecolor = blue,}

\begin{document}

\cite{Sampson1989}

\printbibliography

\end{document} 

在此处输入图片描述

相关内容