# Tag Info

2

You need to make TeX think it is starting a new word after these breaks so that allows hyphenation of the following part. \hspace{0pt} will accomplish such a break. It is best to collect your code for this in to custom commands for the behaviour you wish to allow at the given punctuation mark: \documentclass[a4paper,leqno,twoside]{article} ...

2


1

Add a pair of \vfill inside the landscape environment. I added threeparttable, in order not to have the table caption much wider than the table, and gave some more spacing between table and caption: \documentclass{amsart} \usepackage{relsize, fullpage, url, amsmath, amssymb, graphicx, array} \usepackage{lscape, afterpage} \setlength{\parindent}{0cm} ...

0

Try http://texpoint.necula.org/manual.html. It processes Tex code within Word and Powerpoint. Using /input{Your File Here} and then ReTex Displays, it will also update as your tables change.

0

If you wish to mix-and-match the use of a floating and non-floating figure or table, then you should use the float package's [H] float specifier. Here's a small example: \documentclass{article} \usepackage[margin=1in]{geometry}% Just for this example \usepackage{float,lipsum,graphicx} \begin{document} \lipsum[1] \begin{figure}[H]% Non-floating figure ...

2

Only with tikz and the fit and matrix libraries. I also used backgrounds library for highlighting in the background (and does not cover the numbers). \documentclass[border=1mm,tikz]{standalone} \usetikzlibrary{fit,matrix,backgrounds} \begin{document} \begin{tikzpicture} \matrix[matrix of math nodes,% Not strictly necessary but useful to put math symbols ...

2

I agree with Mico that you may need a fourth column, but I have another suggestion for the alignment of the 3rd and 4th columns. Since the 3rd column contains numbers, it is better justified right and the numbers between the parentheses in the 4th column should be left justified with a single space { } after the 3rd column to make the two columns appear as ...

1

I suggest you use four columns for your table and let the header "Umsatz mit Ikea" span columns 3 and 4. By using the column type r for columns 3 and 4 you'll get the natural alignement for the turnover numbers. \documentclass[titlepage,a4paper,12pt]{article} \usepackage[ngerman]{babel} \usepackage[T1]{fontenc} ...

1

I would suggest using the 'siunitx' package and the I included feature of having automated number alignments by means of the table column type S. \documentclass[titlepage,a4paper,12pt]{article} \usepackage[ngerman]{babel} \usepackage[T1]{fontenc} \usepackage[latin1]{inputenc} \usepackage{booktabs} ...

2

You can collect the cell entry using collcell and condition on it's value with a basic \ifnum TeX condition: \documentclass{article} \usepackage{collcell,array,xcolor} \newcommand{\formatcolentry}[1]{% \ifnum#1<10 \color{red}% \else\ifnum#1>30 \color{green}% \fi\fi#1} \begin{document} ...

0

This should do what you're asking for: \documentclass{scrartcl} \usepackage{tabularx} \setlength{\tabcolsep}{25pt} \renewcommand{\arraystretch}{2} \usepackage{booktabs} \begin{document} \section*{Conferences} \begin{itemize} \item Oral presentation \hspace{-\tabcolsep}\begin{tabularx}{\linewidth}{Xr} A conference title, New Orleans & ...

7

The mis-match comes beacuse of two lines in the middle. They add to the height. You can compensate to them in the second table using \extrarowheight from array package. \documentclass{article} \usepackage{array} \begin{document} \begin{tabular}{|c|} \hline \\ \hline \\ \hline \\ \hline \end{tabular} % \hspace{\tabcolsep}% ...

3

You can try tikz package and put your table (I use the simple tableau package here) inside a node to make drawing easier. Here is my code: \documentclass[border=2mm]{standalone} \usepackage{ytableau,tikz,varwidth} \usetikzlibrary{calc,shapes} \begin{document} \ytableausetup{boxsize=2em} \begin{tikzpicture}[b/.style={rounded ...

0

Thanks to Mico. Based on his suggestion the following wide table was constructed. However, I do not understand why \hline is not working except in the heading of the table. MyCode: \documentclass[table]{article} \usepackage[margin=0.5in]{geometry} \usepackage{booktabs} \usepackage{graphicx} \usepackage{siunitx} \begin{document} \begin{center} \textbf{Wide ...

0

To my utter surprise, I actually managed to patch the code for the ltabulary environment to add support for the \caption command. The patched code is taken from the ltxtable package with very minor changes and comprises a whooping 3 lines. The below code solves all problems in one go, as suggested in the first problem in the question. Replace the ...

0

One idea, provided that the table is currently only slightly too wide, is to locally change your page's geometry using the geometry package and the command \newgeometry. If for instance you have an a4paper set up using \usepackage[a4paper]{geometry} in your preamble you can locally make the page a bit wider(changing only the margins) using ...

5

If the table is currently only slightly too wide and you do not want to resort to using \resizebox -- say, because you don't want to incur an uncontrolled change in font size -- you could try the following measures. Reduce the value of the parameter \tabcolsep, which sets the amount of intercolumn whitespace. The default value of \tabcolsep is 6pt. Try if ...

0

It seems that you have discovered one of TeX and LaTeX ‘features’. See Frank Mittelbach’s answer to a similar question regarding the m-columns. I have found two additional ‘solutions’ so we end up with three: Use an empty line as you have done Use a \strut Use \leavevmode Your MWE with alternativs: \documentclass{article} \usepackage[a4paper]{geometry} ...

1

Table can also be created as shown below. \documentclass{article} \usepackage{booktabs,siunitx,caption} \begin{document} \begin{table}[ht] \caption{Information about countries} \label{table:countries} \centering \begin{tabular*}{1.2\textwidth}{r|r|r||r|r|r||r|r|r} \toprule \multicolumn{9}{c}{Country}\\ \midrule \multicolumn{3}{c}{France} ...

0

Your minor problems can be solved First Problem: use ~{} before and after ; Second Problem: use \begin{tabular*}{0.95\textwidth}{@{\extracolsep{\fill}}rrrrrcc} and adjust the numbers in brackets with ~{} as shown in the code Third problem: minus sign is accepted. no error message was thrown code \documentclass{article} \usepackage{booktabs} ...

5

Rather than try to improve the display of the information given in the top left-hand cell, it may be more fruitful to disentangle the information and create two groups of columns -- a "country" column and a "property" column, with the latter getting three sub-columns (population, area, and HDI). To enhance the readability of the table, it's probably also a ...

2

With package mathtools: \documentclass[11pt]{article} \usepackage{mathtools} \usepackage{array} \usepackage[math]{cellspace} \begin{document} \begin{table}[!htdp] \begin{center} \begin{tabular}{Sc @{\clap{0}} m{5cm} @{$\mathclap{c}$} m{5cm} @{$\mathclap{r}$}} \cline{2-3} \multicolumn{1}{c}{$\dfrac{1}{x}$} & \multicolumn{1}{|c}{F} & ...

1

With tabularx: \documentclass[11pt]{article} \usepackage{amsmath} %% showframe just for demo \usepackage{tabularx} \usepackage[table]{xcolor} \begin{document} \noindent\arrayrulewidth1pt \begin{tabularx}{\textwidth}{>{\hsize=0.05\hsize}XXX} \cline{2-3} \noalign{\vspace{\arrayrulewidth}} \raggedleft$\dfrac{1}{x}$ & ...

1

I figured out how to do it with a graphics package. Still interested if there's a way with tables. \documentclass[11pt]{article} \usepackage{array} \usepackage[math]{cellspace} \usepackage{tikz} \definecolor{fillcolour}{HTML}{eeeeee} \begin{document} \begin{tikzpicture} \draw (5,0) -- (5,1); \draw (0,0) rectangle (10,1); \draw [fill=fillcolour] (0,0) ...

2

For your first problem, it's because inside each cell we're in math mode. For the second problem, I think it would be better-looking to have the confidence intervals centred in the cell; to have the semi-colon centred between numbers, I replaced it with {\,;\,}. I do not meet the third problem with the code you give. I also propose to put the legend at ...

2

One way to solve issues #1 and #2 is to center-set the confidence intervals below the corresponding point estimates, by encasing the intervals in pairs of curly braces, {...}. You can probably solve issue #3 by removing - (the minus symbol) from the list of "input symbols" defined in \sisetup{...}. However, since there's not a single - symbol in the table ...

0

Well I read your MWE code and the first two lines repeated once, I erased from the MWE, later I copied the code and compile on my machine without errors. The first time only the second table gives an error showing the footnote in very narrow column. But the second time all look good. I fear the errors your reported come from those duplicated lines in your ...

2

Here is how I would typeset the table: \documentclass{article} \usepackage[ margin = 3cm % avoids overfull \hbox' warning ]{geometry} \usepackage[ tableposition = top, % correct spacing between table and caption width = 0.76\textwidth % relative width of the caption ]{caption} \usepackage{booktabs} % horizontal lines in table \usepackage{siunitx} % ...

3

A different alignment for the first rows, an automatic numbering of rows and a slight simplification of code with the makecell or stackengine packages (no multirows): \documentclass{book} \usepackage[utf8]{inputenc} \usepackage{booktabs, caption, siunitx} \usepackage{makecell} \renewcommand\theadalign{tc} \usepackage{tabstackengine} \setstackEOL{\\} ...

1

Can't run your code but from what I read in your post this should help: In R: w <- latex( sumstats, file = "sumstats.tex" ) and then in LaTeX: \input{sumstats} assuming that this all takes place in the same folder. [edited] As stated in the help file: To prevent the latex file from being displayed store the result of ‘latex’ in an object, e.g. ...

3

The simplest solution to getting rid of the unwanted pair of vertical bars is to remove the directive \\ that occurs immediately after \begin{tabular}{...}. A better -- certainly more elegant -- solution comes from recognizing that you currently don't seem to be using LaTeX's \caption command to generate captions. Instead of typing ...

8

I don't think that using \multirow improves the look of the header cells -- quite the opposite, actually. The big gap between the first and second group of three columns seems excessive; you may get a better overall effect by trimming the \cmidrules to leave a modest visual gap. Finally, since the data are numeric, you may want to consider using the S column ...

3

\documentclass[table]{book} \usepackage{booktabs} \usepackage{multirow} \usepackage{multicol} \usepackage{caption} \begin{document} \begin{table}[H] \centering \caption{Comparison of Group A and B}\label{AB} \begin{tabular}{ccccccccc} \toprule \multirow{3}[4]{*}{No.} & & \multicolumn{3}{c}{Group A} & &\multicolumn{3}{c}{Group B}\\ ...

2

You wrote in a comment: I managed to fix the width of my table using p{<width>} type. My problem now is that all my text is aligned to the left. I need most of my text to be center aligned. To define a column type that center-sets its contents and takes a width specifier, you could add the following code to your preamble \usepackage{array} ...

3

Table Construction: Code: \documentclass[table]{book} \usepackage{multirow} \usepackage{multicol} \usepackage{caption} \usepackage{listings} \begin{document} \begin{table}[h] \centering \begin{tabular*}{0.90\textwidth}{@{\extracolsep{\fill}}rrrrrrrr} \hline \hline \multirow{4}{*}{No} & \multirow{4}{*}{A} & \multicolumn{3}{c}{Group A} & ...

0

You want to align two rows of first minipage with three rows of second minipage. The logic is correct. Since you have opted for bottom option the first minipage's two rows are aligned with the last two rows of second minipage. Since third row of second minipage contains another three rows it appears to be incorrect. So you have added ~&~ as the last row ...

2

Here are two ways of doing things, first defining a \mycases environment in the definition style of amsthm, and two ways of having your equations aligned on the left margin — one defining a tabenum counter that's increased each time a\tabitem command is called (and it can be cross-referenced); the other simply uses theflalign environment, and thus the ...

0

You could have broken the lines neare \lipsum[3] My Code: \documentclass{article} \usepackage[a4paper]{geometry} \usepackage{tabularx} \usepackage{lipsum} \usepackage{fix-cm} \begin{document} \begin{minipage}[b]{0.4\textwidth} \begin{flushleft} \begin{tabular}[t]{@{}ll@{}} A & B\\ A & ...

0

Now, from your code my first idea was that the error with your tables is that you was using the whole \textwidth in the cell, where you should use only an fraction, but later I see that is not true. I see if you don't adjust the width of your cells, the text inside will be displayed in a very long line as you can see. So, if you want to use minipages with ...

3

Your problems stem from the fact that your table, defined with 4 X columns really has none. It suffices to re-define X column type so as to ensure right alignment, and you'll have both a table that looks like what you want, and a simpler code. I also suppressed redundant vertical lines in \multicolumns: \documentclass[a4paper]{article} ...

7

Here is a try using \hsize \documentclass[]{article} \usepackage[a4paper, top=25mm, left=25mm, right=25mm, bottom=20mm, headsep=5mm, footskip=10mm, headheight=25mm]{geometry} \usepackage{tabularx} \begin{document} \noindent \begin{table}[h!] \begin{tabularx}{\textwidth}{|X|X|X|X|} \hline \multicolumn{3}{|>{\hsize=3\hsize}X|}{3 cells left} ...

5

As noted in the comments, you need an \hline instruction to tell LaTeX to draw a full-width horizontal line. Rather than create a table with lots and lots of vertical lines and quite a few horizontal lines, consider setting up a table with no vertical lines and just a few, but well-spaced horizontal lines. For that, use the macros \toprule, \midrule, and ...

0

\noindent command is the correct answer. Overfull \hbox (15.0pt too wide) is a warning only. After applying \noindent command before starting \begin{tabularx} command your code runs perfectly well. I got zero error, zero warnings and zero bad boxes. However, I am working with MikTex 2.9 in windows 8.

1

The little breaks in the left-hand vertical line disappears with a coorect use of \hhline. The missing vertical line problem is solved as said @Christian Hupfer. I also simplified a little your code: it's useless to load color if you load xcolor, and I don't see why you wrap your multirow in a \parbox. I added another way to improve your table: ...

2

You have omitted to give pipe symbol in line no. 31 where |c| must appear so as to remove the error of unlinked bottom right corner of the table. Line no.28,29,30 must contain \hhline{|~|-|-|-|-|-|} in the last Correct code \documentclass[12pt,letterpaper,twoside,openright]{book} \usepackage[margin=1.0in]{geometry} \usepackage{multirow} ...

6

Please upgrade your LaTeX installation. That is one horribly old LaTeX installation In my system (TeX Live 2014), then the only warning I get is a overfull \hbox (15.0pt too wide). 15pt is the standard size of the paragraph indentation. So you may want to use \noindent \begin{tabularx}... or \begin{center} \begin{tabularx}.... ... \end{tabularx} ...

4

In the comments the fancyhdr and scrlayer-scrpage packages have been recommended, but it's always fun to roll your own. What you need to do is to insert your table into \@oddfoot and \@even foot -- and in turn these should both be inside your own header style that you can pass to \pagestyle. Here's a fun example using the tcolorbox package to produce the ...

4

You need to make (at least) the following changes: If you want the minipages to be placed one below the other rather than side-by-side, remove the \hfill instruction and simply leave a blank line If you want the captions to occupy the full width of the textblock, don't restrict the minipage widths to 0.48\linewidth. Instead, set their widths to ...

0

rws <- c(0,3,5,6,7) should do it.

1

Could have also done \begin{landscape} \begin{sidewaystable} INSERT TABLE \end{sidewaystable} \end{landscape}

Top 50 recent answers are included