Commit f02e7f77 authored by Houtan Bastani's avatar Houtan Bastani
Browse files

reporting: support a different shape for the axis in a graph

parent 168acbe6
......@@ -40,6 +40,8 @@ o.titleFormat = '';
o.ylabel = '';
o.xlabel = '';
o.axisShape = 'box';
o.graphDirName = 'tmpRepDir';
o.graphName = '';
o.data = '';
......@@ -140,7 +142,8 @@ assert(any(strcmp(o.shadeColor, valid_shadeColor)), ['@graph.graph: shadeColor m
strjoin(valid_shadeColor)]);
assert(any(strcmp(o.zeroLineColor, valid_shadeColor)), ...
['@graph.graph: zeroLineColor must be one of ' strjoin(valid_shadeColor)]);
assert(any(strcmp(o.axisShape, {'box', 'L'})), ['@graph.graph: shadeColor ' ...
'must be one of ''box'' or ''L''']);
valid_legend_locations = ...
{'south west','south east','north west','north east','outer north east'};
assert(any(strcmp(o.legendLocation, valid_legend_locations)), ...
......
......@@ -119,9 +119,14 @@ fprintf(fid, ['},\n',...
'width=%fin,\n'...
'height=%fin,\n'...
'scale only axis,\n'...
'axis lines=box,\n'...
'unbounded coords=jump,\n'], o.width, o.height);
if strcmpi(o.axisShape, 'box')
fprintf(fid, 'axis lines=box,\n');
elseif strcmpi(o.axisShape, 'L')
fprintf(fid, 'axis x line=bottom,\naxis y line=left,\n');
end
if ~isempty(o.title{1})
fprintf(fid, 'title style={align=center');
if ~isempty(o.titleFormat)
......
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