2

How I make this table more attractive for the reader? (because the The reader cannot read the numbers of the table and I wanna want the table fit in the sheet).

\documentclass{article}   
\usepackage{booktabs,array,tabularx,threeparttablex}
\usepackage{scalefnt}
\usepackage{mathtools,float}
\begin {document}
\subsubsection{Tabela que relaciona o per\'{i}odo com o comprimento do fio e 
que cont\'{e}m o resultado de todas as m\'{e}dias e desvios padr\~{a}o para os 
v\'{a}rios comprimentos do fio:}
\begin{table}[H]
\scriptsize
\centering
\scalefont{0.75}
\begin{tabular}{ccccccc}
\toprule
L - comprimento do fio (m) & M\'{e}dia do Per\'{i}odo (s) & Desvio Padr\~{a}o da 
m\'{e}dia & N$^{\circ}$ contagens & Per\'{i}odo ao quadrado ($s^2$) & 
$log\;L$ & $log\;T$\\
\midrule
0 & 0 & & & 0\\
\hline 0,4500 & 1,5278 & 1E-04 & 16 & 1,8616 & -0,7985 & 0,3107\\
\hline 0,5750 & 1,5280 & 1E-04 & 18 & 2,3345 & -0,5534 & 0,4239\\
\hline 0,6550 & 1,5278 & 1E-04 & 9 & 2,6576 & -0,4231 & 0,4887\\
\hline 0,7100 & 1,5281 & 5E-04 & 33 & 2,8917 & -0,3425 & 0,5309\\
\hline 0,7550 & 1,5276 & 1E-04 & 17 & 3,0804 & -0,2810 & 0,5625\\
\hline 0,8550 & 1,5282 & 4E-04 & 20 & 3,4767 & -0,1567 & 0,6230\\
\hline 0,9500 & 1,5294 & 1E-04 & 13 & 3,8310 & -0,0513 & 0,6716\\
\hline 1,0870 & 1,5273 & 2E-04 & 21 & 4,4019 & 0,0834 & 0,7409\\
\hline 1,1500 & 1,5278 & 1E-04 & 16 & 4,6393 & 0,1398 & 0,7673\\
\bottomrule
\end{tabular}
\begin{tablenotes}
\item[\textasteriskcentered] Nota: $log$ neste caso corresponde ao logaritmo neperiano
\end{tablenotes}
\caption{Representa\c{c}\~{a}o dos dados finais para todos os ensaios realizados do p\^{e}ndulo simples}
\end{table}
\end{document}
  • 2
    Good to see some code in this question, but this code will not compile. Please edit your question to make your code compilable. – cfr Apr 15 '16 at 1:24
  • @cfr Sorry for the errors on my code. I missing the packages. – Carmen González Apr 15 '16 at 1:27
  • 1
    To see if your code is compilable, try compiling it. If you get an error when you compile, chances are we will, too. – cfr Apr 15 '16 at 1:28
  • 1
    @cfr I change the code. Try now, please. – Carmen González Apr 15 '16 at 1:36
  • 2
    Thanks. Yes. That compiles now ;). So how do you want to change it? I would get rid of all the \hlines. But apart from that, what do you wish to do? You could rotate it. Or you could make the headers multi-line. – cfr Apr 15 '16 at 1:48
2

I would rotate the table. However, if you do not want to do that, I would do something like the following.

  • Do not scale fonts, especially those which come in multiple optical sizes. The shape of the letters at smaller sizes is not the same as the shape at larger sizes. 0.75 of 12pt is not equivalent to 8pt. Computer Modern and Latin Modern both feature multiple optical sizes, as do other high quality font families. especially don't scale a font to 0.75 when it is already \scriptsize.

  • Personally, I would not use the H specifier. If you don't want something to move, don't make it a float. You can use \captionof from caption or capt-of if you nonetheless need a caption. I let tables float, but \captionof is a perfectly reasonable alternative.

  • Don't use an excess of horizontal lines.

  • tabularx can be used with a custom X column specifier for the first 5 columns to get multiline headers, effectively.

  • Use geometry to get less excessive margins and a larger \textwidth.

This produces something like the following:

possibly improved table - different, anyway

I would also recommend aligning the columns according to the relevant number format. siunitx can help with this and with the correct typesetting of SI units and number formats generally.

\documentclass[letterpaper]{article}
\usepackage{geometry}
\usepackage{booktabs,array,tabularx,threeparttablex}
\usepackage{mathtools}
\newcolumntype{C}{>{\centering\arraybackslash}X}
\begin {document}
\subsubsection{Tabela que relaciona o per\'{i}odo com o comprimento do fio e que cont\'{e}m o resultado de todas as m\'{e}dias e desvios padr\~{a}o para os v\'{a}rios comprimentos do fio:}
\begin{table}
  \scriptsize
  \centering
  \begin{threeparttable}
  \begin{tabularx}{\textwidth}{*{5}{C}cc}
    \toprule
    L - comprimento do fio (m) & M\'{e}dia do Per\'{i}odo (s) & Desvio Padr\~{a}o da m\'{e}dia & N$^{\circ}$ contagens & Per\'{i}odo ao quadrado ($s^2$) & $log\;L$ & $log\;T$\\
    \midrule
    0 & 0 & & & 0\\
    0,4500 & 1,5278 & 1E-04 & 16 & 1,8616 & -0,7985 & 0,3107\\
    0,5750 & 1,5280 & 1E-04 & 18 & 2,3345 & -0,5534 & 0,4239\\
    0,6550 & 1,5278 & 1E-04 & 9 & 2,6576 & -0,4231 & 0,4887\\
    0,7100 & 1,5281 & 5E-04 & 33 & 2,8917 & -0,3425 & 0,5309\\
    0,7550 & 1,5276 & 1E-04 & 17 & 3,0804 & -0,2810 & 0,5625\\
    0,8550 & 1,5282 & 4E-04 & 20 & 3,4767 & -0,1567 & 0,6230\\
    0,9500 & 1,5294 & 1E-04 & 13 & 3,8310 & -0,0513 & 0,6716\\
    1,0870 & 1,5273 & 2E-04 & 21 & 4,4019 & 0,0834 & 0,7409\\
    1,1500 & 1,5278 & 1E-04 & 16 & 4,6393 & 0,1398 & 0,7673\\
    \bottomrule
  \end{tabularx}
  \begin{tablenotes}
    \item[\textasteriskcentered] Nota: $log$ neste caso corresponde ao logaritmo neperiano
  \end{tablenotes}
  \caption{Representa\c{c}\~{a}o dos dados finais para todos os ensaios realizados do p\^{e}ndulo simples}
  \end{threeparttable}
\end{table}
\end{document}
  • those should be minuses in the log L column, but they're hyphens. – barbara beeton Apr 15 '16 at 2:13
  • Yes, well if I knew how to format the numbers properly, I'd probably do it. However, the OP has already got examples of how to format numbers in tabulars using siunitx (e.g. tex.stackexchange.com/a/303462) and isn't using that approach, so I guess it is not wanted by the OP. – cfr Apr 15 '16 at 2:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.