Skip to content

Commit 858e884

Browse files
committed
check for box plot for label fix
1 parent 874a91f commit 858e884

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

plotly/plotlyfig_aux/core/updateData.m

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@
9696
end
9797

9898
% check for xaxis categories
99-
if strcmpi(xaxis.type, 'category')
99+
if strcmpi(xaxis.type, 'category') && ...
100+
~strcmp(obj.data{dataIndex}.type,'box')
100101
obj.data{dataIndex}.x = get(obj.State.Plot(dataIndex).AssociatedAxis,'XTickLabel');
101102
end
102103

@@ -106,9 +107,11 @@
106107
end
107108

108109
% check for yaxis categories
109-
if strcmpi(yaxis.type, 'category')
110+
if strcmpi(yaxis.type, 'category') && ...
111+
~strcmp(obj.data{dataIndex}.type,'box')
110112
obj.data{dataIndex}.y = get(obj.State.Plot(dataIndex).AssociatedAxis,'YTickLabel');
111113
end
114+
112115
%-------------------------------------------------------------------------%
113116

114117
end

0 commit comments

Comments
 (0)