0

I have three tables in my document in Latex and unwanted a lot of spaces are created between them. I can't figure out how to reduce these spaces.

enter image description here

I have also tried different suggestions such as link1, link2. Unfortunately, None of them solved the problem completely.

Also, I found this problem is because of the first settings of the \documentclass[<options>]{cas-dc}, which I have put along with the following packages, which are used in my document in Latex, in the following code.

\documentclass[a4paper,fleqn]{cas-dc}
\usepackage{lipsum,capt-of,graphicx}
\usepackage{geometry}% Just for this example
\usepackage{natbib}
\usepackage{ragged2e}
\usepackage{setspace}
\usepackage[labelfont=bf,justification=raggedright,singlelinecheck=false, font={footnotesize}]{caption}
\captionsetup[figure]{name=Fig. ,labelsep=period, justification=justified, singlelinecheck=off}
\captionsetup[table]{labelsep=newline,font=footnotesize, justification=justified, singlelinecheck=off}
\usepackage{subcaption}


%%%Author definitions
\def\tsc#1{\csdef{#1}{\textsc{\lowercase{#1}}\xspace}}
\tsc{WGM}
\tsc{QE}
\tsc{EP}
\tsc{PMS}
\tsc{BEC}
\tsc{DE}
%%%


\usepackage{etoolbox}
\AtBeginEnvironment{table}{\sffamily}
\usepackage{booktabs,siunitx, multirow}
\sisetup{table-format=1.4, tight-spacing=true, separate-uncertainty}

\sisetup{
    output-exponent-marker = \text{e},
    exponent-product={},
    retain-explicit-plus,
    input-open-uncertainty  = ,
    input-close-uncertainty = ,
    table-align-text-pre    = false,
    table-align-text-post = false,
    round-mode=places,
    round-precision=2,
    table-space-text-pre    = (,
    table-space-text-post   = ),
}

\usepackage{amsmath}
\usepackage{adjustbox}
\usepackage{floatrow}
\floatsetup[table]{style=Plaintop, captionskip=0pt, capposition=top}

\let\sum\relax % To change the style of summation symbol
\DeclareSymbolFont{otherlargesymbols}{OMX}{cmex}{m}{n}
\DeclareMathSymbol{\sum}{\mathop}{otherlargesymbols}{"50}

\setlength{\mathindent}{0pt}
\setlength\parindent{0pt}

\begin{document}\sloppy
\justify

\title [mode = title]{This is a specimen $a_b$ title}
rtydf

\maketitle


%\vspace*{-\baselineskip}
\begin{table*}[hbt!]
\setlength{\tabcolsep}{1.95pt}
\begin{adjustbox}{width=.7\textwidth}
\captionsetup{width=.69\linewidth}
%\vspace*{-\baselineskip}
%\vspace*{2 mm}
%\renewcommand*\arraystretch{1.3}
\caption{bbbb}\label{tbl:2}
\begin{tabular}{@{} l c *{7}{S} @{}}  % 1 'c' column, 4 'S' columns
\bottomrule
\multirow{2.5}{*}{}
& \multicolumn{7}{c}{C1} \\
\cmidrule(lr){2-8} & {A} & {B} & {C} & {D} & {E} & {F} & {G}\\

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{90 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{90 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\end{tabular}
\end{adjustbox}
\end{table*}

\begin{table*}[hbt!]
\setlength{\tabcolsep}{1.95pt}
\begin{adjustbox}{width=.7\textwidth}
\captionsetup{width=.69\linewidth}
%\vspace*{-\baselineskip}
%\vspace*{2 mm}
%\renewcommand*\arraystretch{1.3}
\caption{ccc.}\label{tbl:2}
\begin{tabular}{@{} l c *{7}{S} @{}}  % 1 'c' column, 4 'S' columns
\bottomrule
\multirow{2.5}{*}{}
& \multicolumn{7}{c}{C1} \\
\cmidrule(lr){2-8} & {A} & {B} & {C} & {D} & {E} & {F} & {G}\\

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{90 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{90 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\end{tabular}
\end{adjustbox}
\end{table*}

\begin{table*}[hbt!]
\setlength{\tabcolsep}{1.95pt}
\begin{adjustbox}{width=.7\textwidth}
\captionsetup{width=.69\linewidth}
%\vspace*{-\baselineskip}
%\vspace*{2 mm}
%\renewcommand*\arraystretch{1.3}
\caption{ddd}\label{tbl:2}
\begin{tabular}{@{} l c *{7}{S} @{}}  % 1 'c' column, 4 'S' columns
\bottomrule
\multirow{2.5}{*}{}
& \multicolumn{7}{c}{C1} \\
\cmidrule(lr){2-8} & {A} & {B} & {C} & {D} & {E} & {F} & {G}\\

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{9 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\bottomrule
\multirow{1.3}{*}{TTT:}\\
\midrule
AA & \num{8.12 \pm 3.5} & \num{1} & \num{1 \pm 7.91} &
\num{9 \pm 4.24} & \num{9 \pm 3.21} & \num{2.50 \pm 7.91} &
\num{5 \pm 3.12}\\
BB & \num{2.1 \pm 4.52} & \num{7.69 \pm 10} & \num{21} &
\num{6 \pm 5.80} & \num{15 \pm 6.2} & \num{17} &
\num{10}\\
CC & \num{6.14 \pm 6.2} & \num{9.67 \pm 10.54} & \num{8.5 \pm 7.1} & \num{14.83 \pm 6.79} & \num{9.7 \pm 7.5} & \num{2.50 \pm 7.91} &
\num{13.75 \pm 3.95}\\
DD & \num{15.71 \pm 13.55} & \num{12 \pm 31.62} & \num{45} &
\num{12 \pm 1.62} & \num{90 \pm 31.62} & \num{0} &
\num{1.50 \pm 2.91}\\
%\bottomrule
\midrule

\end{tabular}
\end{adjustbox}
\end{table*}

\end{document}
2
  • 1
    I deleted the biblatex tag that you added but does not seem related. Dec 8, 2020 at 22:17
  • Why did the "keep them in a single float" option not work?
    – Werner
    Dec 8, 2020 at 23:26

1 Answer 1

2

Note that cas-dc is intended for journal submission. If you are using it to submit an article to a Jornal you should not change the layout parameters. The whole point of a publisher supplied class is to remove choice from the author and enforce a consistent style.

However to answer the question as asked:

These are double column floats on a float page so they are spaced \@dblfpsep apart.

Adding

\makeatletter
\@dblfpsep=0pt
\makeatother

to your preamble sets this to 0pt and the tables have no space at all, set to a length that you prefer.

7
  • The length of election must be probably the default. It is a Elsevier class ...
    – Fran
    Dec 8, 2020 at 22:32
  • @Fran well that's true: I hadn't noticed it was a journal class. I will add a big don't do this warning. Dec 8, 2020 at 22:36
  • @David Carlisle: Thanks. I have applied your suggestion, but it couldn't solve my problem completely. The distance between table 1 and table 2 is ok, but table 3 is still far from these two tables. Also, there is an unwanted space between table 1 and the top of the page.
    – Ellie
    Dec 8, 2020 at 22:38
  • @Ellie this changes the spaces between floats on a float page (a page with just floats and no text) perhaps you have tables appearing on text page which use different parameters. Impossible to guess, also note that "don't do this" warning I added. Dec 8, 2020 at 22:40
  • @Fran Yes, but these three tables don't have good position in my document.
    – Ellie
    Dec 8, 2020 at 22:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.