Institut de Robòtica i Informàtica Industrial

GetFirstComponents

PURPOSE ^

Gets the first components of a GMixture.

SYNOPSIS ^

function gmOut=GetFirstComponents(gm,m)

DESCRIPTION ^

   Gets the first components of a GMixture.

   Returns a Gaussian mixture formed by the 'm' first elements of the
   input mixture.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function gmOut=GetFirstComponents(gm,m)
0002 %   Gets the first components of a GMixture.
0003 %
0004 %   Returns a Gaussian mixture formed by the 'm' first elements of the
0005 %   input mixture.
0006 
0007   if gm.n>m
0008     nw=gm.w(1:m);
0009     gmOut=GMixture(nw/sum(nw),gm.g(1:m));
0010   else
0011     gmOut=gm;
0012   end


Institut de Robòtica i Informàtica Industrial

Generated on Wed 05-Aug-2009 15:05:21 by m2html © 2003