class HashingTF extends Serializable
Maps a sequence of terms to their term frequencies using the hashing trick.
- Annotations
- @Since( "1.1.0" )
- Source
- HashingTF.scala
- Alphabetic
- By Inheritance
- HashingTF
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native() @IntrinsicCandidate()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
-
def
indexOf(term: Any): Int
Returns the index of the input term.
Returns the index of the input term.
- Annotations
- @Since( "1.1.0" )
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- val numFeatures: Int
-
def
setBinary(value: Boolean): HashingTF.this.type
If true, term frequency vector will be binary such that non-zero term counts will be set to 1 (default: false)
If true, term frequency vector will be binary such that non-zero term counts will be set to 1 (default: false)
- Annotations
- @Since( "2.0.0" )
-
def
setHashAlgorithm(value: String): HashingTF.this.type
Set the hash algorithm used when mapping term to integer.
Set the hash algorithm used when mapping term to integer. (default: murmur3)
- Annotations
- @Since( "2.0.0" )
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
transform[D <: Iterable[_]](dataset: JavaRDD[D]): JavaRDD[Vector]
Transforms the input document to term frequency vectors (Java version).
Transforms the input document to term frequency vectors (Java version).
- Annotations
- @Since( "1.1.0" )
-
def
transform[D <: Iterable[_]](dataset: RDD[D]): RDD[Vector]
Transforms the input document to term frequency vectors.
Transforms the input document to term frequency vectors.
- Annotations
- @Since( "1.1.0" )
-
def
transform(document: Iterable[_]): Vector
Transforms the input document into a sparse term frequency vector (Java version).
Transforms the input document into a sparse term frequency vector (Java version).
- Annotations
- @Since( "1.1.0" )
-
def
transform(document: Iterable[_]): Vector
Transforms the input document into a sparse term frequency vector.
Transforms the input document into a sparse term frequency vector.
- Annotations
- @Since( "1.1.0" )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
Deprecated Value Members
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] ) @Deprecated
- Deprecated