Share your knowledge at the LQ Wiki.
 Home Forums HCL Reviews Tutorials Articles Register Search Today's Posts Mark Forums Read
 LinuxQuestions.org latex, floating tables side by side?
 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.

 10-29-2006, 09:54 AM #1 hedpe Member   Registered: Jan 2005 Location: Pittsburgh Distribution: Ubuntu Posts: 378 Rep: latex, floating tables side by side? Hey guys, I am trying to float two tables to the top of the page to span across both columns of an IEEE journal style paper, so I did doing this: Code: \begin{figure*} \centering \label{fig:sdevalarms} \begin{tabular}{|l|c|c|c|c|c|} \hline & D\_IN & D\_OUT & R\_ADDR & PORT & FSD \\ \hline D\_IN & - & 83.67\% & 73.47\% & 75.51\% & 18.37\% \\ \hline D\_OUT & 56.16\% & - & 67.12\% & 65.75\% & 17.80\% \\ \hline R\_ADDR & 52.17\% & 71.01\% & - & 91.30\% & 18.84\% \\ \hline PORT & 55.22\% & 71.64\% & 94.03\% & - & 16.42\% \\ \hline FSD & 20.00\% & 28.89\% & 28.89\% & 24.44\% & - \\ \hline \end{tabular} \begin{tabular}{|l|c|c|c|c|c|} \hline & D\_IN & D\_OUT & R\_ADDR & PORT & FSD \\ \hline D\_IN & - & 78.95\% & 62.11\% & 65.26\% & 29.47\% \\ \hline D\_OUT & 39.47\% & - & 37.89\% & 38.95\% & 17.89\% \\ \hline R\_ADDR & 52.68\% & 64.29\% & - & 86.61\% & 46.43\% \\ \hline PORT & 55.86\% & 66.67\% & 87.39\% & - & 40.54\% \\ \hline FSD & 33.73\% & 40.96\% & 62.65\% & 54.22\% & - \\ \hline \end{tabular} \caption{Wavelet based anomaly detection} \end{figure*} Except, doing that floats them, but they are directly on top of each other. I'd like them to be side by side with about an inches worth of space between them. Any ideas? Thanks! George
 10-29-2006, 10:14 AM #2 vharishankar Senior Member   Registered: Dec 2003 Posts: 3,161 Blog Entries: 4 Rep: You should probably use a longtable environment to achieve fancy effects with tables instead of using a floating environment. One idea is instead of having two separate tables, try and achieve the same visual effect by using a single table with columns to hold both the tables. Last edited by vharishankar; 10-29-2006 at 10:16 AM.
 10-29-2006, 10:27 AM #3 hedpe Member   Registered: Jan 2005 Location: Pittsburgh Distribution: Ubuntu Posts: 378 Original Poster Rep: got it, thanks for the suggestion: Code: \begin{table*}[htbp] \label{table:alarms} \centering \begin{minipage}{8.5cm} \begin{tabular}{|l|c|c|c|c|c|} \hline & D\_IN & D\_OUT & R\_ADDR & PORT & FSD \\ \hline D\_IN & - & 83.67\% & 73.47\% & 75.51\% & 18.37\% \\ \hline D\_OUT & 56.16\% & - & 67.12\% & 65.75\% & 17.80\% \\ \hline R\_ADDR & 52.17\% & 71.01\% & - & 91.30\% & 18.84\% \\ \hline PORT & 55.22\% & 71.64\% & 94.03\% & - & 16.42\% \\ \hline FSD & 20.00\% & 28.89\% & 28.89\% & 24.44\% & - \\ \hline \end{tabular} \caption{Standard deviation detection methods} \end{minipage} \begin{minipage}{8.5cm} \begin{tabular}{|l|c|c|c|c|c|} \hline & D\_IN & D\_OUT & R\_ADDR & PORT & FSD \\ \hline D\_IN & - & 78.95\% & 62.11\% & 65.26\% & 29.47\% \\ \hline D\_OUT & 39.47\% & - & 37.89\% & 38.95\% & 17.89\% \\ \hline R\_ADDR & 52.68\% & 64.29\% & - & 86.61\% & 46.43\% \\ \hline PORT & 55.86\% & 66.67\% & 87.39\% & - & 40.54\% \\ \hline FSD & 33.73\% & 40.96\% & 62.65\% & 54.22\% & - \\ \hline \end{tabular} \caption{Wavelet based anomaly detection} \end{minipage} \end{table*}
 10-29-2006, 10:39 AM #4 vharishankar Senior Member   Registered: Dec 2003 Posts: 3,161 Blog Entries: 4 Rep: Glad you got it. I would still prefer the longtable solution over using floats. To me using the longtable environment is cleaner for more complex tabular presentation. Here's a link if you wish: http://www.fi.infn.it/pub/tex/doc/orig/longtable.pdf Last edited by vharishankar; 10-29-2006 at 10:40 AM.

 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 Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post hustla Slackware 6 10-29-2006 03:11 PM dr_zayus69 Linux - Software 9 05-01-2006 02:53 AM hkl8324 Linux - Wireless Networking 1 06-08-2005 06:03 AM Burgin Programming 5 09-17-2004 01:42 PM niverson Linux - Networking 3 02-02-2004 08:52 AM

All times are GMT -5. The time now is 08:14 AM.

 Contact Us - Advertising Info - Rules - LQ Merchandise - Donations - Contributing Member - LQ Sitemap -