LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-22-2010, 12:10 PM   #1
ynovh
LQ Newbie
 
Registered: Mar 2010
Posts: 1

Rep: Reputation: 0
Adjust table width so that it fits to page width


Hi all,

A couple of days I started using latex and have still one question about the table width. My table is too wide for a page. How can I adjust it so that it fits on the full width of a page? Can I use a command or do I have to specify each column widths by hand?

my table looks like this;

\begin{tabular}{l c c c c c c c c c c} \hline\hline
\textbf{Panel B: Book Leverage} & & & & & & & & & & \\[-2.5ex]
\textbf{\% Change in Response} &Full & & & & & & & & & \\[-2.5ex]
\textbf{to IQR Shock} &Sample & & \multicolumn{2}{c}{Size} & &\multicolumn{2}{c}{Ratings} & &\multicolumn{2}{c}{Div. Payout} \\[-1.0ex]
\cline{2-2}
\cline{4-5}
\cline{7-8}
\cline{10-11}


& & &Small &Large & &Unrated &Rated & &Low &High \\[-2ex]
& & &Firms &Firms & &Firms &Firms & &DivPayout &DivPayout \\[-2ex]
& & &(1) &(2)& &(3) &(4)& &(5) &(6) \\[-0.5ex]
\hline

$Land\&Building$ &20.12**& &28.94* &-18.66 & &26.12** &-14.66 & &28.56** &-17.80 \\[0ex]
$Machinery\&Equipment$ &0.61& &5.83 &-5.73 & &-0.77 &1.94 & &-0.87 &-12.01 \\[0ex]
$OtherTangibles$ &1.27& &0.98 &-1.89 & &0.69 &6.22 & &0.89 &-7.85 \\[0ex]
$Size$ &13.95& &-6.77 &1.29 & &5.83 &2.44 & &-3.65 &-12.38*** \\[0ex]
$Profiability$ &-5.54***& &-4.81 &7.62* & &-5.65*** &-6.89** & &-4.38 &76.76*** \\[0ex]
$Q$ &3.80*& &1.98 &-3.16 & &-2.04 &-2.07 & &-0.85 &-12.46*** \\[0ex]
$EarningsVolatility$ &-5.86& &-8.41 &0.36 & &-7.99 &-2.71 & &-11.39 &-1.02 \\[0ex]
$MarginalTaxRate$ &-4.51***& &-15.82*** &-1.31 & &-5.52*** &-1.03 & &-12.81*** &-2.32 \\[0ex]
$RatingDummy$ &0.07***& & &0.07*** & & & & &20.18 &14.50** \\[0ex]
\hline
$Obs.$ &8,645& &2,404 &2,549 & &6,463 &1,373 & &3,448 &2,476 \\[0ex]
$Adj.-R2$ &0.086& &0.110 &0.084 & &0.067 &0.035 & &0.057 &0.037 \\[0ex]
\hline\hline

\hline \end{tabular}

I did try several commands like \textwidth, \resizebox, \setlength but didn't found the solution yet. Can anybody help me?
Thanks in advance!
 
Old 03-22-2010, 02:02 PM   #2
devnull10
Member
 
Registered: Jan 2010
Location: Lancashire
Distribution: Slackware Stable
Posts: 572

Rep: Reputation: 120Reputation: 120
I think the only "clean" way is to adjust the font size you are using. Remember the whole point of LaTeX is that you shouldn't care about how the document formats - LaTeX does that for you. So, if it isn't doing it right then perhaps you need to re-think the data you are giving it!
 
Old 03-22-2010, 03:13 PM   #3
CoderMan
Member
 
Registered: Jan 2009
Location: Gemini Capsule 25164
Distribution: Gentoo
Posts: 375
Blog Entries: 24

Rep: Reputation: 43
Does this link help?

http://www.latex-community.org/forum...it=table+width

If not, I'd recommending making a post in the latex-community.org forums. I have found that they are both very helpful and very knowledgeable.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
sceen width avmurthy Linux - Laptop and Netbook 1 08-20-2008 08:50 AM
bash: how to resize and fix the width of a page.html ? frenchn00b Linux - General 1 03-10-2008 05:46 PM
ostringstream width gecoool Programming 3 12-09-2005 02:02 AM
Latex, width of a tabular table? fei Programming 5 05-23-2005 09:11 AM
Name Width in apache im1crazyassmofo Linux - Networking 1 07-28-2003 03:01 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 03:22 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration