Commit 521a48e9 authored by Houtan Bastani's avatar Houtan Bastani
Browse files

reporting: fix bug where a whole row wasn’t colored if the...

reporting: fix bug where a whole row wasn’t colored if the tableSubSectionHeader option was passed at the same time
parent 4a1c2afa
function o = writeSeriesForTable(o, fid, dates, precision)
%function o = writeSeriesForTable(o, fid, dates, precision)
function o = writeSeriesForTable(o, fid, dates, precision, ncols)
%function o = writeSeriesForTable(o, fid, dates, precision, ncols)
% Write Table Row
%
% INPUTS
......@@ -7,6 +7,7 @@ function o = writeSeriesForTable(o, fid, dates, precision)
% fid [int] file id
% dates [dates] dates for report_series slice
% precision [float] precision with which to print the data
% ncols [int] total number of columns in table
%
%
% OUTPUTS
......@@ -69,6 +70,9 @@ if ~isempty(o.tableRowColor)
end
if ~isempty(o.tableSubSectionHeader)
fprintf(fid, '%s', o.tableSubSectionHeader);
for i=1:ncols-1
fprintf(fid, ' &');
end
fprintf(fid, '\\\\%%\n');
return;
end
......
......@@ -170,7 +170,7 @@ fprintf(fid, '%%\n');
% Write Report_Table Data
for i=1:ne
o.series{i}.writeSeriesForTable(fid, o.range, o.precision);
o.series{i}.writeSeriesForTable(fid, o.range, o.precision, ncols);
if o.showHlines
fprintf(fid, '\\hline\n');
end
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment