tags:

views:

178

answers:

5

Hi, I notice that there is some gap after my table. See the following snapshot:

http://i39.tinypic.com/x3e4vd.jpg

My Latex code is:

\begin{table}[htb]  
\caption{Error rates VS training size in AdaBoosted stump, SVM and kNN. \label{tab:examplecount8000errerrplot}}  
\begin{center}  
\begin{tabular}{c c}  
\includegraphics[scale=0.4]{../boost.eps}   
&  
\includegraphics[scale=0.4]{../svm.eps}   \\    
\includegraphics[scale=0.4]{../knn.eps}   
& \\    
\end{tabular}  
\end{center}  
\end{table}     
%  
\subsection{Feature Numbers}

Is the gap normal or How can I reduce the gap to be normal?

Thanks and regards!

+4  A: 

The gap is normal. Typical LaTeX use case means "let LaTeX worry about the layout."

If it's still a problem when you've coded up all your content, worry about it then. Otherwise LaTeX tends to be pretty good at choosing how to arrange things.

Matt Ball
+1  A: 

Undeleted answer, since this was referred to by dmckee. I'm generally against fiddling about with the way you express content: better live with the unwanted space, change things in the style files (per dmckee's suggestion), change what you want to express (like where captions are), or put in pure band-aid (like vspace). So I don't like this answer, since terminating every row of a tabular with a \\ makes them easier to maintain, like ending C blocks with a semicolon.

Delete the last \\ in the tabular environment.

Charles Stewart
+2  A: 

If Charles's and midtiby's answers don't fix it for you and you must adjust it (because, for instance the margin lady won't pass your dissertation until you do), you can diddle the lengths

  • \floatsep
  • \textfloatsep
  • \intextsep

(and their two column brethren) which adjust the spacing around and between floats. In this case I believe you want \textfloatsep.

But do what Charles and midtiby said first, and consider Bears' advice as well.

dmckee
I've restored my comment, with an explanation as to why I deleted it.
Charles Stewart
+4  A: 

Instead of centering the tables with the {center} environment, try to use the \centering macro. I should be something like

\begin{table}
\centering
...
\end{table}
midtiby
Mica
+1  A: 

You can always fix vertical spacing by emitting a vskip command, say \vskip{-1em}, in vertical mode, such as before the \section. Bears is right: delay worrying about layout as late as possible. There should be a saying about premature formatting...

The table would look more attractive to me if the caption was at the bottom. The matter of appearance would be as much what is the proportion of space above and below the caption as the total amount of space.

Charles Stewart