title: CDH4 - Mahout seq2sparse with custom analyzer
body: <p>I'm newbie with Mahout and I try to code my own analyzer for seq2sparse. I use CDH4 with default versions: Mahout 0.7 and Lucene 3.6.</p>
  
  <p>This is my analyzer code:</p>
  
  <pre><code>package com.analyzer;
  
  import java.io.Reader;
  import org.apache.lucene.analysis.Analyzer;
  import org.apache.lucene.analysis.LengthFilter;
  import org.apache.lucene.analysis.LowerCaseFilter;
  import org.apache.lucene.analysis.PorterStemFilter;
  import org.apache.lucene.analysis.StopFilter;
  import org.apache.lucene.analysis.TokenStream;
  import org.apache.lucene.analysis.standard.StandardAnalyzer;
  import org.apache.lucene.analysis.standard.StandardTokenizer;
  import org.apache.lucene.util.Version;
  
  public class MyAnalyzer extends Analyzer {
  
      @Override
      public TokenStream tokenStream(String fieldName, Reader reader) {
          Version version = Version.LUCENE_36;
          TokenStream result = new StandardTokenizer(version, reader);
          result = new LowerCaseFilter(version, result);
          result = new LengthFilter(result, 3, 50);
          result = new StopFilter(version, result, StandardAnalyzer.STOP_WORDS_SET);
          result = new PorterStemFilter(result);
          return result;
      }
  }
  </code></pre>
  
  <p>I built it in a JAR file and move to $MAHOUT_HOME/lib folder. My JAR is correctly added to classpath when I check with the following command:</p>
  
  <pre><code>$MAHOUT_HOME/bin/mahout classpath
  </code></pre>
  
  <p>But when I call the seq2sparse tool from Mahout with:</p>
  
  <pre><code>$MAHOUT_HOME/bin/mahout seq2sparse -i input_folder -o output_folder --minDF 2 --maxDFPercent 70 --norm 1 -a com.analyzer.MyAnalyzer
  </code></pre>
  
  <p>I get this error:</p>
  
  <pre><code>Exception in thread "main" java.lang.ClassNotFoundException: com.analyzer.MyAnalyzer
  </code></pre>
  
  <p>If I call with an analyzer from Lucene like org.apache.lucene.analysis.WhitespaceAnalyzer, there's no error and job finished successfully.</p>
  
  <p>How to add and use my own analyzer correctly?</p>