Hi everyone, This may sound like a stupid question but I need to be sure of this :
Given a dataframe composed by « n » features : f1, f2, …, fn For each row of my dataframe, I create a labeled point : val row_i = LabeledPoint(label, Vectors.dense(v1_i,v2_i,…, vn_i) ) where v1_i,v2_i,…, vn_i are respectively the values of the features f1, f2, …, fn of the i th row. Then, I fit a pipeline composed by a standardScaler and a logisticRegression model. When I get back my LogisticRegressionModel and StandardScalerModel from the pipeline, I’m calling the getters : LogisticRegressionModel.coefficients, StandardScalerModel.mean and StandardScalerModel.std This gives me 3 vectors of length « n » My question is the following : Am I assured that the element of index « j » of each vectors correspond to the feature « j » ? Is the "*order*" of the feature kept ? e.g : Is StandardScalerModel.mean(j) the mean of the feature « j » of my data frame ? Thanks for your time. Regards, J. -- View this message in context: http://apache-spark-user-list.1001560.n3.nabble.com/MLLib-Is-the-order-of-the-coefficients-in-a-LogisticRegresionModel-kept-tp26137.html Sent from the Apache Spark User List mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
