You are here: Symbol Reference > MtxExpr Namespace > Classes > Vector Record > public > DownSample Method > Vector.DownSample Method (TMtxVec, integer, integer)
MtxVec VCL
ContentsIndex
PreviousUpNext
Vector.DownSample Method (TMtxVec, integer, integer)

Downsamples vector values.

Pascal
function DownSample(const Src: TMtxVec; Factor: integer; Phase: integer = 0): TVec; overload;

The methods copies only every Factor sample from the Src vector to the calling vector. The Length and Complex properties of the calling vector are set implicitly. The phase parameter determines the initial sample offset. Phase must be less than Factor.

var a,b: Vector; begin b.SetIt(False,[0,0,0,0,1,2,3,4,5,6]); a.DownSample(b,2); // a = [0,0,1,3,5] end;
Examples on GitHub
Copyright (c) 1999-2025 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!