public static double [ ] normalizePower ( double [ ] vector , double aParameter ) { for ( int i = 0 ; i < vector . length ; i ++ ) { vector [ i ] = Math . signum ( vector [ i ] ) * Math . pow ( Math . abs ( vector [ i ] ) , aParameter ) ; } return vector ; }
This method applies power normalization on a given array of doubles . The passed vector is modified by the method .