减少过长表格的宽度

减少过长表格的宽度

如何减少工具长表的宽度?

\documentclass[review]{elsarticle}
\usepackage[font={normalsize}]{caption}
\usepackage[para,flushleft]{threeparttable}
\usepackage{amsmath}
\usepackage{setspace}
\usepackage{mathtools}
\usepackage{tabularx}
\usepackage{float}
\usepackage{makecell}
\usepackage{multirow}
\usepackage[table,xcdraw]{xcolor}

\begin{document}

    \setlength{\tabcolsep}{1pt}
\begin{table}[H]
\centering
\caption{Summary of the relevant state of the art}
\begin{tabular}{lllllll}
\hline
 Independent variables & Target variable & Data records & Train/test(\%) & Model & Metrics & Reference \\ \hline
 Critical energy release rate , unnotched strength, young modulus, hole diameter, width, stacking sequences& Tensile strength & 10000 & 90/10 & XGBoost, Random Forests, Gaussian Processes and Artificixxxxxxxxal Networks & RMSE = 0.005 &  Furtado et al. furtado2021methodology\\
 Young modulus, Damagxxxxxx strain, saturation strain, damage curve angle& force-pin opening displacement curve & 15000 & 70/30 & Theory-guided neural network architecture, recurrent neural networks wxxxxx Short-Term Memory (LSTM) architecture  & RMSE=0.266 & Reiner et al. reiner2021machine \\
 particle size, cuxxxxxx,power level, volume fraction, curing angle& optimum tensile strength  & 46 &  78.26/21.74 & Adaptixxxxxxxrk-based Fuzzy Inference System , Artificial Neural Networks  & RMSE=0.0307, MAE=0.0098, $R^2$=0.99, RMSE=0.0827 & Okafor et al. okafor2021evaluation \\
 crack position , pattern type , loading angle,
sample thickness, crack length& Fracture toughness & 200 & 80/20 & KNN, DT, RF, SVM & RMSE=35.49, MAE=26.48, EP=7.45, $R^2$=0.95 &  Balcıoğlu et al. \cite{balciouglu2021comparison}\\
stacking sequence, thickness & buckling load, ultimate load & 4367 & 75/25  & ANN & RMSE =  3.03E-06 & Sun et alsun2021prediction\\
 Elastic modulus, Poisson's ratio, fiber volume fraction, fiber aspect ratio& stiffness & 1015 & 75/25 & ANN & RMSE= 0.03 & Breuer et al.breuer2021prediction \\
 fiber content , hold time, molding pressure, and hold temperature&  Impact toughness&30  & 66.6/33.3&Gaussian process regression, DT, Ensemble, SVR, LR  & $R^2$=0.96, RMSE= 0.4369, MAE=0.3265 & Zhang et al. zhang2021machine \\
 fiber content , hold time, molding pressure, and hold temperature& Tensile strength &  30& 66.6/33.3 & Gaussian process regression, DT, Ensemble, SVR, LR & $R^2$=0.99, RMSE= 0.08, MAE=0.06 &  Zhang et al. zhang2021machine \\
 Fiber diameter, Embedded length, Young’s modulus, Poisson’s ratio, Loading rate, Preparation and test temperature & Maximum force , Interfacial shear strength & 922 & 88/12& LR, BR, EN, SVR, GBR, ANN & RMSE=0.131, $R^2$=0.735 & Yin et al. yin2021machine \\
 Length, Width, Thickness, Hole configuration, Circle radius, Hole radius, Force, Stacking Sequence&  Maximum tensile Stress & 8960 &  1/99 & Stacked models & $R^2$=0.97  & This study \\ \hline
\end{tabular}
\label{SART}
\end{table}


\end{document}

答案1

您可以拆分过长的条目;在行之间添加一些垂直空间将有助于使表格适合。

我添加了一些其他建议,请留意<---

\documentclass[review]{elsarticle}
%\documentclass[1p]{elsarticle}
%\usepackage{geometry}% <--- use the style elsarticle wants
%\usepackage{epsfig}% <--- obsolete
%\usepackage{latexsym}% <--- obsolete
\usepackage[font={normalsize}]{caption}
\usepackage[para,flushleft]{threeparttable}
\usepackage{booktabs}
%\usepackage{nicematrix}
\usepackage{amsmath}
\usepackage{fullpage}
%\usepackage{setspace}% <--- use the style elsarticle wants
\usepackage{mathtools}
%\usepackage{fancyhdr}% <--- use the style elsarticle wants
%\usepackage{sectsty}% <--- not with elsarticle
\usepackage{siunitx}
\usepackage{tabularx}
%\usepackage{float}% <--- don't use [H]
%\usepackage{indentfirst}% <--- use the style elsarticle wants
\usepackage{changepage}
\usepackage{adjustbox}
\usepackage{tabularx}
\usepackage{rotating}
\usepackage{makecell}
\usepackage{subcaption}
\usepackage{rotating}
%\usepackage{subfigure}% <--- obsolete and incompatible with subcaption

% packages for tables
\usepackage{multirow}
\usepackage[table,xcdraw]{xcolor}
\usepackage{graphicx}
%\usepackage{graphics}% <--- obsolete
%\usepackage{caption}% <--- duplication

\renewcommand{\TPTtagStyle}{\textit}

\newcommand{\splitcell}[1]{\begin{tabular}{@{}c@{}}#1\end{tabular}}

\begin{document}

\begin{table}[htp]
\centering

%\setlength{\tabcolsep}{2pt} % <--- should be local, anyway

\caption{Summary of the relevant state of the art}
\label{SART}% <--- the label refers to the caption

\begin{tabular}{@{}ccccccl@{}}
\toprule
% headers
\splitcell{Independent \\ variables} &
\splitcell{Target \\ variable} &
\splitcell{Data \\ records} &
Train/test &
Model &
Metrics &
Reference
\\
\midrule
% body
&  &  &  &  & 
RMSE = 0.005 &
Furtado et al. \cite{furtado2021methodology}
\\ \addlinespace
&  &  &  &  &
RMSE = 0.266 &
Reiner et al. \cite{reine}
\\ \addlinespace
&  &  &  &  &
  \splitcell{RMSE = 0.0307 \\ MAE = 0.0098 \\ $R^2$ = 0.0827} &
  Okafor et al. \cite{okafor2021evaluation}
\\ \addlinespace
&  &  &  &  &
  \splitcell{RMSE = 35.49 \\ MAE = 26.48 \\ EP = 7.45 \\ $R^2$ = 0.95} &
  Balcıoğlu et al. \cite{balciouglu2021comparison}
\\ \addlinespace
&  &  &  &  &
  RMSE = 3.03E$-06$ &
  Sun et al.\cite{prediction}
\\ \addlinespace
&  &  &  &  &
  RMSE = 0.03 &
  Breuer et al.\cite{bre21prediction}
\\ \addlinespace
&  &  &  &  &
  \splitcell{$R^2$ = 0.96 \\ RMSE = 0.4369 \\ MAE = 0.3265} &
  Zhang et al. \cite{zhang2021machine}
\\ \addlinespace
&  &  &  &  &
  \splitcell{$R^2$ = 0.99 \\ RMSE = 0.08 \\ MAE = 0.06} &
  Zhang et al. \cite{zhang2021machine}
\\ \addlinespace
&  &  &  &  &
  \splitcell{RMSE = 0.131 \\ $R^2$ = 0.735} &
  Yin et al. \cite{machine}
\\ \addlinespace
&  &  &  &  &
  $R^2$ = 0.97  &
  This study
\\
\bottomrule
\end{tabular}

\end{table}

\end{document}

在此处输入图片描述

我还修复了 = 周围空格的所有不一致问题。

相关内容