Path: SpacecraftEstimation/StellarAttDet
% CREATEKVECTOR Create the k vector from an array of data The k vector gives the number of elements in the sorted data that lie below a linear fit - k(i) gives the number of elements below z(i), where the line z is defined as z(i) = m*i + q The k indices are for the sorted data. If the data is not sorted on input, it will be and the sorted data is returned in s. Type CreateKVector for a demo (produces 2 figures). --------------------------------------------------------------------- Form: [k,m,q,s] = CreateKVector( data ) --------------------------------------------------------------------- ------ Inputs ------ data (1,:) Array of data (star angles) ------- Outputs ------- k (1,:) Set of integer indices m (1,1) Slope of linear fit q (1,1) Intercept of linear fit s (1,:) Sorted data --------------------------------------------------------------------- See also: SearchKVector ---------------------------------------------------------------------
Common: General/Watermark Common: Graphics/NewFig
Back to the SpacecraftEstimation Module page