Can't align/center table

Clash Royale CLAN TAG#URR8PPP
up vote
4
down vote
favorite
The following LaTeX code generates a table, but it's not centralized with the paper:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
begincenter
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do\ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& 4e-10
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& 4e-36
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& 4e-143
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endcenter
endtable
enddocument
I've tried using begincenter and centering... but it doesn't work. How can I solve this problem?
tables
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
4
down vote
favorite
The following LaTeX code generates a table, but it's not centralized with the paper:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
begincenter
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do\ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& 4e-10
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& 4e-36
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& 4e-143
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endcenter
endtable
enddocument
I've tried using begincenter and centering... but it doesn't work. How can I solve this problem?
tables
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Your tabular is too wide. If you want it centered anyway, usemakebox[textwidth]...
â John Kormylo
Sep 30 at 15:35
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13
add a comment |Â
up vote
4
down vote
favorite
up vote
4
down vote
favorite
The following LaTeX code generates a table, but it's not centralized with the paper:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
begincenter
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do\ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& 4e-10
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& 4e-36
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& 4e-143
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endcenter
endtable
enddocument
I've tried using begincenter and centering... but it doesn't work. How can I solve this problem?
tables
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
The following LaTeX code generates a table, but it's not centralized with the paper:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
begincenter
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do\ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& 4e-10
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& 4e-36
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& 4e-143
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endcenter
endtable
enddocument
I've tried using begincenter and centering... but it doesn't work. How can I solve this problem?
tables
tables
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
edited Sep 30 at 20:13
Circumscribe
2,128322
2,128322
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked Sep 30 at 14:48
Nicholas Yamasaki
474
474
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Nicholas Yamasaki is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Your tabular is too wide. If you want it centered anyway, usemakebox[textwidth]...
â John Kormylo
Sep 30 at 15:35
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13
add a comment |Â
1
Your tabular is too wide. If you want it centered anyway, usemakebox[textwidth]...
â John Kormylo
Sep 30 at 15:35
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13
1
1
Your tabular is too wide. If you want it centered anyway, use
makebox[textwidth]...â John Kormylo
Sep 30 at 15:35
Your tabular is too wide. If you want it centered anyway, use
makebox[textwidth]...â John Kormylo
Sep 30 at 15:35
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
5
down vote
accepted
Here is a solution and some improvements, playing with the value of tabcolsep and adding lines in a column head:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[T1]fontenc
usepackage[portuguese]babel
usepackage[showframe]geometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
centeringsetlengthtabcolsep3pt
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do \ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho\ do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& $ 4,mathrme-10 $
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& $ 4,mathrme-36 $
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& $ 4,mathrme-143 $
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endtable
enddocument

Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
Here's a solution that (a) switches over to a tabularx environment and (b) uses centered versions of the p and X column types to allow for line breaks automatically. The solution also gets rid of all vertical lines and of most horizontal lines to give the table a more "open" look.

documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagetabularx,booktabs,ragged2e
newcolumntypeY%
>Centeringarraybackslashhspace0ptX
newcolumntypeC[1]%
>Centeringarraybackslashhspace0ptp#1
newcolumntypeL[1]%
>RaggedRightarraybackslashhspace0ptp#1
newlengthlena settowidthlenaIdentific
newlengthlenb settowidthlenbTamanho
newlengthlenc settowidthlencIdentid
newlengthlend settowidthlendTamanho do
newlengthlene settowidthleneAlgoritmo
hyphenationnano-pe-la-gi-cus
begindocument
sectionResults
begintable[h!]
setlengthtabcolsep4pt
begintabularxtextwidth@
Llena Clenb Y c Clenc Clend Clene @
toprule
Identificador de contig &
Tamanho do contig (bp) &
Melhor hit newline (organismo) &
e-value &
Identidade (%) &
Tamanho do alinhamento (bp) (% do tamanho do contig) &
Algoritmo usado\
midrule
ctg1 & 13425 & textitFriedmanniella textitsagamiharensis strain DSM 21743 & 4e-10 & 69 & 269 (2) & BLASTn \
addlinespace
ctg2 & 11567 & textitKineococcus radiotolerans SRS30216 & 0.0 & 71 & 3933 (34) & BLASTn \
addlinespace
ctg3 & 12900 & textitPseudomonas fluorescens strain NEP1 genome & 0.0 & 69 & 2193 (17) & BLASTn \
addlinespace
ctg4 & 17737 & textitHerminiimonas arsenicoxydans & 0.0 & 69 & 4257 (24) & BLASTn \
addlinespace
ctg5 & 13319 & textitNonomuraea sp. ATCC 55076 & 0.0 & 66 & 7192 (54) & BLASTn \
addlinespace
ctg6 & 10398 & textitMarichromatium purpuratum 984 & 0.0 & 72 & 5719 (55) & BLASTn \
addlinespace
ctg7 & 16623 & textitBacillus cereus AH820 & 4e-36 & 67 & 1330 (8) & BLASTn \
addlinespace
ctg8 & 20951 & textitLimnohabitans sp. 63ED37-2 & 0.0 & 80 & 15923 (76) & BLASTn \
addlinespace
ctg9 & 13925 & textitPontibacter actiniarum DSM 19842 & 4e-143 & 74 & 1114 (8) & BLASTn \
addlinespace
ctg10 & 10484 & textitCandidatus Nanopelagicus limnes & 0.0 & 80 & 9331 (89) & BLASTn \
bottomrule
endtabularx
endtable
enddocument
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
5
down vote
accepted
Here is a solution and some improvements, playing with the value of tabcolsep and adding lines in a column head:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[T1]fontenc
usepackage[portuguese]babel
usepackage[showframe]geometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
centeringsetlengthtabcolsep3pt
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do \ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho\ do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& $ 4,mathrme-10 $
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& $ 4,mathrme-36 $
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& $ 4,mathrme-143 $
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endtable
enddocument

Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
accepted
Here is a solution and some improvements, playing with the value of tabcolsep and adding lines in a column head:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[T1]fontenc
usepackage[portuguese]babel
usepackage[showframe]geometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
centeringsetlengthtabcolsep3pt
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do \ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho\ do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& $ 4,mathrme-10 $
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& $ 4,mathrme-36 $
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& $ 4,mathrme-143 $
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endtable
enddocument

Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
accepted
up vote
5
down vote
accepted
Here is a solution and some improvements, playing with the value of tabcolsep and adding lines in a column head:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[T1]fontenc
usepackage[portuguese]babel
usepackage[showframe]geometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
centeringsetlengthtabcolsep3pt
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do \ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho\ do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& $ 4,mathrme-10 $
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& $ 4,mathrme-36 $
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& $ 4,mathrme-143 $
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endtable
enddocument

Here is a solution and some improvements, playing with the value of tabcolsep and adding lines in a column head:
documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[T1]fontenc
usepackage[portuguese]babel
usepackage[showframe]geometry
usepackagemakecell
begindocument
sectionResults
begintable[h]
centeringsetlengthtabcolsep3pt
begintabularc
hline
theadIdentificador\ de contig
& theadTamanho do \ contig (bp)
& theadMelhor hit\ (organismo)
& theade-value
& theadIdentidade\ (%)
& theadTamanho do\ alinhamento (bp)\ (% do tamanho\ do contig)
& theadAlgoritmo\ usado\
hline
ctg1
& 13425
& theadtextitFriedmanniella\textitsagamiharensis \ strain DSM 21743
& $ 4,mathrme-10 $
& 69
& 269 (2)
& BLASTn \
hline
ctg2
& 11567
& theadtextitKineococcus \textitradiotolerans \ SRS30216
& 0.0
& 71
& 3933 (34)
& BLASTn \
hline
ctg3
& 12900
& theadtextitPseudomonas \ textitfluorescens \ strain NEP1 genome
& 0.0
& 69
& 2193 (17)
& BLASTn \
hline
ctg4
& 17737
& theadtextitHerminiimonas \ textitarsenicoxydans
& 0.0
& 69
& 4257 (24)
& BLASTn \
hline
ctg5
& 13319
& theadtextitNonomuraea sp. \ ATCC 55076\
& 0.0
& 66
& 7192 (54)
& BLASTn \
hline
ctg6
& 10398
& theadtextitMarichromatium \ textitpurpuratum \ 984
& 0.0
& 72
& 5719 (55)
& BLASTn \
hline
ctg7
& 16623
& theadtextitBacillus cereus \ AH820
& $ 4,mathrme-36 $
& 67
& 1330 (8)
& BLASTn \
hline
ctg8
& 20951
& theadtextitLimnohabitans sp. \ 63ED37-2
& 0.0
& 80
& 15923 (76)
& BLASTn \
hline
ctg9
& 13925
& theadtextitPontibacter \ textitactiniarum \ DSM 19842
& $ 4,mathrme-143 $
& 74
& 1114 (8)
& BLASTn \
hline
ctg10
& 10484
& theadtextitCandidatus \ textitNanopelagicus \ textitlimnes
& 0.0
& 80
& 9331 (89)
& BLASTn \
hline
endtabular
endtable
enddocument

answered Sep 30 at 16:12
Bernard
157k764190
157k764190
Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
Thank you! I really aprecciate it!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
Here's a solution that (a) switches over to a tabularx environment and (b) uses centered versions of the p and X column types to allow for line breaks automatically. The solution also gets rid of all vertical lines and of most horizontal lines to give the table a more "open" look.

documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagetabularx,booktabs,ragged2e
newcolumntypeY%
>Centeringarraybackslashhspace0ptX
newcolumntypeC[1]%
>Centeringarraybackslashhspace0ptp#1
newcolumntypeL[1]%
>RaggedRightarraybackslashhspace0ptp#1
newlengthlena settowidthlenaIdentific
newlengthlenb settowidthlenbTamanho
newlengthlenc settowidthlencIdentid
newlengthlend settowidthlendTamanho do
newlengthlene settowidthleneAlgoritmo
hyphenationnano-pe-la-gi-cus
begindocument
sectionResults
begintable[h!]
setlengthtabcolsep4pt
begintabularxtextwidth@
Llena Clenb Y c Clenc Clend Clene @
toprule
Identificador de contig &
Tamanho do contig (bp) &
Melhor hit newline (organismo) &
e-value &
Identidade (%) &
Tamanho do alinhamento (bp) (% do tamanho do contig) &
Algoritmo usado\
midrule
ctg1 & 13425 & textitFriedmanniella textitsagamiharensis strain DSM 21743 & 4e-10 & 69 & 269 (2) & BLASTn \
addlinespace
ctg2 & 11567 & textitKineococcus radiotolerans SRS30216 & 0.0 & 71 & 3933 (34) & BLASTn \
addlinespace
ctg3 & 12900 & textitPseudomonas fluorescens strain NEP1 genome & 0.0 & 69 & 2193 (17) & BLASTn \
addlinespace
ctg4 & 17737 & textitHerminiimonas arsenicoxydans & 0.0 & 69 & 4257 (24) & BLASTn \
addlinespace
ctg5 & 13319 & textitNonomuraea sp. ATCC 55076 & 0.0 & 66 & 7192 (54) & BLASTn \
addlinespace
ctg6 & 10398 & textitMarichromatium purpuratum 984 & 0.0 & 72 & 5719 (55) & BLASTn \
addlinespace
ctg7 & 16623 & textitBacillus cereus AH820 & 4e-36 & 67 & 1330 (8) & BLASTn \
addlinespace
ctg8 & 20951 & textitLimnohabitans sp. 63ED37-2 & 0.0 & 80 & 15923 (76) & BLASTn \
addlinespace
ctg9 & 13925 & textitPontibacter actiniarum DSM 19842 & 4e-143 & 74 & 1114 (8) & BLASTn \
addlinespace
ctg10 & 10484 & textitCandidatus Nanopelagicus limnes & 0.0 & 80 & 9331 (89) & BLASTn \
bottomrule
endtabularx
endtable
enddocument
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
Here's a solution that (a) switches over to a tabularx environment and (b) uses centered versions of the p and X column types to allow for line breaks automatically. The solution also gets rid of all vertical lines and of most horizontal lines to give the table a more "open" look.

documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagetabularx,booktabs,ragged2e
newcolumntypeY%
>Centeringarraybackslashhspace0ptX
newcolumntypeC[1]%
>Centeringarraybackslashhspace0ptp#1
newcolumntypeL[1]%
>RaggedRightarraybackslashhspace0ptp#1
newlengthlena settowidthlenaIdentific
newlengthlenb settowidthlenbTamanho
newlengthlenc settowidthlencIdentid
newlengthlend settowidthlendTamanho do
newlengthlene settowidthleneAlgoritmo
hyphenationnano-pe-la-gi-cus
begindocument
sectionResults
begintable[h!]
setlengthtabcolsep4pt
begintabularxtextwidth@
Llena Clenb Y c Clenc Clend Clene @
toprule
Identificador de contig &
Tamanho do contig (bp) &
Melhor hit newline (organismo) &
e-value &
Identidade (%) &
Tamanho do alinhamento (bp) (% do tamanho do contig) &
Algoritmo usado\
midrule
ctg1 & 13425 & textitFriedmanniella textitsagamiharensis strain DSM 21743 & 4e-10 & 69 & 269 (2) & BLASTn \
addlinespace
ctg2 & 11567 & textitKineococcus radiotolerans SRS30216 & 0.0 & 71 & 3933 (34) & BLASTn \
addlinespace
ctg3 & 12900 & textitPseudomonas fluorescens strain NEP1 genome & 0.0 & 69 & 2193 (17) & BLASTn \
addlinespace
ctg4 & 17737 & textitHerminiimonas arsenicoxydans & 0.0 & 69 & 4257 (24) & BLASTn \
addlinespace
ctg5 & 13319 & textitNonomuraea sp. ATCC 55076 & 0.0 & 66 & 7192 (54) & BLASTn \
addlinespace
ctg6 & 10398 & textitMarichromatium purpuratum 984 & 0.0 & 72 & 5719 (55) & BLASTn \
addlinespace
ctg7 & 16623 & textitBacillus cereus AH820 & 4e-36 & 67 & 1330 (8) & BLASTn \
addlinespace
ctg8 & 20951 & textitLimnohabitans sp. 63ED37-2 & 0.0 & 80 & 15923 (76) & BLASTn \
addlinespace
ctg9 & 13925 & textitPontibacter actiniarum DSM 19842 & 4e-143 & 74 & 1114 (8) & BLASTn \
addlinespace
ctg10 & 10484 & textitCandidatus Nanopelagicus limnes & 0.0 & 80 & 9331 (89) & BLASTn \
bottomrule
endtabularx
endtable
enddocument
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
up vote
5
down vote
up vote
5
down vote
Here's a solution that (a) switches over to a tabularx environment and (b) uses centered versions of the p and X column types to allow for line breaks automatically. The solution also gets rid of all vertical lines and of most horizontal lines to give the table a more "open" look.

documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagetabularx,booktabs,ragged2e
newcolumntypeY%
>Centeringarraybackslashhspace0ptX
newcolumntypeC[1]%
>Centeringarraybackslashhspace0ptp#1
newcolumntypeL[1]%
>RaggedRightarraybackslashhspace0ptp#1
newlengthlena settowidthlenaIdentific
newlengthlenb settowidthlenbTamanho
newlengthlenc settowidthlencIdentid
newlengthlend settowidthlendTamanho do
newlengthlene settowidthleneAlgoritmo
hyphenationnano-pe-la-gi-cus
begindocument
sectionResults
begintable[h!]
setlengthtabcolsep4pt
begintabularxtextwidth@
Llena Clenb Y c Clenc Clend Clene @
toprule
Identificador de contig &
Tamanho do contig (bp) &
Melhor hit newline (organismo) &
e-value &
Identidade (%) &
Tamanho do alinhamento (bp) (% do tamanho do contig) &
Algoritmo usado\
midrule
ctg1 & 13425 & textitFriedmanniella textitsagamiharensis strain DSM 21743 & 4e-10 & 69 & 269 (2) & BLASTn \
addlinespace
ctg2 & 11567 & textitKineococcus radiotolerans SRS30216 & 0.0 & 71 & 3933 (34) & BLASTn \
addlinespace
ctg3 & 12900 & textitPseudomonas fluorescens strain NEP1 genome & 0.0 & 69 & 2193 (17) & BLASTn \
addlinespace
ctg4 & 17737 & textitHerminiimonas arsenicoxydans & 0.0 & 69 & 4257 (24) & BLASTn \
addlinespace
ctg5 & 13319 & textitNonomuraea sp. ATCC 55076 & 0.0 & 66 & 7192 (54) & BLASTn \
addlinespace
ctg6 & 10398 & textitMarichromatium purpuratum 984 & 0.0 & 72 & 5719 (55) & BLASTn \
addlinespace
ctg7 & 16623 & textitBacillus cereus AH820 & 4e-36 & 67 & 1330 (8) & BLASTn \
addlinespace
ctg8 & 20951 & textitLimnohabitans sp. 63ED37-2 & 0.0 & 80 & 15923 (76) & BLASTn \
addlinespace
ctg9 & 13925 & textitPontibacter actiniarum DSM 19842 & 4e-143 & 74 & 1114 (8) & BLASTn \
addlinespace
ctg10 & 10484 & textitCandidatus Nanopelagicus limnes & 0.0 & 80 & 9331 (89) & BLASTn \
bottomrule
endtabularx
endtable
enddocument
Here's a solution that (a) switches over to a tabularx environment and (b) uses centered versions of the p and X column types to allow for line breaks automatically. The solution also gets rid of all vertical lines and of most horizontal lines to give the table a more "open" look.

documentclass[11pt]article
usepackage[utf8]inputenc
usepackage[portuguese]babel
usepackagegeometry
usepackagetabularx,booktabs,ragged2e
newcolumntypeY%
>Centeringarraybackslashhspace0ptX
newcolumntypeC[1]%
>Centeringarraybackslashhspace0ptp#1
newcolumntypeL[1]%
>RaggedRightarraybackslashhspace0ptp#1
newlengthlena settowidthlenaIdentific
newlengthlenb settowidthlenbTamanho
newlengthlenc settowidthlencIdentid
newlengthlend settowidthlendTamanho do
newlengthlene settowidthleneAlgoritmo
hyphenationnano-pe-la-gi-cus
begindocument
sectionResults
begintable[h!]
setlengthtabcolsep4pt
begintabularxtextwidth@
Llena Clenb Y c Clenc Clend Clene @
toprule
Identificador de contig &
Tamanho do contig (bp) &
Melhor hit newline (organismo) &
e-value &
Identidade (%) &
Tamanho do alinhamento (bp) (% do tamanho do contig) &
Algoritmo usado\
midrule
ctg1 & 13425 & textitFriedmanniella textitsagamiharensis strain DSM 21743 & 4e-10 & 69 & 269 (2) & BLASTn \
addlinespace
ctg2 & 11567 & textitKineococcus radiotolerans SRS30216 & 0.0 & 71 & 3933 (34) & BLASTn \
addlinespace
ctg3 & 12900 & textitPseudomonas fluorescens strain NEP1 genome & 0.0 & 69 & 2193 (17) & BLASTn \
addlinespace
ctg4 & 17737 & textitHerminiimonas arsenicoxydans & 0.0 & 69 & 4257 (24) & BLASTn \
addlinespace
ctg5 & 13319 & textitNonomuraea sp. ATCC 55076 & 0.0 & 66 & 7192 (54) & BLASTn \
addlinespace
ctg6 & 10398 & textitMarichromatium purpuratum 984 & 0.0 & 72 & 5719 (55) & BLASTn \
addlinespace
ctg7 & 16623 & textitBacillus cereus AH820 & 4e-36 & 67 & 1330 (8) & BLASTn \
addlinespace
ctg8 & 20951 & textitLimnohabitans sp. 63ED37-2 & 0.0 & 80 & 15923 (76) & BLASTn \
addlinespace
ctg9 & 13925 & textitPontibacter actiniarum DSM 19842 & 4e-143 & 74 & 1114 (8) & BLASTn \
addlinespace
ctg10 & 10484 & textitCandidatus Nanopelagicus limnes & 0.0 & 80 & 9331 (89) & BLASTn \
bottomrule
endtabularx
endtable
enddocument
answered Sep 30 at 16:28
Mico
265k30358738
265k30358738
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
I really liked the new design! Thanks!
â Nicholas Yamasaki
Sep 30 at 21:02
add a comment |Â
Nicholas Yamasaki is a new contributor. Be nice, and check out our Code of Conduct.
Nicholas Yamasaki is a new contributor. Be nice, and check out our Code of Conduct.
Nicholas Yamasaki is a new contributor. Be nice, and check out our Code of Conduct.
Nicholas Yamasaki is a new contributor. Be nice, and check out our Code of Conduct.
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%2f453199%2fcant-align-center-table%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
1
Your tabular is too wide. If you want it centered anyway, use
makebox[textwidth]...â John Kormylo
Sep 30 at 15:35
Note that you can format non-inline code by clicking the "" button or pressing ctrl-K (while the code is selected). More information on formatting can be found here here.
â Circumscribe
Sep 30 at 20:13