public class DatasetUtils
extends Object
Constructor and Description |
---|
DatasetUtils() |
Modifier and Type | Method and Description |
---|---|
static RDD<Vector> |
columnToOldVector(Dataset<?> dataset,
String colName) |
static Column |
columnToVector(Dataset<?> dataset,
String colName)
Cast a column in a Dataset to Vector type.
|
public static Column columnToVector(Dataset<?> dataset, String colName)
The supported data types of the input column are - Vector - float/double type Array.
Note: The returned column does not have Metadata.
dataset
- input DataFramecolName
- column name.