我有一个包含多列的复杂表格。我认为我不能使用它,\seqsplit
因为它是一个表格环境(在 内tabularx
)。我试过了\newline
,\hline
但它也没有用。
\documentclass{article}
\usepackage{tabularx, seqsplit}
\usepackage{multirow}
\usepackage{booktabs}
\begin{document}
\begin{table}[h!]
\centering
\begin{tabularx}{\textwidth}{llX}
\hline
\textbf{PCR} & \textbf{Template} & \textbf{Primers} \\
\hline
\textit{\#1} & 355. Pdat-1+intron & \begin{tabular}{@{}l@{}}
\seqsplit{GCCTATTCCAGTATGACCCCTTTGAA}\\
\addlinespace
AGATACGGGTTTCACTTTTTCTACCGGTACCCTCCAAGG\\
\end{tabular}\\
\hline
\textit{\#2} & 399.Pdat-1::SEC-24.2::mKate::UTR & \begin{tabular}{@{}l@{}}
TACCGGTAGAAAAAGTGAAACCCGTATCTCAAATCCCAAATGG\\
\addlinespace
TTTGGATCAACATGAGCATTCGGATTCGC\\
\end{tabular}
\\
\hline
\textit{Fusion} & Products from PCR\#1 and \#2 & \begin{tabular}{@{}l@{}}
GCCTATTCCAGTATGACCCCTTTGAA\\
\addlinespace
TTTGGATCAACATGAGCATTCGGATTCGC\\
\end{tabular}
\\
\hline
\end{tabularx}
\caption{Primers}
\label{tab:Primers_CSKD}
\end{table}
\end{document}
答案1
一个可能的解决方案是\makecell
从\makecell package
。
离题:在我看来,您应该尝试减少 PCR 和模板列的空间,以便将整个引物序列(大部分)放在一行上,或者至少给出方向(5'-3'端)。
\documentclass{article}
\usepackage{tabularx,seqsplit}
\usepackage{multirow}
\usepackage{makecell}
\usepackage{booktabs}
\begin{document}
\renewcommand{\arraystretch}{2}
\begin{table}[h!]
\centering
\begin{tabularx}{\textwidth}{@{} llX @{}}
\hline
\textbf{PCR} & \textbf{Template} & \textbf{Primers} \\
\hline
\textit{\#1} & 355. Pdat-1+intron & \begin{tabular}{@{}l@{}}
\makecell[l]{GCCTATTCCAGTATGACC\\CCTTTGAA}\\
\addlinespace
\makecell[l]{AGATACGGGTTTCACTTT\\TTCTACCGGTACCCTCCA\\AGG}\\
\end{tabular}\\
\hline
\textit{\#2} & 399.Pdat-1::SEC-24.2::mKate::UTR & \begin{tabular}{@{}l@{}}
\makecell[l]{TACCGGTAGAAAAAGTGA\\AACCCGTATCTCAAATCC\\CAAATGG}\\
\addlinespace
\makecell[l]{TTTGGATCAACATGAGCA\\TTCGGATTCGC}\\
\end{tabular}
\\
\hline
\textit{Fusion} & Products from PCR\#1 and \#2 & \begin{tabular}{@{}l@{}}
\makecell[l]{GCCTATTCCAGTATGACCC\\CTTTGAA} \\
\addlinespace
\makecell[l]{TTTGGATCAACATGAGCAT\\TCGGATTCGC} \\
\end{tabular}
\\
\hline
\end{tabularx}
\caption{Primers}
\label{tab:Primers_CSKD}
\end{table}
\end{document}