patchhandles.m

来自「JLAB is a set of Matlab functions I have」· M 代码 · 共 34 行

M
34
字号
function[h1,h2]=patchhandles(axh)%PATCHHANDES  Finds all patch handles from a given set of axes.%%   H=PATCHHANDLES returns handles to all lines associated with the%   current axes.%	 %   H=PATCHHANDLES(AX) returns handles to all lines associated with%   the set of axes whose handle is AX.%%   See also LINEHANDLES, AXESHANDLES%   _________________________________________________________________%   This is part of JLAB --- type 'help jlab' for more information%   (C) 2004--2006 J.M. Lilly --- type 'help jlab_license' for details          if nargin==0   axh=gca;endh=get(axh,'children');if strcmp(get(h,'type'),'hggroup')    h=get(h,'children');endbool=0*h;for j=1:length(h)    if strcmp(get(h(j),'type'),'patch')       bool(j)=1;    endendindex1=find(bool);index2=find(~bool);h1=h(index1);     h2=h(index2);     

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?