I've been using the tabularx package in hopes of representing a rather lengthy table as part of a LaTeX document. However, no matter what strategies I have tried, the table not only runs past the right side of the table, but isn't centered on the page as I would have hoped. This image demonstrates what the table looks like:
Demonstration of table running past the right side of the document
TableError.png (43.84 KiB) Viewed 18179 times
Currently, I've tried using tabularx and specifying every column as X, but all this has proven to do is squish the cells that the contents of the table are in, to the point where the table looks visually unappealing. I've tried setting the width of the table to \pagewidth instead of \textwidth, but this has not alleviated the issue. I believe the issue stems from the fact that the left limit of the text is too far for the entire table to be displayed, but I'm unsure on how to fix this issue without changing the text width entirely, which I don't want to do.
Any thoughts on this matter? For reference, here is the excerpt of code I have used thus far to produce this table:
First of all: You should never use center to center floats like table or figure, because center is a trivlist environment and so adds extra vertical space. Usually use \centering switch to center inside floats. However in this case this wouldn't be enough, because the tabularx would be still to wide and a centering will be done inside the text area. The only LaTeX centering command's, that allow to exceed the text area are \centerline or \makebox. However, also using \centerline the tabularx would be to wide, because the sum of the widths of all X[latex]-columns would be wider than [latex]\paperwidth. Here we have the case: You cannot take an elephant on the bus.
A suggestion would be to use the natural width of every column (here given by the colum heads). But I would not use l-, c-, or r-columns. For numbers the (configurable) S-columns of siunitx are recommended. See the manual for more information.