public final class CategoricalValueEncodings extends Object implements Serializable
Constructor and Description |
---|
CategoricalValueEncodings(Map<Integer,? extends Collection<String>> distinctValues) |
Modifier and Type | Method and Description |
---|---|
Map<Integer,Integer> |
getCategoryCounts() |
Map<Integer,String> |
getEncodingValueMap(int index) |
int |
getValueCount(int index) |
Map<String,Integer> |
getValueEncodingMap(int index) |
String |
toString() |
public CategoricalValueEncodings(Map<Integer,? extends Collection<String>> distinctValues)
distinctValues
- map of categorical feature indices, to the set of distinct
values for that categorical feature. Order matters.public Map<String,Integer> getValueEncodingMap(int index)
index
- feature indexpublic Map<Integer,String> getEncodingValueMap(int index)
index
- feature indexpublic int getValueCount(int index)
index
- feature indexpublic Map<Integer,Integer> getCategoryCounts()
Copyright © 2014–2018. All rights reserved.