I have the following dataframe with array of doubles that need to be converted to Vectors in order to pass it to an ML algorithm. Can anyone help me with this?
fList: org.apache.spark.sql.DataFrame = [features: array<double>]
+--------------------------------------------------------------------------------+
|features |
+--------------------------------------------------------------------------------+
|[2.5046410000000003, 2.1487149999999997, 1.0884870000000002, 3.5877090000000003]|
|[0.9558040000000001, 0.9843780000000002, 0.545025, 0.9979860000000002] |
+--------------------------------------------------------------------------------+
Expected Output: Should look something like this.
fList: org.apache.spark.sql.DataFrame = [features: vector]