function q=mmhole(x,y,z,xlim,ylim) 8 d: X; q+ x- k8 x& z% `& D%MMHOLE Create Hole in 3D Graphics Data 6 e) s2 v, v; P% Z=MMHOLE(X,Y,Z,Xlim,Ylim) sets the data in Z to NaN4 \9 Q1 E/ w8 q7 z* D) R& ~. T
% corresponding to the limits in Xlim=[Xmin Xmax] and ; A! I8 F! H9 Z) q: `5 F% Z* L% Ylim=[Ymin Ymax]. If Xlim or Ylim are empty they are/ v( n; @4 y. D1 A
% assumed to be [-inf inf]. ' T2 g7 T6 v2 t# Q2 R! p! A' f8 Z5 Y2 q% X and Y can be plaid matrices, e.g., created by MESHGRID # O* H& T1 I% G6 U/ F! Q2 J/ }% or they can be vectors defining the x and y axes. # \" a$ l( }9 I/ M# j%3 D( k* u1 U( z! H5 m
% Z=MMHOLE(Z,Clim,Rlim) creates the NaN hole based on the , n2 C0 J: L( m# ]( |3 g
% column index limits in Clim and the row index limits in Rlim 4 d& w; l9 \/ }* X% S) w% 0 E% o$ M y+ d8 x* M# D% Resulting data can be plotted using mesh or surf:( e/ G. B% i/ V* }2 r
% MESH(X,Y,Z) or SURF(X,Y,Z)- E" _1 X! Z3 J% h( V5 k
% This function automates the procedure described on7 Z- j0 C2 ]5 ? p% i2 ]4 n5 A
% page 249 of "Mastering MATLAB". 7 m5 M: z# F+ x, |2 y . d2 R% y7 @. l8 ]1 j) X% D.C. Hanselman, University of Maine, Orono ME, 04469 ; A% q9 ?& r+ h2 r# L% 9/26/95 ! r' V% Y$ ?2 j6 D' |5 h% Copyright (c) 1996 by Prentice-Hall, Inc. X7 U/ ~, y1 d # l$ a* y! _2 h8 z) J4 X+ N* k7 uif nargin==3