按照第一作者、年份、合著者使用自己的书目样式进行排序

按照第一作者、年份、合著者使用自己的书目样式进行排序

我正在尝试重新整理我的参考书目,但我被难住了。最后应该按字母顺序排列,先是第一作者,然后是年份,然后是合著者,如果年份相同,则应使用ab

目前,字母排序有点扭曲,但我无法弄清楚 LateX 如何对 bibitems 进行排序。

图形化地演示一下我的意思: 在此处输入图片描述

bbx 文件:

% $Id: ulm.bbx,v 0.1 2013/06/28 19:09:07 lehman unstable $

\ProvidesFile{ulm.bbx}
[\abx@bbxid $Id: ulm.bbx,v 0.1 2013/06/28 19:09:07 lehman unstable $]

\newbibmacro*{begentry}{}
\newbibmacro*{finentry}{\finentry}

\DeclareBibliographyDriver{article}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author/translator+others}%
  \setunit{\labelnamepunct}\newblock
  \usebibmacro{title}%
  \newunit\newblock
  \usebibmacro{journal+issuetitle}%
  \addcolon
  \usebibmacro{note+pages}%
  \newblock
  \usebibmacro{date}
%  \setunit{\bibpagerefpunct}\newblock
%  \usebibmacro{pageref}%
  \usebibmacro{finentry}}



\DeclareBibliographyDriver{book}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author/editor+others/translator+others}%
  \setunit{\labelnamepunct}\newblock
  \usebibmacro{maintitle+title}%
  \newunit\newblock
  \ifnameundef{editor}
      {}
      {
       \usebibmacro{in:}%
       \setunit{\addspace}
       \printnames{editor}%
       \setunit{\addspace}%
       \printtext{(Hrsg)}%
       \addspace%
       \usebibmacro{title}%
       \newblock}%
  \newunit\newblock
  \printfield{edition}%
  \newunit\newblock
  \usebibmacro{publisher+location}%
  \newunit\newblock
  \usebibmacro{chapter+pages}%
  \addspace
  \usebibmacro{date}%
  \usebibmacro{finentry}}

\DeclareBibliographyDriver{incollection}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author/editor+others/translator+others}%
  \setunit{\labelnamepunct}\newblock
  \usebibmacro{maintitle+title}%
  \newunit\newblock
  \ifnameundef{editor}
      {}
      {
       \usebibmacro{in:}%
       \setunit{\addspace}
       \printnames{editor}%
       \setunit{\addspace}%
       \printtext{(Hrsg)}%
       \newblock}%
  \addspace\newblock
  \printfield{series}
  \newunit\newblock
  \printfield{volume}
  \newunit\newblock
  \printfield{edition}%
  \newunit\newblock
  \usebibmacro{publisher+location}%
  \newunit\newblock
  \usebibmacro{chapter+pages}%
  \addspace
  \usebibmacro{date}%
  \usebibmacro{finentry}}

\DeclareBibliographyDriver{online}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \usebibmacro{author/translator+others}%
  \setunit{\labelnamepunct}\newblock
  \printfield{url}
  \newblock
  \printfield{note} %ich konnte mit meiner Literaturverwaltung nicht urldate mitangeben. Richtig wäre die Angabe \printfield{urldate}. Ggf. muss man das noch durch ein Makro in Klammern setzen.
  \usebibmacro{finentry}}

\DeclareBibliographyAlias{mvbook}{book}
\DeclareBibliographyAlias{bookinbook}{inbook}
\DeclareBibliographyAlias{suppbook}{inbook}
\DeclareBibliographyAlias{mvcollection}{collection}
\DeclareBibliographyAlias{suppcollection}{incollection}
\DeclareBibliographyAlias{mvproceedings}{proceedings}
\DeclareBibliographyAlias{reference}{collection}
\DeclareBibliographyAlias{mvreference}{reference}
\DeclareBibliographyAlias{inreference}{incollection}
\DeclareBibliographyAlias{suppperiodical}{article}
\DeclareBibliographyAlias{review}{article}
\DeclareBibliographyAlias{*}{misc}

\newbibmacro*{maintitle+title}{%
  \iffieldsequal{maintitle}{title}
    {\clearfield{maintitle}%
     \clearfield{mainsubtitle}%
     \clearfield{maintitleaddon}}
    {\iffieldundef{maintitle}
       {}
       {\usebibmacro{maintitle}%
    \newunit\newblock
    \iffieldundef{volume}
      {}  \usebibmacro{series+number}%
        \newunit\newblock
        \printfield{note}%
        \newunit\newblock
      {\printfield{volume}%
           \printfield{part}%
           \setunit{\addcolon\space}}}}%
  \usebibmacro{title}%
  \newunit}

\newbibmacro*{maintitle+booktitle}{%
  \iffieldundef{maintitle}
    {}
    {\usebibmacro{maintitle}%
     \newunit\newblock
     \iffieldundef{volume}
       {}
       {\printfield{volume}%
        \printfield{part}%
        \setunit{\addcolon\space}}}%
  \usebibmacro{booktitle}%
  \newunit}

\newbibmacro*{journal+issuetitle}{%
  \usebibmacro{journal}%
  \setunit*{\addspace}%
  \iffieldundef{series}
    {}
    {\newunit
     \printfield{series}%
     \setunit{\addspace}}%
  \usebibmacro{volume}%
%  \setunit{\addspace}%
%  \usebibmacro{issue}%
  \setunit{\addcolon\space}%
  \newunit}

\newbibmacro*{volume}{%
  \printfield{volume}%
  \setunit*{\addcolon}%
  }

\newbibmacro*{title+issuetitle}{%
  \usebibmacro{periodical}%
  \setunit*{\addspace}%
  \iffieldundef{series}
    {}
    {\newunit
     \printfield{series}%
     \setunit{\addspace}}%
  \printfield{volume}%
  \setunit*{\adddot}%
  \printfield{number}%
  \setunit{\addcomma\space}%
  \printfield{eid}%
  \setunit{\addspace}%
  \usebibmacro{issue}%
  \setunit{\addcolon\space}%
  \usebibmacro{issue}%
  \newunit} 

\renewbibmacro*{issue}{%
  \iffieldundef{issue}
      {}
    {\printtext[parens]{%
      {\printfield{issue}%
       \setunit*{\addspace}}}%
  \newunit}}

\newbibmacro*{series+number}{%
  \printfield{series}%
  \setunit*{\addspace}%
  \printfield{number}%
  \newunit}

\newbibmacro*{publisher+location}{%
    \iflistundef{publisher}
    {}
  \printlist{publisher}%
  \setunit*{\addcomma\space}
  \printlist{location}%
  \setunit*{\addcomma\space}%
  \newunit}

\newbibmacro*{institution+location+date}{%
  \printlist{location}%
  \iflistundef{institution}
    {\setunit*{\addcomma\space}}
    {\setunit*{\addcolon\space}}%
  \printlist{institution}%
%  \setunit*{\addcomma\space}%
%  \usebibmacro{date}%
  \newunit}

\newbibmacro*{organization+location+date}{%
  \printlist{location}%
  \iflistundef{organization}
    {\setunit*{\addcomma\space}}
    {\setunit*{\addcolon\space}}%
  \printlist{organization}%
%  \setunit*{\addcomma\space}%
%  \usebibmacro{date}%
  \newunit}

\newbibmacro*{location+date}{%
  \printlist{location}%
%  \setunit*{\addcomma\space}%
%  \usebibmacro{date}%
  \newunit}

\newbibmacro*{chapter+pages}{%
%  \printfield{chapter}%
%  \setunit{\addcomma\space}
  \usebibmacro{S.}
  \setunit{\bibpagespunct}%
  \printfield{pages}%
  \addspace}

\newbibmacro*{note+pages}{%
%  \printfield{note}%
  \setunit{\bibpagespunct}%
  \printfield{pages}%
  \addspace}

\ExecuteBibliographyOptions{labelnumber}

\providebool{bbx:subentry}

\DeclareBibliographyOption{subentry}[true]{%
  \setbool{bbx:subentry}{#1}}

\DeclareNameAlias{author}{default}
\DeclareNameAlias{editor}{default}
\DeclareNameAlias{translator}{default}

\DeclareFieldFormat{bibentrysetcount}{\mkbibparens{\mknumalph{#1}}}
\DeclareFieldFormat{labelnumberwidth}{\mkbibbrackets{#1}}
\DeclareFieldFormat{shorthandwidth}{\mkbibbrackets{#1}}

\defbibenvironment{bibliography}
  {\list
     {\printtext[labelnumberwidth]{%
    \printfield{prefixnumber}%
    \printfield{labelnumber}}}
     {\setlength{\labelwidth}{\labelnumberwidth}%
      \setlength{\leftmargin}{\labelwidth}%
      \setlength{\labelsep}{\biblabelsep}%
      \addtolength{\leftmargin}{\labelsep}%
      \setlength{\itemsep}{\bibitemsep}%
      \setlength{\parsep}{\bibparsep}}%
      \renewcommand*{\makelabel}[1]{\hss##1}}
  {\endlist}
  {\item}

\defbibenvironment{shorthands}
  {\list
     {\printfield[shorthandwidth]{shorthand}}
     {\setlength{\labelwidth}{\shorthandwidth}%
      \setlength{\leftmargin}{\labelwidth}%
      \setlength{\labelsep}{\biblabelsep}%
      \addtolength{\leftmargin}{\labelsep}%
      \setlength{\itemsep}{\bibitemsep}%
      \setlength{\parsep}{\bibparsep}%
      \renewcommand*{\makelabel}[1]{\hss##1}}}
  {\endlist}
  {\item}

\DeclareBibliographyDriver{set}{%
  \entryset
    {\ifbool{bbx:subentry}
       {\printfield[bibentrysetcount]{entrysetcount}%
    \setunit*{\addnbspace}}
       {}}
    {}%
  \newunit\newblock
  \usebibmacro{setpageref}%
  \finentry}

\def\MKbibnamefirst#1{\expandafter\mkbibnamefirst@i#1..\@nil}
\def\mkbibnamefirst@i#1.#2.#3\@nil{#1}

\renewbibmacro*{name:last-first}[4]{%
  \ifuseprefix
    {\usebibmacro{name:delim}{#3#1}%
     \usebibmacro{name:hook}{#3#1}%
     \ifblank{#3}{}{%
       \ifcapital
         {\mkbibnameprefix{\MakeCapital{#3}}\isdot}
     {\mkbibnameprefix{#3}}%
       \ifpunctmark{'}{}{\addhighpenspace}}%
     \mkbibnamelast{#1}\isdot
     \ifblank{#4}{}{\addlowpenspace\mkbibnameaffix{#4}\isdot}%
     \ifblank{#2}{}{\addlowpenspace\mkbibnamefirst{#2}}}
    {\usebibmacro{name:delim}{#1}%
     \usebibmacro{name:hook}{#1}%
     \mkbibnamelast{#1}\isdot
     \ifblank{#4}{}{\addlowpenspace\mkbibnameaffix{#4}\isdot}%
%     \ifblank{#2#3}{}{\addcomma}%
     \ifblank{#2}{}{\addlowpenspace\MKbibnamefirst{#2}}%
%     \ifblank{#3}{}{\addlowpenspace\mkbibnameprefix{#3}\isdot}
}}

\DeclareFieldFormat{parens}{\mkbibparens{#1}}
\renewbibmacro*{date}{\printtext[parens]{\printdate}}

\renewcommand*{\multilistdelim}{\addslash }

\renewbibmacro*{finentry}{}

\newbibmacro*{S.}{%
  \printtext{S.}}


\renewbibmacro*{in:}{%
  \printtext{In:%
%    \bibstring{In}
    \intitlepunct}}

\endinput

cbx 文件

% $Id: verbose-inote.cbx,v 1.7 2011/11/13 19:09:07 lehman stable $

\ProvidesFile{ulm.cbx}
[\abx@cbxid $Id: verbose-inote.cbx,v 1.7 2011/11/13 19:09:07 lehman stable $]

\ExecuteBibliographyOptions{labelnumber,sortcites,autocite=inline}
\renewcommand*{\multicitedelim}{\addcomma\space}
\providebool{bbx:subentry}
\DeclareFieldFormat[article,book,collection,inbook,incollection,inproceedings,patent,thesis,unpublished]{title}{#1\addperiod}
\DeclareFieldFormat[article]{journaltitle}{#1}

\DeclareNameAlias{default}{last-first}
\renewcommand{\labelnamepunct}{\addcolon\space}
\AtEveryBibitem{\clearfield{month}}
%\renewbibmacro{in:}{}
\renewcommand*{\finalnamedelim}{%
  \ifbibliography% NEW
    {\addcomma\space}% NEW
    {\ifnumgreater{\value{liststop}}{2}{\finalandcomma}{}%
        \addspace\bibstring{and}\space}}
\DeclareFieldFormat[book]{year}{\mkbibquote{#1\isdot}}

\DeclareFieldFormat{pages}{#1\isdot}

\DeclareFieldFormat{entrysetcount}{\mknumalph{#1}}
\newbibmacro*{cite}{%
  \printtext[bibhyperref]{%
    \printfield{prefixnumber}%
    \printfield{labelnumber}%
    \ifbool{bbx:subentry}
      {\printfield{entrysetcount}}
      {}}}

\newbibmacro*{textcite}{%
  \iffieldequals{namehash}{\cbx@lasthash}
    {\multicitedelim}
    {\cbx@tempa
     \ifnameundef{labelname}
       {\printfield[citetitle]{labeltitle}}
       {\printnames{labelname}}%
     \addspace\bibopenbracket}%
  \ifnumequal{\value{citecount}}{1}
    {\usebibmacro{prenote}}
    {}%
  \usebibmacro{cite}%
  \savefield{namehash}{\cbx@lasthash}%
  \gdef\cbx@tempa{\bibclosebracket\multicitedelim}}

\DeclareCiteCommand{\cite}[\mkbibbrackets]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\parencite}[\mkbibbrackets]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\footcite}[\mkbibfootnote]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\footcitetext}[\mkbibfootnotetext]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\smartcite}[\iffootnote\mkbibbrackets\mkbibfootnote]
  {\usebibmacro{prenote}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\textcite}
  {\let\cbx@tempa=\empty
   \undef\cbx@lasthash}
  {\usebibmacro{citeindex}%
   \usebibmacro{textcite}}
  {}
  {\usebibmacro{postnote}%
   \bibclosebracket}

\DeclareCiteCommand{\supercite}[\mkbibsuperscript]
  {\iffieldundef{prenote}
     {}
     {\BibliographyWarning{Ignoring prenote argument}}%
   \iffieldundef{postnote}
     {}
     {\BibliographyWarning{Ignoring postnote argument}}}
  {\usebibmacro{citeindex}%
   \usebibmacro{cite}}
  {\supercitedelim}
  {}

\DeclareMultiCiteCommand{\cites}[\mkbibbrackets]{\cite}{\multicitedelim}
\DeclareMultiCiteCommand{\parencites}[\mkbibbrackets]{\parencite}{\multicitedelim}
\DeclareMultiCiteCommand{\smartcites}[\iffootnote\mkbibbrackets\mkbibfootnote]{\smartcite}{\multicitedelim}

\DeclareFieldFormat{edition}{%
  \ifinteger{#1}
    {\mkbibordedition{#1}~\printtext{Aufl}}
    {#1}}

\renewcommand\mkbibnamelast[1]{\textsc{#1}} %Autor/Editorname in small caps
\renewcommand*{\newunitpunct}{\addcomma\addspace}

\endinput

梅威瑟:

\documentclass{scrreprt}
\usepackage[latin1]{inputenc}
\usepackage[
bibstyle=ulm, citestyle=ulm, maxbibnames=99,
]{biblatex}

\begin{filecontents*}{books.bib}
@ARTICLE{Jager2012a,
  author = {J\"ager, M. and Lang, F. and Frasch, K. and Becker, T.},
  title = {Schizophrene Psychosen mit bipolarem Verlauf -- Implikationen f\"ur
    Nosologie und Therapie},
  journal = {Fortschr Neurol Psychiatr},
  year = {2012},
  volume = {80},
  pages = {520--526},
  number = {09},
}

@ARTICLE{Jager2012b,
  author = {J\"ager, Markus and Lang, Fabian and Frasch, Karel and Becker, Thomas},
  title = {Schizophrenie und aggressives Verhalten -- die Bedeutung katatoner
    Ph\"anomene},
  journal = {Psychiatr Prax},
  year = {2012},
  volume = {39},
  pages = {84--90},
  number = {02},
}

@ARTICLE{Lang2012,
  author = {F. Lang and M. K\"osters and S. Lang and T. Becker and M. J\"ager},
  title = {Psychopathological long-term outcome of schizophrenia -- a review.},
  journal = {Acta Psychiatr Scand},
  year = {2012},
  pages = {173--182},
  month = {11},
}

@ARTICLE{Lang2012a,
  author = {Lang, F.U. and Klug, R. and Kunath, M. and Palm, C. and Uttner, I.
    and J\"ager, M.},
  title = {Fr\"uhe Demenz als Leitsyndrom einer Schizophrenie},
  journal = {Nervenarzt},
  year = {2012},
  pages = {1--4},
  publisher = {Springer-Verlag},

}

@ARTICLE{Lang2013,
  author = {Lang, F. U. AND Lang, S. AND Becker, T. AND J\"ager, M.},
  title = {Therapieresistente schizophrene Psychosen},
  journal = {Dtsch Z Nervenheilkd},
  year = {2013},
  volume = {3},
  pages = {145--149},
}


\end{filecontents*}

\bibliography{books.bib}

\begin{document}
\cite{Jager2012a}
\cite{Jager2012b}
\cite{Lang2012}
\cite{Lang2012a}
\cite{Lang2013}

\printbibliography
\end{document}

我已经阅读了 biblatex 手册,但我唯一找到的是sorting=nyt,但它不起作用,因为我没有使用 biber。

答案1

就像我在第一条评论中说的那样,我在参考书目中添加了一个字母,例如2012 a2012 b 我通过引入更正的三个 Lang 条目的错误排序sortname={LangX} X是排序号。有了它,sortkey我就必须在我原来的 = 非 MWE 参考书目中定义更多的排序键。

\documentclass{scrreprt}
\usepackage[latin1]{inputenc}
\usepackage[
bibstyle=ulm, citestyle=ulm, maxbibnames=99,
]{biblatex}

\begin{filecontents*}{books2.bib }
@ARTICLE{Jager2012a,
  author = {J\"ager, M. and Lang, F. and Frasch, K. and Becker, T.},
  title = {Schizophrene Psychosen mit bipolarem Verlauf -- Implikationen f\"ur
    Nosologie und Therapie},
  journal = {Fortschr Neurol Psychiatr},
  year = {2012 a},
  volume = {80},
  pages = {520--526},
  number = {09},
}

@ARTICLE{Jager2012b,
  author = {J\"ager, Markus and Lang, Fabian and Frasch, Karel and Becker, Thomas},
  title = {Schizophrenie und aggressives Verhalten -- die Bedeutung katatoner
    Ph\"anomene},
  journal = {Psychiatr Prax},
  year = {2012 b},
  volume = {39},
  pages = {84--90},
  number = {02},
}

@ARTICLE{Lang2012,
  author = {F. Lang and M. K\"osters and S. Lang and T. Becker and M. J\"ager},
  title = {Psychopathological long-term outcome of schizophrenia -- a review.},
  journal = {Acta Psychiatr Scand},
  year = {2012},
  pages = {173--182},
  month = {11},
  sortname = {Lang2}
}

@ARTICLE{Lang2012a,
  author = {Lang, F.U. and Klug, R. and Kunath, M. and Palm, C. and Uttner, I.
    and J\"ager, M.},
  title = {Fr\"uhe Demenz als Leitsyndrom einer Schizophrenie},
  journal = {Nervenarzt},
  year = {2012},
  pages = {1--4},
  publisher = {Springer-Verlag},
  sortname = {Lang1}

}

@ARTICLE{Lang2013,
  author = {Lang, F. U. AND Lang, S. AND Becker, T. AND J\"ager, M.},
  title = {Therapieresistente schizophrene Psychosen},
  journal = {Dtsch Z Nervenheilkd},
  year = {2013},
  volume = {3},
  pages = {145--149},
  sortname = {Lang3}
}


\end{filecontents*}

\bibliography{books2.bib }

\begin{document}
\cite{Jager2012a}
\cite{Jager2012b}
\cite{Lang2012}
\cite{Lang2012a}
\cite{Lang2013}

\printbibliography
\end{document}

相关内容