@@ -570,7 +570,11 @@ function validate(obj)
570
570
ax = findobj(obj .State .Figure .Handle ,' Type' ,' axes' ,' -and' ,{' Tag' ,' ' ,' -or' ,' Tag' ,' PlotMatrixBigAx' ,' -or' ,' Tag' ,' PlotMatrixScatterAx' , ' -or' ,' Tag' ,' PlotMatrixHistAx' });
571
571
572
572
if isempty(ax )
573
- ax = gca ;
573
+ try
574
+ ax = get(obj .State .Figure .Handle ,' Children' );
575
+ catch
576
+ ax = gca ;
577
+ end
574
578
end
575
579
576
580
% ---------- checking the overlaping of the graphs ----------%
@@ -647,7 +651,9 @@ function validate(obj)
647
651
nprev = length(plots ) - np + 1 ;
648
652
649
653
% update the plot fields
650
- if ~strcmpi(getGraphClass(plots(nprev )), ' light' )
654
+ plotClass = lower(getGraphClass(plots(nprev )));
655
+
656
+ if ~ismember(plotClass , {' light' , ' polaraxes' })
651
657
obj.State.Figure.NumPlots = obj .State .Figure .NumPlots + 1 ;
652
658
obj .State .Plot(obj .State .Figure .NumPlots ).Handle = handle(plots(nprev ));
653
659
obj .State .Plot(obj .State .Figure .NumPlots ).AssociatedAxis = handle(ax(axrev ));
@@ -658,11 +664,16 @@ function validate(obj)
658
664
end
659
665
660
666
% this works for pareto
661
- if length(plots ) == 0 & obj .State .Figure .NumPlots ~= 0
662
- isPareto = length(ax ) >= 2 & obj .State .Figure .NumPlots >= 2 ;
663
- isBar = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots ).Class), ' line' );
664
- isLine = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots - 1 ).Class), ' bar' );
665
- isPareto = isPareto & isBar & isLine ;
667
+ if length(plots ) == 0
668
+
669
+ try
670
+ isPareto = length(ax ) >= 2 & obj .State .Figure .NumPlots >= 2 ;
671
+ isBar = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots ).Class), ' line' );
672
+ isLine = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots - 1 ).Class), ' bar' );
673
+ isPareto = isPareto & isBar & isLine ;
674
+ catch
675
+ isPareto = false ;
676
+ end
666
677
667
678
if isPareto
668
679
obj .State .Plot(obj .State .Figure .NumPlots ).AssociatedAxis = handle(ax(axrev ));
@@ -784,6 +795,9 @@ function validate(obj)
784
795
else
785
796
if ~obj .PlotlyDefaults .isTernary
786
797
updateAnnotation(obj ,n );
798
+ if obj .State .Figure .NumAxes == 1
799
+ obj.PlotOptions.CleanFeedTitle = false ;
800
+ end
787
801
end
788
802
end
789
803
catch
0 commit comments