spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From SK <skrishna...@gmail.com>
Subject Extracting an element from the feature vector in LabeledPoint
Date Fri, 01 Aug 2014 02:01:41 GMT

Hi,

I want to extract the individual elements of a feature vector that is part
of a LabeledPoint. I tried the following:

data.features._1
data.features(1)
data.features.map(_.1)


data is a LabeledPoint with a feature vector containing 3 features. All of
the above resulted in  compilation errors. What is the right way to extract
the elements of the feature vector?

thanks



--
View this message in context: http://apache-spark-user-list.1001560.n3.nabble.com/Extracting-an-element-from-the-feature-vector-in-LabeledPoint-tp11110.html
Sent from the Apache Spark User List mailing list archive at Nabble.com.

Mime
View raw message