as.clynx.audio.statistic
Class AbstractMeanCalc

java.lang.Object
  extended by as.clynx.audio.statistic.AbstractMeanCalc
Direct Known Subclasses:
ArithmeticMean, RootMeanSquare

public abstract class AbstractMeanCalc
extends java.lang.Object

The interface AbstractMeanCalc.java defines a mean calculation.

Version:
cLynx v.1.2, JDK 6.0: 12.10.2007
Author:
Andreas Senfter - andreas@senfters.com

Constructor Summary
AbstractMeanCalc()
          Constructor
AbstractMeanCalc(javax.sound.sampled.AudioFormat format)
          Constructor
 
Method Summary
abstract  void addValue(int value)
          adds a sample value
abstract  double getBotMean()
          calculates the mean of all passed samples which are greater than bound.
abstract  double getMean()
          calculates the mean of all passed samples.
abstract  double getTopMean()
          calculates the mean of all passed samples which are smaller than bound.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractMeanCalc

public AbstractMeanCalc()
Constructor


AbstractMeanCalc

public AbstractMeanCalc(javax.sound.sampled.AudioFormat format)
Constructor

Parameters:
format -
Method Detail

addValue

public abstract void addValue(int value)
adds a sample value

Parameters:
value -

getTopMean

public abstract double getTopMean()
calculates the mean of all passed samples which are smaller than bound.

Returns:
the mean of all passed samples which are smaller than bound.

getBotMean

public abstract double getBotMean()
calculates the mean of all passed samples which are greater than bound.

Returns:
the mean of all passed samples which are greater than bound.

getMean

public abstract double getMean()
calculates the mean of all passed samples.

Returns:
the mean of all passed samples.