fix(matlab): rate 0.02 grid, batch 4

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Experiments DB Dev
2026-07-24 10:37:11 -04:00
parent 43666b1dc6
commit 2885ad1eee
12 changed files with 48 additions and 16 deletions
Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 47 KiB

@@ -54,12 +54,20 @@ if strcmp(metric, 'count') % count: tick every 5, but label only every 10
if mod(yt(k), 10) == 0; lbl{k} = num2str(yt(k)); else; lbl{k} = ''; end
end
set(gca, 'YTick', yt, 'YTickLabel', lbl);
else % rate: fine minor tick marks every 0.02 (no labels)
else % rate: tick every 0.02, label only every 0.1
yl = ylim(gca);
set(gca, 'YMinorTick', 'on');
ax = gca; ax.YAxis.MinorTickValues = 0 : 0.02 : ceil(yl(2) / 0.02) * 0.02;
yt = 0 : 0.02 : ceil(yl(2) / 0.02) * 0.02;
lbl = cell(1, numel(yt));
for k = 1:numel(yt)
if abs(yt(k) / 0.1 - round(yt(k) / 0.1)) < 1e-9 % multiple of 0.1
lbl{k} = num2str(round(yt(k), 1));
else
lbl{k} = '';
end
end
set(gca, 'YTick', yt, 'YTickLabel', lbl);
end
grid on
grid on % gridlines fall on the ticks (rate: every 0.02)
% Add breathing room between the y-axis label and the tick numbers.
set(ylh, 'Units', 'normalized');
yp = get(ylh, 'Position');