# Tag Info

1

If only one column needs to break that can be on the main vertical list with the other columns treated as parboxes hung to the side: \documentclass {article} \usepackage [utf8] {inputenc} \usepackage [latin] {babel} \usepackage{lipsum} \newenvironment{foo}[3] {\list{}{\leftmargin6cm\rightmargin3cm \itemindent0cm \labelsep0pt \labelwidth0cm}% ...

4

As clarified in comments the problem is unrelated to floating environments. \documentclass{article} \usepackage{longtable} \begin{document} \paragraph{zz} \begin{longtable}{| c | c | c | c |} \hline 1 & 5 & 6 & 7 \\ \hline 1 & 5 & 6 & 7 \\ \hline 1 & 5 & 6 & 7 \\ \hline % and so on, many rows ...

1

Maybe this is not very nice and most certainly not the perfect way to handle that, but I never used \multirowcell before: It seems like you have to give the number of text-lines as argument to this cell and not (like in \multirow) only the number of vertical cells. Here is my approach which draws right for your case. If you need to modify and want to use ...

2

A slight improvement to David Carlisle's version, with threeparttable and makecell: table now fits ‘naturally’ into the margins: \documentclass{article} \usepackage{hyperref} \usepackage{graphicx,array} \usepackage[showframe, no marginpar]{geometry} \usepackage{threeparttable, caption} \captionsetup{font = footnotesize} \usepackage{makecell} ...

1

The case of mixed floats can be managed by the floatrow package, see §2.3.1 of the documentation. I mixed one of my favourite images with your tables (slightly improved as to vertical spacing with the setcellgapes command, from mmakecell. \documentclass[12pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} ...

1

There are many ways to do this. You will note the minipages are currently set to align bottoms. The \rasieboxes are included in case you want to align tops. Also, you might want to make the second minipage wider to handle the caption in one line. \documentclass{article} \usepackage{caption} \usepackage{graphicx} \usepackage{tabularx} \usepackage{mwe} ...

0

Thanks everyone! Here is my final code and the output: \documentclass[12pt]{article} \usepackage{hyperref} \usepackage{graphicx} \usepackage[table]{xcolor} \definecolor{lightgray}{gray}{0.9} \begin{document} \rowcolors{1}{}{lightgray} \begin{table}[ht] \centering % used for centering table \caption{Parameter Estimates} % title of Table ...

2

Scaling the table gives you little control over the font size. Here I've used \footnotesize which is really as small as you want to go. This bleeds into the margins but using subject knowledge you can probably abbreviate the first column headings and make it fit. Alternatively wrapping the existing headings to a narrower column but letting the table go to ...

4

Replication of column specifications is done using a *{<num>}{<col spec>} interface, which should repeat <col spec> a total of <num> times: \begin{tabular}{*{20}{c}} % tabular content \end{tabular} will produce a table of 20 columns, each one centred. To add vertical column rules (which you should never do), you can use ...

1

Here is a way to go, with array and its modifier >{…} that allows to insert commands at the beginning of each cell of a column. It allows here to insert the sign in each cell of the second column, and the number of the rows in the first column. I also use makecell to have easy common formatting of column heads, and variable width horizontal rules: ... 3 My first thought was to use pgfplotstable. You can choose which columns (of the original table) to plot by the columns key in the \pgfplotstabletranspose macro. The colnames from key says that I want the columns of the transposed table to be named based on the values in the course column of the original table. The postproc cell content line adds Subj before ... 2 Another alternative is use of package adjustbox and add valign=t (vertically align top) into the \includegraphic option. Remove [demo] from the graphicx package for true image Code \documentclass[12pt,twoside,openright,a4paper,oldfontcommands]{memoir} \usepackage{tabularx} \usepackage[pdftex,demo]{graphicx} % remove demo for true image ... 3 My idea is to build up the transposed rows step by step with every data line. Afterwards, the table is generated: \begin{filecontents*}{transpose.csv} course,J,Js,F,Fs,G,Gs,T,Ts 1,4,4,4,4,3,3,5,5 2,3,7,2,6,2,5,4,9 3,4,11,3,9,5,10,2,11 4,2,13,7,16,3,13,7,18 5,7,20,3,19,7,20,7,25 6,5,25,3,23,7,27,2,27 7,3,28,5,28,2,29,3,30 8,6,34,4,32,7,36,3,33 ... 3 use \raisebox{\dimexpr-\height+2ex}{% \includegraphics[width=\marginparwidth]% {structureIconArtifactsProxyWorkload.pdf}} 2 I have another solution to wrap a figure or table in a list environment. It relies on the insbox.tex generic macros file. Upon this file, I build two commands, \InsertListL and \ InsertListR that take two mandatory and one optional argument and insert any (well, most of them) box in a list environment. The arguments are: the number of lines that remain ... 2 Maybe you are looking for something like that: Then you can name the parent node of the tree and position a matrix beside the tree using the matrix and the fit library. Code: \documentclass[margin=10pt]{standalone} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} %%%%Tikz%%%%%% \usepackage{tikz} \usetikzlibrary{ trees, matrix, fit } ... 2 Assuming you want to stay with the tabularx table type that was used in my answer to the posting Table rowspan and colspan, you may achieve your objective using the methods set forth in section 4.3 of the user guide of the tabularx package. The method described there works by adjusting the relative widths of the columns of type X. (Naturally, if your ... 4 One option will be to use tabulary. It provides LCRJ column types and you can control the minimum and maximum column widths be setting \tymin and \tymax like \tymin=20pt \tymax=\maxdimen These can be set using \setlength also. Code (using the linked answer): \documentclass{article} \usepackage[margin=1in]{geometry} \usepackage{multirow,tabulary} ... 1 tabu seems very powerful but I guess you would only need something fairly simple in this case: \documentclass{article} \usepackage{hhline,tabu} \begin{document} \newtabulinestyle { mystyle=.5pt on 1.5pt off 1.5pt } \begin{tabu}{| r || *{3}{c|} c |[mystyle] c |}\hhline{|-||*{5}{-|}} a & b & e & f & i & j\\\hhline{:=::*{5}{=:}} ... 2 tabularx adjusts the table width by adjusting the column width for line breaking paragraphs it rarely makes sense to use it on tabular data as here. I made your "minimal" example more minimal by removing unused packages, used tabular instead of tabularx and truncated the last entry in column 1 which was making it too wide. \documentclass{article} ... 2 Using a default tabularx with package ltablex \documentclass[a4paper]{article} \usepackage{geometry} \usepackage[tablename=TABLE,labelsep=newline,aboveskip=0pt,bf]{caption} \usepackage{booktabs} \usepackage[svgnames]{xcolor} \usepackage{ltablex} \usepackage{amsmath} \protected\def\stars#1{^{#1}\$} \newcolumntype{k}{>{\hsize=.1\hsize}S} ...

2

I would compile the long table as in independent file in landscape format, then include it in the main file, using the pdfpages package. Here is a code for landscape form \documentclass[a4paper]{article}% \usepackage{geometry}%,showframe, nomarginpar [textwidth = 15.75cm, textheight = 25cm, marginratio={4:6,5:7}] ...

0

The easy answer would be "use a (even) smaller font size", or wider margins (see the geometry package) but I assume you don't want to do that. By best effort: \documentclass{article} \usepackage{booktabs} \usepackage{rotating} \usepackage{multirow} \begin{document} \begin{table}[htbp] \centering \footnotesize \caption{Add caption} ...

7

You've told us the size of the sheet of paper (A4), but we lack information regarding the width of the text block or, equivalently, the widths of the margins. In the example below, I assume 1" margins. Some suggestions: Use \multicolumn{5}{c}{...} to typeset the material that spans five columns. Split the headers of the final two columns to make them ...

0

Use p type colums to limit column width: p{2.5cm} limits the columns width to 2.5 cm (contrary to c/l/r type colums which grow with the content) Replace the table head with Bank & Country & \multicolumn{5}{|c|}{Conditional joint probability of default} & Total assets & Total liabilities \\ . The \multicolumncommand joins the number of cells ...

14

Example, which uses the following tricks: Smaller font size as in the question: \footnotesize. (Should not be smaller than that.) Long column headers put in two lines (via macro \tabstack). Also the dates are written in two lines to save space. \cmidrule adds a visual separator between the year and the following numbers in the column. Space between columns ...

2

I would use booktabs too, avoiding rules as much as possible; but also siunitx for the second column, in order to fully align the numbers. Also the data are easier to input. \documentclass[12pt]{article} % load the golden pair for numeric tables \usepackage{siunitx,booktabs} \usepackage{caption} \captionsetup[table]{position=bottom} \begin{document} ...

3

Package array provides \extrarowheight, which adds extra space to the height of the rows: \documentclass[12pt]{article} \usepackage{caption} \captionsetup[table]{position=bottom} \usepackage{amstext} \usepackage{array} \setlength{\extrarowheight}{2pt} \begin{document} \begin{table} \centering \begin{tabular}{|r|l|} \hline \textbf{Paramagnetic ...

3

Just adjust the loading order so that eqparbox comes before arydshln: \documentclass[12pt]{report} \usepackage{algorithm} \usepackage{algpseudocode} \usepackage{trimspaces} \usepackage{eqparbox} \usepackage{arydshln} \renewcommand{\algorithmiccomment}[1]{\hfill\eqparbox{COMMENT}{\% #1}} \begin{document} \begin{table}[htbp] \caption{A simple table with ...

2

The table is not fitting on to a page, but you may play around with this. Your first question is answered by \sisetup{add-integer-zero=false} and the second by posts like here or here or here. % arara: pdflatex \documentclass{article} \usepackage{caption} \usepackage{siunitx} \usepackage{booktabs} \usepackage{threeparttable} \usepackage{multirow} ...

0

My own solution is very similar to Gjallar's, but adds outside borders to the table, similar to Microsoft Word tables. \documentclass{report} \usepackage{parcolumns} \usepackage{mdframed} \newenvironment{mytable}[1] ...

0

The threeparttable environment, provided by the threeparttable package, is designed to handle just this task. The three parts of the threeparttable environment are (a) the caption, (b) the tabular (or tabular*, tabularx, or whatever) sub-environment, and (c) the tablenotes sub-environment. As the package's user guide says, there's nothing automatic about ...

0

I recommend to use the package scrextend and its command \footref{<key>} where <key> is defined in a \label{<key>} into the footnote that you wish to repeat. Here my code \documentclass{article} \usepackage{scrextend} \begin{document} \begin{minipage}[b]{0.9\linewidth} \begin{tabular}{lll} \hline a\footnote{This is other note.} & b ...

3

I believe that the text should be in a supplementary row below the rule: just remove the vertical rule, which serves no purpose. I added also the analog for the first table chunk. \documentclass{article} \usepackage{siunitx,booktabs} \sisetup{range-phrase=--} \begin{document} \begin{tabular}{l r} \toprule \multicolumn{1}{c}{\textbf{PARAMETER}} & ...

6

Please always post complete documnents showing all packages used (your example required siunitx) \documentclass{article} \usepackage{siunitx} \begin{document} \begin{table}[htbp]\centering \renewcommand{\arraystretch}{1.3} \caption[..]{..} \label{tab:trigger} \begin{tabular}{l | r} \multicolumn{1}{c|}{\textbf{PARAMETER}} & ...

4

\cmidrule needs a start and an end column number even if they are the same. That's why you have to use \cmidrule(lr){1-1} if only the first column should be underlined. Code: \documentclass{article} \usepackage{booktabs} \begin{document} \begin{table} \centering \footnotesize \begin{tabular}{rcccccc} \hline & \multicolumn{3}{c}{Something} & ...

3

This space is controlled by arraystretch (not a length, but a multiplier which defaults to 1) times the depth of \strutbox. Observe that setting arraystretch to zero, \renewcommand*{\arraystretch}{0} removes the spacing. \number\dp\strutbox gives 285084 scaled points, and 285084/65536 is approximately 4.35 pt. Note also that the array package used by ...

5

The reason for having floats at all is to avoid large spaces at page breaks which are more or less inevitable if you use H. Whether saving on paper matters so much in a digital age is an interesting and somewhat controversial question, the answer to which affects how you should approach float positioning. I'd use H as a last resort (and it was me that ...

1

Since not all packages are given, I can only guess about packages. It is a better method to change \arrayrulewidth within a group such that it does not interfere with other tables environments. Fortunately you are using a \newenvironment already, so it is quite comfortable to place it there. For better handling, it would be better to provide an (optional) ...

0

I have finally found a not perfect solution: setting manually the height of the bar cell shrinks the foo cell (setting height=fit for the foo cell does not work). \starttext \startTABLE \NC foo \NC[nr=2] \input knuth \NC \NR \NC[height=28ex] bar \NC \NR \stopTABLE \stoptext I have chosen 28ex for the ...

6

Here is a way to achieve what you want. It uses the array, tabularx and makecell package. I use the \multirowcell command, from makecell, which has a simpler syntax than multirow. Note that when you use \multirow, you must count the number of lines and not the number of cells if some cells are multilined. \documentclass{article} ...

0

Here is a shorter code, with only one tabular environment, using booktabs and hhline: \documentclass{article} \usepackage{array, booktabs, hhline} \begin{document} \begin{table}[!ht] \centering \begin{tabular}{|c|c|c| >{\qquad}c|c|c|} \multicolumn{6}{c}{XYZ} \\ \multicolumn{3}{c}{X} & \multicolumn{1}{c} ...

1

perhaps you have missed & between the two inner tabeles , You want a table like this and you change \documentclass{article} \begin{document} \begin{table}[!ht] \begin{center} \begin{tabular}{cc} \multicolumn{2}{c}{XYZ} \\ X & Y \\ \hline \\ \begin{tabular}{|c|c|c|} ...

3

Do you know where the problem lies, with your question? It's not that the option [nr=2] may or may not be needed, or that an image, albeit unnecessary, since you clearly provided the code, was included in such question, somewhat fulfilling a MWE requirement, to resolve it. But the problem, at least for me, was with a poorly written, last-minute, in the rush ...

2

Here is a compromise: I reduced hintscolumnwidth to 3.25cm and tabcolsep to 2.6pt. Another solution would be to keep 3.85cm for \hintscolwidth, have 4pt for \tabcolsep and use \footnotesize for the table. I used the showframe option of geometry to check if the table lies between the margins. To simplify the code I used the makecell: it defines a \thead ...

1

The following is too long to post as a follow-up comment on Mike Renfro's answer. It should be clear, though, that my posting isn't so much a separate answer as an implementation of some of Mike's suggestions and observations. Here, then, are some additional suggestions that will, hopefully, raise the visual and aesthetic appeal of the table: In tables, ...

2

I can think of two main options: first, use a substitution for common expressions. Second, make a savebox of a more complicated aligned equation, and insert that box into the table. This protects the & characters from being interpreted by the tabular environment. Also, in terms of general table layout, see the booktabs documentation. I've left your ...

0

It's not going to work because Pandoc hardcodes the use of longtable in its conversion or Markdown tables. Therefore, if you use Pandoc you need to use different table formats or write a Haskel or Python script to create a filter for Pandoc in order to make it work. Alternative may be to find another conversion program. Source: I asked the creator of ...

3

I traced down the problem to the \RL commands in the sentence \noindent Si anteponemos \RL{ا}, \RL{مَا}, o \RL{مَنْ} a \RL{هَذَا} , se convierte en una pregunta: Grouping those commands, as in \noindent Si anteponemos {\RL{ا}}, {\RL{مَا}}, o {\RL{مَنْ}} a {\RL{هَذَا}} , se convierte en una pregunta: solves the problem: ...

0

I found it out myself using multirow and creating tables within single cells. I post the code and the result in the following: \begin{table}[htbp]\centering \renewcommand{\arraystretch}{1.3} \caption[..]{..} \label{..} \begin{tabular}{c | c | c | c | c } \textbf{STATION} & \multicolumn{4}{c}{\textbf{SKEW VALUE}} \\ \hline ...

Top 50 recent answers are included