public class SparseOneHotEncoder
extends java.lang.Object
| Constructor and Description |
|---|
SparseOneHotEncoder(smile.data.type.StructType schema)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int[][] |
apply(smile.data.DataFrame data)
Generates the compact representation of sparse binary features for a data frame.
|
int[] |
apply(smile.data.Tuple x)
Generates the compact representation of sparse binary features for given object.
|
public SparseOneHotEncoder(smile.data.type.StructType schema)
schema - the variable attributes. All of them have to be
nominal attributes.public int[] apply(smile.data.Tuple x)
x - an object of interest.public int[][] apply(smile.data.DataFrame data)
data - a data frame.