@@ -584,7 +584,11 @@ function validate(obj)
584
584
ax = findobj(obj .State .Figure .Handle ,' Type' ,' axes' ,' -and' ,{' Tag' ,' ' ,' -or' ,' Tag' ,' PlotMatrixBigAx' ,' -or' ,' Tag' ,' PlotMatrixScatterAx' , ' -or' ,' Tag' ,' PlotMatrixHistAx' });
585
585
586
586
if isempty(ax )
587
- ax = gca ;
587
+ try
588
+ ax = get(obj .State .Figure .Handle ,' Children' );
589
+ catch
590
+ ax = gca ;
591
+ end
588
592
end
589
593
590
594
% ---------- checking the overlaping of the graphs ----------%
@@ -661,7 +665,9 @@ function validate(obj)
661
665
nprev = length(plots ) - np + 1 ;
662
666
663
667
% update the plot fields
664
- if ~strcmpi(getGraphClass(plots(nprev )), ' light' )
668
+ plotClass = lower(getGraphClass(plots(nprev )));
669
+
670
+ if ~ismember(plotClass , {' light' , ' polaraxes' })
665
671
obj.State.Figure.NumPlots = obj .State .Figure .NumPlots + 1 ;
666
672
obj .State .Plot(obj .State .Figure .NumPlots ).Handle = handle(plots(nprev ));
667
673
obj .State .Plot(obj .State .Figure .NumPlots ).AssociatedAxis = handle(ax(axrev ));
@@ -672,11 +678,16 @@ function validate(obj)
672
678
end
673
679
674
680
% this works for pareto
675
- if length(plots ) == 0 & obj .State .Figure .NumPlots ~= 0
676
- isPareto = length(ax ) >= 2 & obj .State .Figure .NumPlots >= 2 ;
677
- isBar = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots ).Class), ' line' );
678
- isLine = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots - 1 ).Class), ' bar' );
679
- isPareto = isPareto & isBar & isLine ;
681
+ if length(plots ) == 0
682
+
683
+ try
684
+ isPareto = length(ax ) >= 2 & obj .State .Figure .NumPlots >= 2 ;
685
+ isBar = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots ).Class), ' line' );
686
+ isLine = strcmpi(lower(obj .State .Plot(obj .State .Figure .NumPlots - 1 ).Class), ' bar' );
687
+ isPareto = isPareto & isBar & isLine ;
688
+ catch
689
+ isPareto = false ;
690
+ end
680
691
681
692
if isPareto
682
693
obj .State .Plot(obj .State .Figure .NumPlots ).AssociatedAxis = handle(ax(axrev ));
@@ -798,6 +809,9 @@ function validate(obj)
798
809
else
799
810
if ~obj .PlotlyDefaults .isTernary
800
811
updateAnnotation(obj ,n );
812
+ if obj .State .Figure .NumAxes == 1
813
+ obj.PlotOptions.CleanFeedTitle = false ;
814
+ end
801
815
end
802
816
end
803
817
catch
0 commit comments