0001 function lfband(fit,varargin)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012 xfit = lfmarg(fit);
0013
0014
0015 ypp = predict(fit,xfit,'band','g',varargin{:});
0016 yfit = ypp{1};
0017 se = ypp{2};
0018 bands = ypp{3};
0019
0020 data = fit{1};
0021 xdata = data{1};
0022 p = size(xdata,2);
0023 cv = 1.96;
0024 fali = fit{4}{5};
0025 cl = invlink(bands(:,1),fali);
0026 cu = invlink(bands(:,2),fali);
0027 if (p==1)
0028 hold on;
0029 plot(xfit{1},cu,':');
0030 plot(xfit{1},cl,':');
0031 hold off;
0032 end;
0033
0034 if (p==2)
0035 x1 = xfit{1};
0036 x2 = xfit{2};
0037 figure(1);
0038 surf(x1,x2,reshape(cl,length(x1),length(x2))');
0039 figure(2);
0040 surf(x1,x2,reshape(cu,length(x1),length(x2))');
0041 end;
0042
0043 return;