ciranda.utils
Class CirandaUtils

java.lang.Object
  extended byciranda.utils.CirandaUtils

public class CirandaUtils
extends java.lang.Object

Author:
vitor Utilities for the ciranda package

Nested Class Summary
static class CirandaUtils.unigramFE
           
 
Constructor Summary
CirandaUtils()
           
 
Method Summary
static Instance addingInstances(Instance target, Instance source)
          Adds one instance to another.
static Instance extract1g2g3g4g5g(java.lang.String str, boolean uni, boolean bi, boolean tri, boolean four, boolean five)
           
static MutableInstance extractBigrams(java.lang.String str)
          Extracts all Bigrams from String TBD
static MutableInstance extractFivegrams(java.lang.String str)
          Extracts all Fivegrams from String
static MutableInstance extractFourgrams(java.lang.String str)
          Extracts all Fourgrams from String
static MutableInstance extractTrigrams(java.lang.String str)
          Extracts all Trigrams from String TBD
static MutableInstance extractUnigrams(java.lang.String str)
          Extracts all unigrams from String TBD
static java.lang.String getBody(java.lang.String str)
          returns only lines of msgs between tags.
static boolean hasBodyTag(java.lang.String str)
           
static void main(java.lang.String[] args)
           
static java.lang.String removeFWDparts(java.lang.String str)
           
static java.lang.String removeQuotes(java.lang.String str)
          Removes quotes from an email message TBD: needs to use the trained classifiers TBD
static MutableInstance renameFeatures(MutableInstance src, java.lang.String prefix)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CirandaUtils

public CirandaUtils()
Method Detail

addingInstances

public static Instance addingInstances(Instance target,
                                       Instance source)
Adds one instance to another. addingInstances(destination, source);


getBody

public static java.lang.String getBody(java.lang.String str)
returns only lines of msgs between tags. remove non-body parts.


hasBodyTag

public static boolean hasBodyTag(java.lang.String str)

removeQuotes

public static java.lang.String removeQuotes(java.lang.String str)
Removes quotes from an email message TBD: needs to use the trained classifiers TBD


extractUnigrams

public static MutableInstance extractUnigrams(java.lang.String str)
Extracts all unigrams from String TBD


extractBigrams

public static MutableInstance extractBigrams(java.lang.String str)
Extracts all Bigrams from String TBD


extractTrigrams

public static MutableInstance extractTrigrams(java.lang.String str)
Extracts all Trigrams from String TBD


extractFourgrams

public static MutableInstance extractFourgrams(java.lang.String str)
Extracts all Fourgrams from String


extractFivegrams

public static MutableInstance extractFivegrams(java.lang.String str)
Extracts all Fivegrams from String


renameFeatures

public static MutableInstance renameFeatures(MutableInstance src,
                                             java.lang.String prefix)

removeFWDparts

public static java.lang.String removeFWDparts(java.lang.String str)

extract1g2g3g4g5g

public static Instance extract1g2g3g4g5g(java.lang.String str,
                                         boolean uni,
                                         boolean bi,
                                         boolean tri,
                                         boolean four,
                                         boolean five)

main

public static void main(java.lang.String[] args)