Hi, 

I have a DataFrame df with a column "feature" of type SparseVector that
results from the ml library's VectorAssembler class. 

I'd like to get a Dataset of SparseVectors from this column, but when I do a 

df.as[SparseVector] scala complains that it doesn't know of an encoder for
SparseVector. If I then try to implement the Encoder[T] interface for
SparseVector I get the error
"java.lang.RuntimeException: Only expression encoders are supported today"

How can I get a Dataset[SparseVector] from the output of VectorAssembler?



--
View this message in context: 
http://apache-spark-user-list.1001560.n3.nabble.com/Dataset-Encoders-for-SparseVector-tp26149.html
Sent from the Apache Spark User List mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@spark.apache.org
For additional commands, e-mail: user-h...@spark.apache.org

Reply via email to