void add ( final double m , final Object pt ) { if ( count == 0 ) { set ( m , pt ) ; } else { count += 1 ; if ( m != 0.0 ) { m0 += m ; clusters . space . addScaled ( m1 , m , pt ) ; clusters . space . addScaledSqr ( m2 , m , pt ) ; update ( ) ; } } }
Adds a point to the cluster .