How can I use multicolumn in a pgfplotstable table?
up vote
3
down vote
favorite
In my experiments with pgfplotstable, I've run into some bumps:
- merging multiple columns
- adding formatting commands to text within cells
Problem
I cannot seem to properly add a multicolumn{}{}{} to my portable graphics format plot table.
I've viewed the following questions:
- Multiple Multi columns with pgfplotstable
- Pgfplotstable multicolumn table with dec sep align and Tabularx
Example
documentclass{article}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}}
}%
begin{document}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} % <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
tables pgfplotstable multicolumn
add a comment |
up vote
3
down vote
favorite
In my experiments with pgfplotstable, I've run into some bumps:
- merging multiple columns
- adding formatting commands to text within cells
Problem
I cannot seem to properly add a multicolumn{}{}{} to my portable graphics format plot table.
I've viewed the following questions:
- Multiple Multi columns with pgfplotstable
- Pgfplotstable multicolumn table with dec sep align and Tabularx
Example
documentclass{article}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}}
}%
begin{document}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} % <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
tables pgfplotstable multicolumn
add a comment |
up vote
3
down vote
favorite
up vote
3
down vote
favorite
In my experiments with pgfplotstable, I've run into some bumps:
- merging multiple columns
- adding formatting commands to text within cells
Problem
I cannot seem to properly add a multicolumn{}{}{} to my portable graphics format plot table.
I've viewed the following questions:
- Multiple Multi columns with pgfplotstable
- Pgfplotstable multicolumn table with dec sep align and Tabularx
Example
documentclass{article}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}}
}%
begin{document}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} % <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
tables pgfplotstable multicolumn
In my experiments with pgfplotstable, I've run into some bumps:
- merging multiple columns
- adding formatting commands to text within cells
Problem
I cannot seem to properly add a multicolumn{}{}{} to my portable graphics format plot table.
I've viewed the following questions:
- Multiple Multi columns with pgfplotstable
- Pgfplotstable multicolumn table with dec sep align and Tabularx
Example
documentclass{article}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}}
}%
begin{document}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} % <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
tables pgfplotstable multicolumn
tables pgfplotstable multicolumn
edited Apr 13 '17 at 12:35
Community♦
1
1
asked Mar 31 '15 at 16:49
Jonathan Komar
6,44632977
6,44632977
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
I think it is better to give a true minmal working example. There is much stuff, which has nothing to do with the problem...
Maybe, you are looking for something like this:
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}

% arara: lualatex
%documentclass{article}
documentclass[margin=5mm]{standalone}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
%usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}
},
%
}%
begin{document}
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} \% <-- Replacing the cells "good" and look" with this causes problems
}%
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
0
down vote
I think it is better to give a true minmal working example. There is much stuff, which has nothing to do with the problem...
Maybe, you are looking for something like this:
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}

% arara: lualatex
%documentclass{article}
documentclass[margin=5mm]{standalone}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
%usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}
},
%
}%
begin{document}
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} \% <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
add a comment |
up vote
0
down vote
I think it is better to give a true minmal working example. There is much stuff, which has nothing to do with the problem...
Maybe, you are looking for something like this:
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}

% arara: lualatex
%documentclass{article}
documentclass[margin=5mm]{standalone}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
%usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}
},
%
}%
begin{document}
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} \% <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
add a comment |
up vote
0
down vote
up vote
0
down vote
I think it is better to give a true minmal working example. There is much stuff, which has nothing to do with the problem...
Maybe, you are looking for something like this:
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}

% arara: lualatex
%documentclass{article}
documentclass[margin=5mm]{standalone}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
%usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}
},
%
}%
begin{document}
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} \% <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
I think it is better to give a true minmal working example. There is much stuff, which has nothing to do with the problem...
Maybe, you are looking for something like this:
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}

% arara: lualatex
%documentclass{article}
documentclass[margin=5mm]{standalone}
usepackage{fontspec}
usepackage{booktabs}
usepackage{pgfplotstable}
%usepackage{multicol}% <-- Don't think this is needed.
pgfplotstableset{% Global config
every head row/.style={before row=toprule,after row=midrule},
every last row/.style={after row=bottomrule},
col sep=&,
row sep=\,
column type=l,
column type={>{fontseries{bx}selectfontcolor{orange}}l}, %see sec 2.6 for defining column types
string type,
postproc cell content/.append style={ % see sec 3.2
/pgfplots/table/@cell content/.add={fontseries{seriesdefault}selectfontcolor{black}}{}
},
%
}%
begin{document}
pgfplotstableset{
every row no 0/.append style={after row={
for & multicolumn{2}{c}{color{red} good looks} \
}},
}
pgfplotstabletypeset{%
col1 & col2 & col3\
here & more & stuff\
for & good & looks \ % multicolumn{2}{c}{good looks} \% <-- Replacing the cells "good" and look" with this causes problems
}%
end{document}
answered Oct 26 at 17:53
cis
617514
617514
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%2f236215%2fhow-can-i-use-multicolumn-in-a-pgfplotstable-table%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