编辑

编辑

我使用来自的自定义 footcite 命令仅包含作者、标题和年份的内联引用

\newcommand{\customcite}[1]{\citeauthor{#1}, \citetitle{#1}, \citeyear{#1}}

我现在的问题是,当我在多张幻灯片上出现相同的参考资料时,脚注编号会增加。我希望在出现同一来源的每张幻灯片上都有相同的编号。

我发现了一些内容savefootnote,但这似乎非常复杂:Beamer:多次引用同一脚注。另外,一次只能存储一个参考文献,但我想在 2 页上各存储 3 个参考文献。

梅威瑟:

\documentclass[11pt]{beamer}
%\documentclass[handout,11pt]{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usetheme{Madrid}


% literature
% only for this example, otherwise in .bib file
\usepackage{filecontents}

\begin{filecontents}{\jobname.bib}
@article{Harshman1970,
    author = {and others Harshman, Richard A},
    doi = {10.1134/S0036023613040165},
    file = {:C$\backslash$:/Users/Isi/Documents/Research/Tensors/TensorsDocumentation/Literature/Harshman{\_}CPD.pdf:pdf},
    issn = {00360236},
    journal = {UCLA Working Papers in Phonetics},
    pages = {1--84},
    title = {{Foundations of the PARAFAC procedure: Models and conditions for an" explanatory" multimodal factor analysis}},
    volume = {16},
    year = {1970}
}
@article{Hitchcock1927,
    author = {Hitchcock, Frank L.},
    doi = {10.1002/sapm192761164},
    file = {:C$\backslash$:/Users/Isi/Documents/Research/Tensors/TensorsDocumentation/Literature/Hitchcock{\_}cpd.pdf:pdf},
    issn = {0097-1421},
    journal = {Journal of Mathematics and Physics},
    number = {1-4},
    pages = {164--189},
    title = {{The Expression of a Tensor or a Polyadic as a Sum of Products}},
    volume = {6},
    year = {1927}
}
@article{Carroll1970,
    doi = {10.1007/BF02310791},
    file = {:C$\backslash$:/Users/Isi/Documents/Research/Tensors/TensorsDocumentation/Literature/Carrol{\_}Chang{\_}CPD.pdf:pdf},
    issn = {00333123},
    journal = {Psychometrika},
    number = {3},
    pages = {283--319},
    title = {{Analysis of individual differences in multidimensional scaling via an n-way generalization of "Eckart-Young" decomposition}},
    volume = {35},
    year = {1970}
}

\end{filecontents}

\usepackage[style=verbose,backend=bibtex]{biblatex}
\addbibresource{\jobname.bib}
\newcommand{\customfootcite}[1]{\footnote{\citeauthor{#1}, \citetitle{#1}, \citeyear{#1}}}



\begin{document}
    \setbeamertemplate{navigation symbols}{}

    \begin{frame}{Slide 1\customfootcite{Harshman1970}\customfootcite{Hitchcock1927}\customfootcite{Carroll1970}}
        some text
    \end{frame}

    \begin{frame}{Slide 2\customfootcite{Harshman1970}\customfootcite{Hitchcock1927}\customfootcite{Carroll1970}}
    some figure
    \end{frame}

\end{document}

给出这个:

在此处输入图片描述

我希望第二张幻灯片再次显示数字 1,2,3(而不是 4,5,6)。

先感谢您!

答案1

我建议使用可以在参考书目中使用数字样式的数字作为脚注符号。因此,如果您想在演示文稿末尾打印参考书目,您将获得连贯的内容。

我还建议使用\DeclareCiteCommand比通常更灵活的。使用也比选项\newcommand更有用。biberbibtex

仅供记录之用,我认为您的 bib 条目的作者姓名有问题Carroll1970

因此,这是我的建议,添加一些额外的内容footnote来测试不同的风格,并添加一张额外的幻灯片来打印参考书目:

\documentclass{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

% literature
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{Harshman1970,
    author = {and others Harshman, Richard A},
    doi = {10.1134/S0036023613040165},
    issn = {00360236},
    journal = {UCLA Working Papers in Phonetics},
    pages = {1--84},
    title = {{Foundations of the PARAFAC procedure: Models and conditions for an" explanatory" multimodal factor analysis}},
    volume = {16},
    year = {1970}
}
@article{Hitchcock1927,
    author = {Hitchcock, Frank L.},
    doi = {10.1002/sapm192761164},
    issn = {0097-1421},
    journal = {Journal of Mathematics and Physics},
    number = {1-4},
    pages = {164--189},
    title = {{The Expression of a Tensor or a Polyadic as a Sum of Products}},
    volume = {6},
    year = {1927}
}
@article{Carroll1970,
    doi = {10.1007/BF02310791},
    author = {Carroll, Chang},
    issn = {00333123},
    journal = {Psychometrika},
    number = {3},
    pages = {283--319},
    title = {{Analysis of individual differences in multidimensional scaling via an n-way generalization of "Eckart-Young" decomposition}},
    volume = {35},
    year = {1970}
}
\end{filecontents}

% Change the footnote style with letters to avoid confusion.
\renewcommand{\thefootnote}{\alph{footnote}}

% Add sorting=None to keep the calling order.
\usepackage[style=numeric, sorting=none, backend=bibtex]{biblatex}
\addbibresource{\jobname.bib}

% Change the style of the printing biblio to let appear the numbers like in the footnote
\setbeamertemplate{bibliography item}{\insertbiblabel}

% Define the new cite command using the footnote
\DeclareCiteCommand{\testcommand}
    {\usebibmacro{prenote}} 
    {%
        \renewcommand{\thefootnote}{\arabic{footnote}}% Switch to footnote with numbers.
        \footnotemark[\thefield{labelnumber}]% Add the mark corresponding to the number entry.
        \footnotetext[\thefield{labelnumber}]{%  Add the footnote text with same number entry.
            \printnames{labelname}% The name 
            \setunit{\printdelim{nametitledelim}}% separator
            \printfield[citetitle]{labeltitle}% The title
            \setunit{\addperiod\space}% separator
            \printfield{year}% The year
        }%
        \renewcommand{\thefootnote}{\alph{footnote}}% Switch back to footnote with letters.
    }
    {\multicitedelim}
    {\usebibmacro{postnote}}

\DeclareCiteCommand{\secondcommand}
    {\usebibmacro{prenote}} 
    {%
        \renewcommand{\thefootnote}{\arabic{footnote}}% Switch to footnote with numbers.
        \footnotemark[\thefield{labelnumber}]% Add the mark corresponding to the number entry.
        \renewcommand{\thefootnote}{\alph{footnote}}% Switch back to footnote with letters.
    }
    {\multicitedelim}
    {\usebibmacro{postnote}}


\begin{document}
    \begin{frame}{Slide 1\testcommand{Harshman1970}\testcommand{Hitchcock1927}\testcommand{Carroll1970}}
        some text \footnote{test} 
    \end{frame}

    \begin{frame}{Slide 2\testcommand{Harshman1970}\testcommand{Hitchcock1927}\testcommand{Carroll1970}}
        some figure \footnote{test}  
    \end{frame}

    \begin{frame}{Slide 2\testcommand{Harshman1970}\testcommand{Hitchcock1927}\testcommand{Carroll1970}}
            some figure \footnote{test}  
            Some citation \secondcommand{Hitchcock1927}
    \end{frame}

    \begin{frame}[noframenumbering,plain,allowframebreaks]{References}
        \printbibliography[heading=none]
    \end{frame}

\end{document}

编辑

在同一张幻灯片上有多个引用时可以secondcommand使用。否则您将多次得到相同的脚注。

相关内容