siunitx: literal period within a cell
Clash Royale CLAN TAG#URR8PPP
up vote
2
down vote
favorite
Today I started practicing with siunitx. It is a bit fun, but I arrive at some troubles.
I have a stats table where I want to have a literal period, meaning no estimate was obtained, in some cells. I also have some cells where the numbers might be wrapped in parentheses and a few where they have asterixes. I've solved those problems, so the mre below does not emphasize them.
It is not allowed to have a cell with "." by itself. I get the "invalid-value" error from siunitx.
One workaround is to wrap the period in a multicolumn, that does not give the error. But the output is not quite right either
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=1.3, table-align-text-post=false]
S[table-format=1.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1c. tabularnewline
hline
endtabular
enddocument
But, as you expect, the period is not aligned.
I don't have a strong reason to require them to be aligned, but it would be fun if I could do it :)
tables
add a comment |Â
up vote
2
down vote
favorite
Today I started practicing with siunitx. It is a bit fun, but I arrive at some troubles.
I have a stats table where I want to have a literal period, meaning no estimate was obtained, in some cells. I also have some cells where the numbers might be wrapped in parentheses and a few where they have asterixes. I've solved those problems, so the mre below does not emphasize them.
It is not allowed to have a cell with "." by itself. I get the "invalid-value" error from siunitx.
One workaround is to wrap the period in a multicolumn, that does not give the error. But the output is not quite right either
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=1.3, table-align-text-post=false]
S[table-format=1.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1c. tabularnewline
hline
endtabular
enddocument
But, as you expect, the period is not aligned.
I don't have a strong reason to require them to be aligned, but it would be fun if I could do it :)
tables
add a comment |Â
up vote
2
down vote
favorite
up vote
2
down vote
favorite
Today I started practicing with siunitx. It is a bit fun, but I arrive at some troubles.
I have a stats table where I want to have a literal period, meaning no estimate was obtained, in some cells. I also have some cells where the numbers might be wrapped in parentheses and a few where they have asterixes. I've solved those problems, so the mre below does not emphasize them.
It is not allowed to have a cell with "." by itself. I get the "invalid-value" error from siunitx.
One workaround is to wrap the period in a multicolumn, that does not give the error. But the output is not quite right either
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=1.3, table-align-text-post=false]
S[table-format=1.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1c. tabularnewline
hline
endtabular
enddocument
But, as you expect, the period is not aligned.
I don't have a strong reason to require them to be aligned, but it would be fun if I could do it :)
tables
Today I started practicing with siunitx. It is a bit fun, but I arrive at some troubles.
I have a stats table where I want to have a literal period, meaning no estimate was obtained, in some cells. I also have some cells where the numbers might be wrapped in parentheses and a few where they have asterixes. I've solved those problems, so the mre below does not emphasize them.
It is not allowed to have a cell with "." by itself. I get the "invalid-value" error from siunitx.
One workaround is to wrap the period in a multicolumn, that does not give the error. But the output is not quite right either
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=1.3, table-align-text-post=false]
S[table-format=1.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1c. tabularnewline
hline
endtabular
enddocument
But, as you expect, the period is not aligned.
I don't have a strong reason to require them to be aligned, but it would be fun if I could do it :)
tables
tables
asked 51 mins ago
pauljohn32
297110
297110
add a comment |Â
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
3
down vote
You could use a phantom
.
By the way, you declared table-format=1.3
but your numbers have 2 integer positions, I corrected in table-format=2.3
, otherwise you have an Overfull hbox
warning.
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1lphantom00. tabularnewline
hline
endtabular
enddocument
add a comment |Â
up vote
1
down vote
similarly to CarLaTeXanswer:
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello & 1.333 & 33.222 tabularnewline
goodbye & 44.1 & .hphantom2 tabularnewline
hline
endtabular
enddocument
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
You could use a phantom
.
By the way, you declared table-format=1.3
but your numbers have 2 integer positions, I corrected in table-format=2.3
, otherwise you have an Overfull hbox
warning.
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1lphantom00. tabularnewline
hline
endtabular
enddocument
add a comment |Â
up vote
3
down vote
You could use a phantom
.
By the way, you declared table-format=1.3
but your numbers have 2 integer positions, I corrected in table-format=2.3
, otherwise you have an Overfull hbox
warning.
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1lphantom00. tabularnewline
hline
endtabular
enddocument
add a comment |Â
up vote
3
down vote
up vote
3
down vote
You could use a phantom
.
By the way, you declared table-format=1.3
but your numbers have 2 integer positions, I corrected in table-format=2.3
, otherwise you have an Overfull hbox
warning.
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1lphantom00. tabularnewline
hline
endtabular
enddocument
You could use a phantom
.
By the way, you declared table-format=1.3
but your numbers have 2 integer positions, I corrected in table-format=2.3
, otherwise you have an Overfull hbox
warning.
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello &1.333 &33.222tabularnewline
goodbye &44.1 & multicolumn1lphantom00. tabularnewline
hline
endtabular
enddocument
answered 34 mins ago
CarLaTeX
25.8k443114
25.8k443114
add a comment |Â
add a comment |Â
up vote
1
down vote
similarly to CarLaTeXanswer:
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello & 1.333 & 33.222 tabularnewline
goodbye & 44.1 & .hphantom2 tabularnewline
hline
endtabular
enddocument
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
add a comment |Â
up vote
1
down vote
similarly to CarLaTeXanswer:
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello & 1.333 & 33.222 tabularnewline
goodbye & 44.1 & .hphantom2 tabularnewline
hline
endtabular
enddocument
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
add a comment |Â
up vote
1
down vote
up vote
1
down vote
similarly to CarLaTeXanswer:
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello & 1.333 & 33.222 tabularnewline
goodbye & 44.1 & .hphantom2 tabularnewline
hline
endtabular
enddocument
similarly to CarLaTeXanswer:
documentclass[11pt,letterpaper,english]extarticle
usepackagelmodern
renewcommandsfdefaultlmss
renewcommandttdefaultlmtt
usepackagesiunitx
sisetup
input-symbols = ()*,
group-minimum-digits = 9
begindocument
begintabular
l
S[table-format=2.3, table-align-text-post=false]
S[table-format=2.3, table-align-text-post=false]
hline
hello & 1.333 & 33.222 tabularnewline
goodbye & 44.1 & .hphantom2 tabularnewline
hline
endtabular
enddocument
edited 20 mins ago
answered 27 mins ago
Zarko
114k863152
114k863152
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
add a comment |Â
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
ups, you are right! this one i prepare for another question ... :-(, i will correct this asap
â Zarko
22 mins ago
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f454445%2fsiunitx-literal-period-within-a-cell%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password