[kepler-dev] Please let me know what are the components components i should to count number of words in a file.
Peter Reutemann
fracpete at gmail.com
Tue Jun 16 13:47:49 PDT 2009
> Please let me know what are the components components i should to count
> number of words in a file.
Here's what you need:
- a FileReader to read the file content into one string,
- a StringSplitter to split on whitespaces ("\s") and
- an ArrayLength actor to count the number of generated array elements
I've attached an example workflow that does this.
Cheers, Peter
--
Peter Reutemann, Dept. of Computer Science, University of Waikato, NZ
http://www.cs.waikato.ac.nz/~fracpete/ Ph. +64 (7) 858-5174
-------------- next part --------------
A non-text attachment was scrubbed...
Name: wordcount.xml
Type: text/xml
Size: 45063 bytes
Desc: not available
URL: <http://mercury.nceas.ucsb.edu/kepler/pipermail/kepler-dev/attachments/20090617/4798daa7/attachment-0001.xml>
More information about the Kepler-dev
mailing list