com.rapidminer.generator
Class SinusFactory

java.lang.Object
  extended by com.rapidminer.generator.SinusFactory

public class SinusFactory
extends java.lang.Object

Factory class to produce new attributes based on the fourier synthesis of the label mapped on an attribute dimension.

Author:
Ingo Mierswa

Field Summary
static java.lang.String[] ADAPTION_TYPES
           
static int GAUSSIAN
           
static int UNIFORMLY
           
static int UNIFORMLY_WITHOUT_NU
           
 
Constructor Summary
SinusFactory(int maxPeaks)
          Creates a new sinus factory which creates maxPeaks new peaks.
 
Method Summary
 void generateSinusFunctions(ExampleSet exampleSet, java.util.List<AttributePeak> attributes, java.util.Random random)
          Generates a new sinus function attribute for all given attribute peaks.
 java.util.List<AttributePeak> getAttributePeaks(ExampleSet exampleSet, Attribute first, Attribute second)
          Calculates the fourier transformation from the first attribute on the second and delivers the maxPeaks highest peaks.
 void setAdaptionType(int type)
           
 void setAttributePerPeak(int attributesPerPeak)
          Must be bigger than 2!
 void setEpsilon(double epsilon)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ADAPTION_TYPES

public static final java.lang.String[] ADAPTION_TYPES

UNIFORMLY

public static final int UNIFORMLY
See Also:
Constant Field Values

UNIFORMLY_WITHOUT_NU

public static final int UNIFORMLY_WITHOUT_NU
See Also:
Constant Field Values

GAUSSIAN

public static final int GAUSSIAN
See Also:
Constant Field Values
Constructor Detail

SinusFactory

public SinusFactory(int maxPeaks)
Creates a new sinus factory which creates maxPeaks new peaks. Uses Blackman-Harris window function and no spectrum filter as default. The adaption type is gaussian with an epsilon of 0.1. The factory produces three attributes for each highest peak as default.

Method Detail

setAdaptionType

public void setAdaptionType(int type)

setEpsilon

public void setEpsilon(double epsilon)

setAttributePerPeak

public void setAttributePerPeak(int attributesPerPeak)
Must be bigger than 2!


getAttributePeaks

public java.util.List<AttributePeak> getAttributePeaks(ExampleSet exampleSet,
                                                       Attribute first,
                                                       Attribute second)
                                                throws OperatorException
Calculates the fourier transformation from the first attribute on the second and delivers the maxPeaks highest peaks. Returns a list with the highest attribute peaks.

Throws:
OperatorException

generateSinusFunctions

public void generateSinusFunctions(ExampleSet exampleSet,
                                   java.util.List<AttributePeak> attributes,
                                   java.util.Random random)
                            throws GenerationException
Generates a new sinus function attribute for all given attribute peaks. Since the frequency cannot be calculated exactly (leakage, aliasing), several new attribute may be added for each peak. These additional attributes are randomly chosen (uniformly in epsilon range, uniformly without nu, gaussian with epsilon as standard deviation)

Throws:
GenerationException


Copyright © 2001-2009 by Rapid-I