Home > chronux > locfit > m > scb.m

scb

PURPOSE ^

Simultaneous Confidence Bands

SYNOPSIS ^

function z=scb(x,y,varargin)

DESCRIPTION ^

 Simultaneous Confidence Bands

 Example:
   load ethanol;
   z = scb(E,NOx,'h',0.5);

 result (z) is a matrix with four columns: evaluation points,
 fitted values, lower confidence limit, upper confidence limit.
 Most locfit arguments should work.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function z=scb(x,y,varargin)
0002 
0003 % Simultaneous Confidence Bands
0004 %
0005 % Example:
0006 %   load ethanol;
0007 %   z = scb(E,NOx,'h',0.5);
0008 %
0009 % result (z) is a matrix with four columns: evaluation points,
0010 % fitted values, lower confidence limit, upper confidence limit.
0011 % Most locfit arguments should work.
0012 
0013 fit = locfit(x,y,'ev','grid','mg',20,varargin{:});
0014 kap = kappa0(x,y,varargin{:});
0015 cb = predict(fit,'fitp','band','g','kappa',kap);
0016 z = [fit.fit_points.evaluation_points' cb{1} cb{3}];
0017 
0018 return;

Generated on Fri 28-Sep-2012 12:34:30 by m2html © 2005