Table next to figure with table caption on top but figure caption on bottom
up vote
4
down vote
favorite
I use the following code, which I modified from the code I found here (second example), to place a table next to a figure.
However, in comparison to the example linked above, I would like to have the figure caption be placed on the bottom of the figure and the table caption on the top of the table, while both should be aligned correctly at the bottom. So the figure caption should be aligned with the bottom of the table.
Unfortunatly, the following code shifts the table and the figure vertically, such that they are not aligned.
How can I fix that?
documentclass[11pt,a4paper,english]{article}
usepackage[T1]{fontenc}
usepackage[utf8]{inputenc}
usepackage{babel}
usepackage[font=small,labelfont=bf,tableposition=top]{caption}
begin{document}
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{6.4cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}{cc}hline
Table head & Table head \ hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \ hline
end{tabular}
end{minipage}
end{minipage}
end{document}
Edit: Changed height of figure.
tables floats subfloats
add a comment |
up vote
4
down vote
favorite
I use the following code, which I modified from the code I found here (second example), to place a table next to a figure.
However, in comparison to the example linked above, I would like to have the figure caption be placed on the bottom of the figure and the table caption on the top of the table, while both should be aligned correctly at the bottom. So the figure caption should be aligned with the bottom of the table.
Unfortunatly, the following code shifts the table and the figure vertically, such that they are not aligned.
How can I fix that?
documentclass[11pt,a4paper,english]{article}
usepackage[T1]{fontenc}
usepackage[utf8]{inputenc}
usepackage{babel}
usepackage[font=small,labelfont=bf,tableposition=top]{caption}
begin{document}
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{6.4cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}{cc}hline
Table head & Table head \ hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \ hline
end{tabular}
end{minipage}
end{minipage}
end{document}
Edit: Changed height of figure.
tables floats subfloats
2
Does usingbegin{minipage}[c]
insteadbegin{minipage}[b]
for both minipages give more like what you want?
– David Purton
Nov 11 at 6:39
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10
add a comment |
up vote
4
down vote
favorite
up vote
4
down vote
favorite
I use the following code, which I modified from the code I found here (second example), to place a table next to a figure.
However, in comparison to the example linked above, I would like to have the figure caption be placed on the bottom of the figure and the table caption on the top of the table, while both should be aligned correctly at the bottom. So the figure caption should be aligned with the bottom of the table.
Unfortunatly, the following code shifts the table and the figure vertically, such that they are not aligned.
How can I fix that?
documentclass[11pt,a4paper,english]{article}
usepackage[T1]{fontenc}
usepackage[utf8]{inputenc}
usepackage{babel}
usepackage[font=small,labelfont=bf,tableposition=top]{caption}
begin{document}
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{6.4cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}{cc}hline
Table head & Table head \ hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \ hline
end{tabular}
end{minipage}
end{minipage}
end{document}
Edit: Changed height of figure.
tables floats subfloats
I use the following code, which I modified from the code I found here (second example), to place a table next to a figure.
However, in comparison to the example linked above, I would like to have the figure caption be placed on the bottom of the figure and the table caption on the top of the table, while both should be aligned correctly at the bottom. So the figure caption should be aligned with the bottom of the table.
Unfortunatly, the following code shifts the table and the figure vertically, such that they are not aligned.
How can I fix that?
documentclass[11pt,a4paper,english]{article}
usepackage[T1]{fontenc}
usepackage[utf8]{inputenc}
usepackage{babel}
usepackage[font=small,labelfont=bf,tableposition=top]{caption}
begin{document}
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{6.4cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}{cc}hline
Table head & Table head \ hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \ hline
end{tabular}
end{minipage}
end{minipage}
end{document}
Edit: Changed height of figure.
tables floats subfloats
tables floats subfloats
edited Nov 11 at 7:09
asked Nov 11 at 6:14
SampleTime
2426
2426
2
Does usingbegin{minipage}[c]
insteadbegin{minipage}[b]
for both minipages give more like what you want?
– David Purton
Nov 11 at 6:39
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10
add a comment |
2
Does usingbegin{minipage}[c]
insteadbegin{minipage}[b]
for both minipages give more like what you want?
– David Purton
Nov 11 at 6:39
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10
2
2
Does using
begin{minipage}[c]
instead begin{minipage}[b]
for both minipages give more like what you want?– David Purton
Nov 11 at 6:39
Does using
begin{minipage}[c]
instead begin{minipage}[b]
for both minipages give more like what you want?– David Purton
Nov 11 at 6:39
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10
add a comment |
1 Answer
1
active
oldest
votes
up vote
3
down vote
accepted
Set the tabular
to be aligned at the [b]
aseline as well:
documentclass{article}
usepackage[
font = small,
labelfont = bf,
tableposition = top
]{caption}
begin{document}
noindent
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{5.5cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}[b]{cc}
hline
Table head & Table head \
hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
hline
end{tabular}
end{minipage}
end{minipage}
end{document}
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
accepted
Set the tabular
to be aligned at the [b]
aseline as well:
documentclass{article}
usepackage[
font = small,
labelfont = bf,
tableposition = top
]{caption}
begin{document}
noindent
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{5.5cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}[b]{cc}
hline
Table head & Table head \
hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
hline
end{tabular}
end{minipage}
end{minipage}
end{document}
add a comment |
up vote
3
down vote
accepted
Set the tabular
to be aligned at the [b]
aseline as well:
documentclass{article}
usepackage[
font = small,
labelfont = bf,
tableposition = top
]{caption}
begin{document}
noindent
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{5.5cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}[b]{cc}
hline
Table head & Table head \
hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
hline
end{tabular}
end{minipage}
end{minipage}
end{document}
add a comment |
up vote
3
down vote
accepted
up vote
3
down vote
accepted
Set the tabular
to be aligned at the [b]
aseline as well:
documentclass{article}
usepackage[
font = small,
labelfont = bf,
tableposition = top
]{caption}
begin{document}
noindent
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{5.5cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}[b]{cc}
hline
Table head & Table head \
hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
hline
end{tabular}
end{minipage}
end{minipage}
end{document}
Set the tabular
to be aligned at the [b]
aseline as well:
documentclass{article}
usepackage[
font = small,
labelfont = bf,
tableposition = top
]{caption}
begin{document}
noindent
begin{minipage}{textwidth}
begin{minipage}[b]{0.49textwidth}
centering
rule{5.5cm}{2.6cm} % Height changed from 3.6cm to 2.6cm
captionof{figure}{A table beside a figure}
end{minipage}
hfill
begin{minipage}[b]{0.49textwidth}
centering
captionof{table}{A table beside a figure}
begin{tabular}[b]{cc}
hline
Table head & Table head \
hline
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
Some values & Some values \
hline
end{tabular}
end{minipage}
end{minipage}
end{document}
answered Nov 11 at 7:16
Werner
433k609531634
433k609531634
add a comment |
add a comment |
Thanks for contributing an answer to TeX - LaTeX Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f459423%2ftable-next-to-figure-with-table-caption-on-top-but-figure-caption-on-bottom%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
2
Does using
begin{minipage}[c]
insteadbegin{minipage}[b]
for both minipages give more like what you want?– David Purton
Nov 11 at 6:39
Almost, thanks. I edited my question.
– SampleTime
Nov 11 at 7:10