private static void add ( DoubleVector semantics , TernaryVector index , double percentage ) { for ( int p : index . positiveDimensions ( ) ) semantics . ( p , percentage ) ; for ( int n : index . negativeDimensions ( ) ) semantics . ( n , - percentage ) ; }
Adds the index vector to the semantic vector using the percentage to specify how much of each dimesion is added .