whistleClassifier
Class WhistleFragment
java.lang.Object
whistleClassifier.WhistleFragment
- All Implemented Interfaces:
- WhistleContour
public class WhistleFragment
- extends java.lang.Object
- implements WhistleContour
|
Constructor Summary |
WhistleFragment(double[] times,
double[] freqs)
Constructor to create a fragment using all of the
data passed |
WhistleFragment(double[] times,
double[] freqs,
int start,
int fragLen)
Constructor to automatically extract the fragment from a longer
segment. |
WhistleFragment(WhistleContour whistleContour,
int start,
int fragLen)
Constructor to automatically extract a fragment from a longer
contour. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
timesSeconds
private double[] timesSeconds
freqsHz
private double[] freqsHz
FITORDER
private static int FITORDER
shapeFit
private double[] shapeFit
negInflections
private int negInflections
posInflections
private int posInflections
WhistleFragment
public WhistleFragment(double[] times,
double[] freqs)
- Constructor to create a fragment using all of the
data passed
- Parameters:
times - times (seconds)freqs - frequencies (Hz)
WhistleFragment
public WhistleFragment(double[] times,
double[] freqs,
int start,
int fragLen)
- Constructor to automatically extract the fragment from a longer
segment.
- Parameters:
times - segment times (seconds)freqs - segment frequencies (Hz)start - first bin in segment to takefragLen - length of fragment to create
WhistleFragment
public WhistleFragment(WhistleContour whistleContour,
int start,
int fragLen)
- Constructor to automatically extract a fragment from a longer
contour.
- Parameters:
whistleContour - contour to extract fragment fromstart - start position in contourfragLen - length of fragment
createFragment
private void createFragment(double[] times,
double[] freqs,
int start,
int fragLen)
setTimeZero
private void setTimeZero()
- Reference all the times in the fragment to zero
getFreqsHz
public double[] getFreqsHz()
- Specified by:
getFreqsHz in interface WhistleContour
getTimesInSeconds
public double[] getTimesInSeconds()
- Specified by:
getTimesInSeconds in interface WhistleContour