All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.twitter.scalding.examples.WordCountJob.scala Maven / Gradle / Ivy

package com.twitter.scalding.examples

import com.twitter.scalding._

class WordCountJob(args : Args) extends Job(args) {
  TextLine( args("input") ).read.
    flatMap('line -> 'word) { line : String => line.split("\\s+") }.
    groupBy('word) { _.size }.
    write( Tsv( args("output") ) )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy