Package org.apache.spark.mllib.feature
Class ElementwiseProduct
Object
org.apache.spark.mllib.feature.ElementwiseProduct
- All Implemented Interfaces:
Serializable
,VectorTransformer
Outputs the Hadamard product (i.e., the element-wise product) of each input vector with a
provided "weight" vector. In other words, it scales each column of the dataset by a scalar
multiplier.
param: scalingVec The values used to scale the reference vector's individual components.
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionDoes the hadamard product transformation.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.spark.mllib.feature.VectorTransformer
transform, transform
-
Constructor Details
-
ElementwiseProduct
-
-
Method Details
-
scalingVec
-
transform
Does the hadamard product transformation.- Specified by:
transform
in interfaceVectorTransformer
- Parameters:
vector
- vector to be transformed.- Returns:
- transformed vector.
-