LaTeX Figure and Table Cheat Sheet
3302 ワード
Introduction
論文作成中に、さまざまな形式のFigureとTableを作成します.
LaTeXを使って論文を書くのは便利ですが.
簡単にdrag&dropを使ってFigureを挿入することはありません.
毎回必要なFigureの形状を考慮し,必要に応じてコードを記述する.
さまざまなタイプのサンプルFigureを整理すると、お客様に最適な形状を簡単に見つけることができます.
コードを直接インポートするのは便利なので、代表的な形式を整理する時間を割くことができます.
Figure
single-column one-figure
single-column basic table
Arraystretch:行の高さ調整機能
0.45textwidth:単列幅の0.45倍
表x:cがテキストに適した列幅を有する場合、Xは幅を最大限に分割する.
makecell:セル内で改行し、セル内でテキストを集中的に整列できます.
論文作成中に、さまざまな形式のFigureとTableを作成します.
LaTeXを使って論文を書くのは便利ですが.
簡単にdrag&dropを使ってFigureを挿入することはありません.
毎回必要なFigureの形状を考慮し,必要に応じてコードを記述する.
さまざまなタイプのサンプルFigureを整理すると、お客様に最適な形状を簡単に見つけることができます.
コードを直接インポートするのは便利なので、代表的な形式を整理する時間を割くことができます.
Figure
single-column one-figure
\begin{figure}[t]
\centering
\includegraphics[width=0.45\textwidth]{figures/figure-a.pdf}
\caption{This is figure A}
\label{fig:fig-a}
\end{figure}
single-column two-figures horizontal\begin{figure}[t]
\centering
\subfloat[Figure A]{%
\includegraphics[width=0.25\textwidth]{figures/figure-a.pdf}%
\label{fig:fig-a}%
}
\subfloat[Figure B]{%
\includegraphics[width=0.25\textwidth]{figures/figure-b.pdf}%
\label{fig:fig-b}%
}
\caption{These are figure A and B}
\label{fig:fig-ab-horizontal}
\end{figure}
single-column two-figures vertical\begin{figure}[t]
\centering
\subfloat[Figure A]{
\includegraphics[width=0.45\textwidth]{figures/figure-a.pdf}
\label{fig:fig-a}
} \\
\subfloat[Figure B]{
\includegraphics[width=0.45\textwidth]{figures/figure-b.pdf}
\label{fig:fig-b}
}
\caption{Figure A and B with vertical placement}
\label{fig:fig-ab-vertical}
\end{figure}
wide two-column three-figures\begin{figure*}[t]
\centering
\subfloat[Figure A]{
\includegraphics[width=0.33\textwidth]{figures/figure-a.pdf}
\label{fig:fig-a}
}
\subfloat[Figure B]{
\includegraphics[width=0.33\textwidth]{figures/figure-b.pdf}
\label{fig:fig-b}
}
\subfloat[Figure C]{
\includegraphics[width=0.33\textwidth]{figures/figure-c.pdf}
\label{fig:fig-c}
}
\caption{Figure A, B and C}
\label{fig:fig-abc}
\end{figure*}
wide two-column four-figures\begin{figure*}[t]
\centering
\subfloat[Figure A]{
\includegraphics[width=0.23\textwidth]{figures/figure-a.pdf}
\label{fig:fig-a}
}
\subfloat[Figure B]{
\includegraphics[width=0.23\textwidth]{figures/figure-b.pdf}
\label{fig:fig-b}
}
\subfloat[Figure C]{
\includegraphics[width=0.23\textwidth]{figures/figure-c.pdf}
\label{fig:fig-c}
}
\subfloat[Figure D]{
\includegraphics[width=0.23\textwidth]{figures/figure-d.pdf}
\label{fig:fig-d}
}
\caption{Four figures with two wide column}
\label{fig:fig-abcd}
\end{figure*}
Tablesingle-column basic table
Arraystretch:行の高さ調整機能
0.45textwidth:単列幅の0.45倍
表x:cがテキストに適した列幅を有する場合、Xは幅を最大限に分割する.
makecell:セル内で改行し、セル内でテキストを集中的に整列できます.
\begin{table}
\def\arraystretch{1.3}
\centering
\begin{tabularx}{0.45\textwidth}{|c||X|X|}
\hline
& \makecell{A} & \makecell{B} \\ \hline
row1 & \makecell{a1} & \makecell{b1} \\
row2 & \makecell{a2} & \makecell{b3} \\
row3 & \makecell{a3} & \makecell{b4} \\ \hline
\end{tabularx}
\caption{Basic Table}
\label{table:basic-table}
\end{table}
ConclusionReference
この問題について(LaTeX Figure and Table Cheat Sheet), 我々は、より多くの情報をここで見つけました https://velog.io/@odobenus/latex-cheat-sheetテキストは自由に共有またはコピーできます。ただし、このドキュメントのURLは参考URLとして残しておいてください。
Collection and Share based on the CC Protocol