No BSD License
-
[Y,T]=derivs(x,dim)
-
[Y,T]=phasespace(x,dim,tau)
-
[dlogCr,dlogr,dlogCrCI]=vr(lo...
Syntax: [dlogCr,dlogr,dlogCrCI]=vr(logCr,logr,alpha)
-
[logCr,logr]=gencorint(x,dim,...
-
[pc,s,v]=SSA(x,dim,tau)
-
[s,iter]=IAAFT(x,c,maxiter)
-
[sigma,dkm,g,r]=noiseest(dlog...
Syntax: [sigma,dkm,g,r]=noiseest(dlogCr,dlogr,method)
-
[x,y,z]=lorentz(n,level,s,r,b...
-
[x,y,z]=rossler(n,level,a,b,c...
-
[x,y]=henon(n,level,a,b,x0,y0...
-
[x,y]=ikeda(n,level,mu,x0,y0)
-
[xr,Yr]=noisergeo(x,dim,tau,r...
-
lock=Knearest(y,Y,K,p)
-
lock=radnearest(y,Y,T,r,p)
-
s=AAFT(x,c)
-
s=phaseran(x,c)
-
s=shuffle(x,c)
-
x=logistic(n,level,a,x0)
-
x=mackeyglass(n,level,a,b,c,x...
-
x=quadratic(n,level,c,x0)
-
xf=SSAeye(x,dim,tau,k,fs,e)
-
xf=SSAforeiter(x,dim,tau,k,fs...
-
xr=SSAinv(pc,v,tau,k)
-
xr=noiserSchreiber(x,K,L,r,re...
Syntax: xr=noiserSchreiber(x,K,L,r,repeat,auto)
-
Contents.m
-
View all files
|
|
| s=shuffle(x,c)
|
function s=shuffle(x,c)
%Syntax: s=shuffle(x,c)
%______________________
%
% Makes c shuffled surrogates of a time series x.
%
% s is the shuffled time series.
% x is the original time series.
% c is the number of surrogates.
%
%
% References:
%
% Theiler J, Galdrikian B, Longtin A, Eubank S, Farmer D J (1992): Using
% Surrogate Data to Detect Nonlinearity in Time Series. In Nonlinear Modeling
% and Forecasting, eds. Casdagli M & Eubank S. 163-188. Addison-Wesley
%
% Theiler J, Eubank S,Galdrikian B, Longtin A, Farmer D J (1992): Testing
% for nonlinearity in time series: the method of surrogate data. Physica D
% 58: 77-94
%
%
% Alexandros Leontitsis
% Department of Education
% University of Ioannina
% 45110 - Dourouti
% Ioannina
% Greece
%
% University e-mail: me00743@cc.uoi.gr
% Lifetime e-mail: leoaleq@yahoo.com
% Homepage: http://www.geocities.com/CapeCanaveral/Lab/1421
%
% 12 Apr 2001.
if nargin<1 | isempty(x)==1
error('You should provide a time series.');
else
% x must be a vector
if min(size(x))>1
error('Invalid time series.');
end
x=x(:);
% N is the time series length
N=length(x);
end
if nargin<2 | isempty(c)==1
c=1;
else
% c must be scalar
if sum(size(c))>2
error('c must be scalar.');
end
% c must be greater or equal than 1
if c<1
error('c must be greater or equal than 1.');
end
end
for i=1:c
% Make a random vector with indices up to n
s1=randperm(N);
% Shuffle the original x with respect to s1
s(:,i)=x(s1);
end
|
|
Contact us at files@mathworks.com