我需要在 Lyx 中生成以下参考样式 -> (AKAMAI, 2013)。我在寻找生成上述参考样式的方法时遇到了很多问题。有没有人能帮助我实现这一点?我在 Windows 7 上使用 Lyx 2.0.7。
答案1
尽管设置起来有点复杂,但我建议使用 biblatex 和 LyX。然后,您可以使用文档序言中的 latex 宏自定义几乎任何内容。请参阅http://wiki.lyx.org/BibTeX/Biblatex
启用 biblatex 引用样式包。
文档设置 -> 参考书目启用 Natbib 和作者年份样式
以 LyX 方式添加参考书目(插入->列表/目录->参考书目),然后将其放在注释框中。(这可让您使用常规插入引文对话框。
将必要的行添加到文档前言中,其中包括\addbibresource
命令。请注意,“natbib=true”对于允许使用 LyX 的引用对话框至关重要。
在序言中自定义作者的姓名。
如果您想使用 biber,请确保在序言和参考书目设置中都选择它作为处理器。
您可以使用 ERT 中的命令在文档中插入参考书目\printbibliography
。
下面是一个最小的例子:
#LyX 2.1 created this file. For more info see http://www.lyx.org/
\lyxformat 474
\begin_document
\begin_header
\textclass article
\begin_preamble
\usepackage[style=authoryear,backend=biber,natbib=true]{biblatex}
\addbibresource{/usr/share/texlive/texmf-dist/bibtex/bib/biblatex/biblatex/biblatex-examples.bib}
%%%%%%%%
% Capitalise author's name
\renewcommand*{\mkbibnamelast}[1]{\MakeUppercase{#1}}
\end_preamble
\use_default_options true
\begin_modules
biblatex
\end_modules
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding auto
\fontencoding global
\font_roman default
\font_sans default
\font_typewriter default
\font_math auto
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100
\graphics default
\default_output_format default
\output_sync 0
\bibtex_command biber
\index_command default
\paperfontsize default
\spacing single
\use_hyperref false
\papersize default
\use_geometry false
\use_package amsmath 1
\use_package amssymb 1
\use_package cancel 1
\use_package esint 1
\use_package mathdots 1
\use_package mathtools 1
\use_package mhchem 1
\use_package stackrel 1
\use_package stmaryrd 1
\use_package undertilde 1
\cite_engine natbib
\cite_engine_type authoryear
\biblio_style plainnat
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\justification true
\use_refstyle 1
\index Index
\shortcut idx
\color #008000
\end_index
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\paragraph_indentation default
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header
\begin_body
\begin_layout Standard
Enable biblatex citation styles package.
\end_layout
\begin_layout Standard
Document settings ->Bibliography enable Natbib and author-year style
\end_layout
\begin_layout Standard
Add the bibliography the LyX way (Insert->List/TOC->Bibliography) and then
put it in a Note box.
(This lets you use the normal insert citation dialog.
\end_layout
\begin_layout Standard
Add the necessary lines to you document preamble, which includes the `
\backslash
addbibresource` command.
Note that
\begin_inset Quotes eld
\end_inset
natbib=true
\begin_inset Quotes erd
\end_inset
is essential to allow the use of LyX
\begin_inset Quotes ers
\end_inset
s citation dialog.
\end_layout
\begin_layout Standard
Customise the author
\begin_inset Quotes ers
\end_inset
s name in the preamble.
\end_layout
\begin_layout Standard
If you want to use biber, make sure to select that as the processor both
in the preamble and in the Bibliography settings.
\end_layout
\begin_layout Standard
You insert the bibliography in the document by using the `
\backslash
printbibliography` command in ERT.
\end_layout
\begin_layout Standard
\begin_inset CommandInset citation
LatexCommand citet
key "doody"
\end_inset
\begin_inset CommandInset citation
LatexCommand citep
key "doody"
\end_inset
\end_layout
\begin_layout Standard
Check out the LyX wiki
\begin_inset Flex URL
status open
\begin_layout Plain Layout
http://wiki.lyx.org/BibTeX/Biblatex
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset ERT
status open
\begin_layout Plain Layout
\backslash
printbibliography
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset Note Note
status open
\begin_layout Plain Layout
\begin_inset CommandInset bibtex
LatexCommand bibtex
bibfiles "/usr/share/texlive/texmf-dist/bibtex/bib/biblatex/biblatex/biblatex-examples"
options "apa"
\end_inset
\end_layout
\end_inset
\end_layout
\end_body
\end_document