14

I would like to format the space reserved for a number shown in a table with separated uncertainty. It seems that when I use the table-format option the brackets around the mantissa disappear. This is illustrated in the example below:

\documentclass{article}    
\usepackage{siunitx}

\begin{document}    
\begin{table}
  \begin{tabular}{
                  S[separate-uncertainty = true]
                  S[table-format=1.1(1)e1,
                  separate-uncertainty = true]
                  }
    {Header} & {Header}\\
    1.0(2)e2 & 1.0(2)e2\\
  \end{tabular}
\end{table}    
\end{document}

enter image description here

I have also tried to use the bracket-numbers and multi-part-units = brackets without solving this issue. Is there any workaround to center the number and keep the brackets like in the first column of the example?

1 Answer 1

6
+300

Using your example: By using the table-figures-XXX assignments independently, rather than using the table-format shortcut, I was able to make Header 1 and 2 appear identical.

\documentclass{article}

\usepackage{siunitx}

\begin{document}

    \begin{table}
        \begin{tabular}{
                S[separate-uncertainty = true]
                S[%table-format=1.1(1)e1,
                table-figures-integer=1,
                table-figures-decimal=1,
                table-figures-exponent=1,
                table-figures-uncertainty=1,
                separate-uncertainty = true]
            }
            {Header} & {Header}\\
            1.0(2)e2 & 1.0(2)e2\\
        \end{tabular}
    \end{table}

\end{document}

%retain-unity-mantissa=true,    % probably unnecessary
%table-sign-mantissa=true,      % probably unnecessary

screenshot

4
  • Why the second number in the last example does not have brackets?
    – gypaetus
    Commented Jan 4, 2015 at 23:36
  • @MigueldeVal-Borro Apologies, I completely missed it. I believe it's expected that the boolean switches for the table-align-exponent, table-align-uncertainty, table-align-comparator etc options are expected to control a formatted table alignment when more complex aspects of the number are used. Let me know if this doesn't help, I will remove my answer as my answer doesn't solve the centering part of the question. I am not aware of a command that will take precedence over mantissa and center environment.
    – EngBIRD
    Commented Jan 5, 2015 at 2:41
  • 1
    Thanks @EngBIRD. There is a bug report about this issue that the author of the package will consider github.com/josephwright/siunitx/issues/244
    – gypaetus
    Commented Jan 6, 2015 at 14:47
  • 1
    Thank you for your answer! Even if it does not solve the problem completely (at least not with this version of siunitx, wink wink 😊), it is illuminating and hopefully brings some attention to this bug. Bounty for you 😊 Commented Jan 10, 2015 at 22:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .