Creates a dense vector from a double array.
Creates a dense vector from its values.
Creates a dense vector from its values.
Parses a string resulted from Vector#toString
into
an org.apache.spark.mllib.linalg.Vector.
Creates a sparse vector using unordered (index, value) pairs in a Java friendly way.
Creates a sparse vector using unordered (index, value) pairs in a Java friendly way.
vector size.
vector elements in (index, value) pairs.
Creates a sparse vector using unordered (index, value) pairs.
Creates a sparse vector using unordered (index, value) pairs.
vector size.
vector elements in (index, value) pairs.
Creates a sparse vector providing its index array and value array.
Creates a sparse vector providing its index array and value array.
vector size.
index array, must be strictly increasing.
value array, must have the same length as indices.
Creates a dense vector of all zeros.
Creates a dense vector of all zeros.
vector size
a zero vector
Factory methods for org.apache.spark.mllib.linalg.Vector. We don't use the name
Vector
because Scala imports scala.collection.immutable.Vector by default.