public class NGram extends UnaryTransformer<scala.collection.Seq<String>,scala.collection.Seq<String>,NGram>
When the input is empty, an empty array is returned. When the input array length is less than n (number of elements per n-gram), no n-grams are returned.
Modifier and Type | Method and Description |
---|---|
int |
getN() |
static NGram |
load(String path) |
IntParam |
n()
Minimum n-gram length, >= 1.
|
NGram |
setN(int value) |
String |
uid()
An immutable unique ID for the object and its derivatives.
|
copy, setInputCol, setOutputCol, transform, transformSchema
transform, transform, transform
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
initializeIfNecessary, initializeLogging, isTraceEnabled, log_, log, logDebug, logDebug, logError, logError, logInfo, logInfo, logName, logTrace, logTrace, logWarning, logWarning
clear, copyValues, defaultCopy, defaultParamMap, explainParam, explainParams, extractParamMap, extractParamMap, get, getDefault, getOrDefault, getParam, hasDefault, hasParam, isDefined, isSet, paramMap, params, set, set, set, setDefault, setDefault, shouldOwn, validateParams
toString
public static NGram load(String path)
public String uid()
Identifiable
public IntParam n()
public NGram setN(int value)
public int getN()