我有這個代碼,我想按字母順序排列:
\section{Abbreviations}
\doublespacing
\begin{tabular}{p{4cm}p{12cm}}
\textbf{AD} & Alzheimer's disease \\
\textbf{FAD} & Familial Alzheimer's disease \\
\textbf{LOAD} & Late-onset Alzheimer's disease \\
\textbf{A\textbeta\ } & Amyloid- \textbeta\ \\
\textbf{APP} & Amyloid precursor protein \\
\textbf{GWAS} & Genome-wide-association studies \\
\textbf{SNP} & Single nucleotide polymorphisms \\
\textbf{CXCL10} & C-X-C motif chemokine 10 \\
\textbf{OAS1} & 2’-5’-oligoadenylate synthase 1\\
\textbf{TREM2} & Triggering receptor expressed on myeloid cells 2 \\
\textbf{R47H KI} & \textit{Trem2} R47H knock-in mice \\
\textbf{APP KI} & \textit{APP\textsuperscript{NL-G-F}} knock-in mice \\
\textbf{WT} & Wild type \\
\textbf{HO} & Homozygous \\
\textbf{HET} & Heterozygous \\
\textbf{P1-P3} & Postnatal day 1-3\\
\textbf{RT-qPCR} & Real-time Quantitative PCR \\
\textbf{CT} & Cycle threshold \\
\textbf{IHC} & Immunohistochemistry \\
\textbf{PBS} & Phosphate-buffered saline \\
\textbf{PBST} & Phosphate-buffered saline 0.3\% Triton \\
\textbf{TBS} & Tris-buffered saline \\
\textbf{TBST} & Tris-buffered saline 0.1\% Tween-20 \\
\end{tabular}
我怎樣才能做到這一點?非常感謝您的幫忙。謝謝!
答案1
首先,刪除所有\textbf{}
.載入大批並使用此指令>{\bfseries}
將第一列設為粗體。
然後,查看您的文字編輯器是否具有行排序功能,標記所有要排序的行,然後對它們進行排序。如果沒有,請將這些行複製到文字處理程式或電子表格中,或將這些行儲存為文字文件,並透過作業系統命令提示字元(Windows 命令列sort < tobesort.txt > sorted.txt
)中的排序篩選器進行管道傳輸,然後進行排序。
您必須檢查您語言的 ISO 排序規則來決定希臘字母的放置位置。在挪威語中,Aβ
被排序為以 開頭的最後一行A
。
除非你有幾十個相似的表格需要排序,否則這種方法是最簡單、最快的,如果沒有人提供可以根據你的語言要求進行排序的排序演算法。
\documentclass{article}
\usepackage{array}
\begin{document}
\section{Abbreviations}
\begin{tabular}{@{}>{\bfseries}p{4cm}p{12cm}@{}}
AD & Alzheimer's disease \\
APP & Amyloid precursor protein \\
APP KI & \textit{APP\textsuperscript{NL-G-F}} knock-in mice \\
A\boldmath{$\beta$}\ & Amyloid-$\beta$\ \\
CT & Cycle threshold \\
CXCL10 & C-X-C motif chemokine 10 \\
FAD & Familial Alzheimer's disease \\
GWAS & Genome-wide-association studies \\
HET & Heterozygous \\
HO & Homozygous \\
IHC & Immunohistochemistry \\
LOAD & Late-onset Alzheimer's disease \\
OAS1 & 2’-5’-oligoadenylate synthase 1\\
P1-P3 & Postnatal day 1-3\\
PBS & Phosphate-buffered saline \\
PBST & Phosphate-buffered saline 0.3\% Triton \\
R47H KI & \textit{Trem2} R47H knock-in mice \\
RT-qPCR & Real-time Quantitative PCR \\
SNP & Single nucleotide polymorphisms \\
TBS & Tris-buffered saline \\
TBST & Tris-buffered saline 0.1\% Tween-20 \\
TREM2 & Triggering receptor expressed on myeloid cells 2 \\
WT & Wild type \\
\end{tabular}
\end{document}