Correlation Library  1.0
CorrelationLib.cpp File Reference

Defines

#define ERR_NULL_OBJECT   -5

Functions

BOOL APIENTRY DllMain (HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved)
 Entry into the Dll space.
CORRELATIONLIB_API void * CreateScaledCorrelationComputerBB (int piScaleWindow, int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes scaled correlation on a pair of binary - binary signals.
CORRELATIONLIB_API void FreeScaledCorrelationComputerBB (void *pvObject)
 Destructor for scaled correlation objects on binary-binary pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeScaledCorrelationBB (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, int *piaTimeStampsB, int piNrTimeStampsInB, int pbUseFisherZTransform)
 Compute the scaled correlation of two vectors of time stamps.
CORRELATIONLIB_API void ComputeWindowedScaledCorrelationPerTrialBB (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, int *piaTimeStampsB, int piNrTimeStampsInB, int piFromOffsetInTrial, int piToOffsetInTrial, int pbUseFisherZTransform)
 Compute the scaled correlation of two vectors of time stamps, on a partial window of the trial; ONLY ACCEPTS ONE TRIAL!!!
CORRELATIONLIB_API float * GetScaledCrossCorrelogramBB (void *pvObject)
 Returns the buffer with the computed scaled-cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API float * GetFiCoefficientSumsBB (void *pvObject)
 Returns the sum of valid Fi coefficients of correlation for each bin of the correlogram.
CORRELATIONLIB_API int * GetFiCoefficientCountsBB (void *pvObject)
 Returns how many Fi coefficients of correlation have been averaged for each bin of the scaled cross correlogram.
CORRELATIONLIB_API int * GetDistributionOfCorrelationCoefficientsBB (void *pvObject, int &piNumberOfBins, float &pfBinSize)
 Returns the distribution of coefficients of correlation.
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowBB (void *pvObject, int piNewScale)
 Changes the scale window for the scaled correlation;.
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowBB (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthBB (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersBB (void *pvObject, int piNewScale, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int ScaledCorrelationGetScaleWindowBB (void *pvObject)
 Get the size of the current scale window.
CORRELATIONLIB_API int ScaledCorrelationGetCorrelationWindowBB (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int ScaledCorrelationGetTrialLengthBB (void *pvObject)
 Get the trial length in original sampling units.
CORRELATIONLIB_API int GetDistributionOfCorrelationCoefficientsBinNrBB (void *pvObject)
 Get the number of bins of the distribution of coefficients of correlation.
CORRELATIONLIB_API float GetDistributionOfCorrelationCoefficientsBinSizeBB (void *pvObject)
 Get the size of a bin of the distribution of coefficients of correlation.
CORRELATIONLIB_API void * CreateScaledCorrelationComputerCC (int piScaleWindow, int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes scaled correlation on a pair of continuous - continuous signals.
CORRELATIONLIB_API void FreeScaledCorrelationComputerCC (void *pvObject)
 Destructor for scaled correlation objects on continuous-continuous input pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeScaledCorrelationCC (void *pvObject, float *pfaSamplesA, int piNrSamplesInA, float *pfaSamplesB, int piNrSamplesInB, int pbUseFisherZTransform)
 Compute the scaled correlation of two digitized continuous signals.
CORRELATIONLIB_API void ComputeWindowedScaledCorrelationPerTrialCC (void *pvObject, float *pfaSamplesA, int piNrSamplesInA, float *pfaSamplesB, int piNrSamplesInB, int piFromOffsetInTrial, int piToOffsetInTrial, int pbUseFisherZTransform)
 Compute the scaled correlation of two digitized continuous signals, on a partial window of the trial; ONLY ACCEPTS ONE TRIAL!!!
CORRELATIONLIB_API float * GetScaledCrossCorrelogramCC (void *pvObject)
 Returns the buffer with the computed scaled correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API float * GetPearsonCoefficientSumsCC (void *pvObject)
 Returns the sum of valid Pearson coefficients of correlation for each bin of the correlogram.
CORRELATIONLIB_API int * GetPearsonCoefficientCountsCC (void *pvObject)
CORRELATIONLIB_API int * GetDistributionOfCorrelationCoefficientsCC (void *pvObject, int &piNumberOfBins, float &pfBinSize)
 Returns the distribution of coefficients of correlation.
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowCC (void *pvObject, int piNewScale)
 Changes the scale segment size for the scaled correlation.
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowCC (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthCC (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersCC (void *pvObject, int piNewScale, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int ScaledCorrelationGetScaleWindowCC (void *pvObject)
 Get the size of the current scale window.
CORRELATIONLIB_API int ScaledCorrelationGetCorrelationWindowCC (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int ScaledCorrelationGetTrialLengthCC (void *pvObject)
 Get the trial length in original sampling units.
CORRELATIONLIB_API int GetDistributionOfCorrelationCoefficientsBinNrCC (void *pvObject)
 Get the number of bins of the distribution of coefficients of correlation.
CORRELATIONLIB_API float GetDistributionOfCorrelationCoefficientsBinSizeCC (void *pvObject)
 Get the size of a bin of the distribution of coefficients of correlation.
CORRELATIONLIB_API void * CreateScaledCorrelationComputerBC (int piScaleWindow, int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes scaled correlation on a pair of binary - continuous signals.
CORRELATIONLIB_API void FreeScaledCorrelationComputerBC (void *pvObject)
 Destructor for scaled correlation objects on binary-continuous input pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeScaledCorrelationBC (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, float *pfaSamplesB, int piNrSamplesInB, int pbUseFisherZTransform)
 Compute the scaled correlation of one binary signal with one continuos signal.
CORRELATIONLIB_API float * GetScaledCrossCorrelogramBC (void *pvObject)
 Returns the buffer with the computed scaled correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API float * GetPBsCoefficientSumsBC (void *pvObject)
 Returns the sum of valid Point Biserial coefficients of correlation for each bin of the correlogram.
CORRELATIONLIB_API int * GetPBsCoefficientCountsBC (void *pvObject)
 Returns how many Point Biserial coefficients of correlation have been averaged for each bin of the scaled cross correlogram.
CORRELATIONLIB_API int * GetDistributionOfCorrelationCoefficientsBC (void *pvObject, int &piNumberOfBins, float &pfBinSize)
 Returns the distribution of coefficients of correlation.
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowBC (void *pvObject, int piNewScale)
 Changes the scale window for the scaled correlation.
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowBC (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter;.
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthBC (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersBC (void *pvObject, int piNewScale, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int ScaledCorrelationGetScaleWindowBC (void *pvObject)
 Get the size of the current scale window.
CORRELATIONLIB_API int ScaledCorrelationGetCorrelationWindowBC (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int ScaledCorrelationGetTrialLengthBC (void *pvObject)
 Get the trial length in original sampling units.
CORRELATIONLIB_API int GetDistributionOfCorrelationCoefficientsBinNrBC (void *pvObject)
 Get the number of bins of the distribution of coefficients of correlation.
CORRELATIONLIB_API float GetDistributionOfCorrelationCoefficientsBinSizeBC (void *pvObject)
 Get the size of a bin of the distribution of coefficients of correlation.
CORRELATIONLIB_API void * CreateCrossCorrelationComputerBB (int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes cross-correlation on a pair of binary - binary signals.
CORRELATIONLIB_API void FreeCrossCorrelationComputerBB (void *pvObject)
 Destructor for cross-correlation objects on binary-binary input pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeCrossCorrelationBB (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, int *piaTimeStampsB, int piNrTimeStampsInB, int pbNormalizeCorrelogram)
 Compute the cross-correlation of two vectors of time stamps.
CORRELATIONLIB_API void ComputeWindowedCrossCorrelationPerTrialBB (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, int *piaTimeStampsB, int piNrTimeStampsInB, int piFromOffsetInTrial, int piToOffsetInTrial, int pbNormalizeCorrelogram)
 Compute the cross-correlation of two vectors of time stamps, on a partial window of the trial. ONLY ACCEPTS ONE TRIAL!!!
CORRELATIONLIB_API float * GetCrossCorrelogramBB (void *pvObject)
 Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowBB (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthBB (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersBB (void *pvObject, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int CrossCorrelationGetCorrelationWindowBB (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int CrossCorrelationGetTrialLengthBB (void *pvObject)
 Get the trial length in original sampling units.
CORRELATIONLIB_API void * CreateCrossCorrelationComputerCC (int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes cross-correlation on a pair of continuous - continuous signals.
CORRELATIONLIB_API void FreeCrossCorrelationComputerCC (void *pvObject)
 Destructor for cross-correlation objects on continuous-continuous input pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeCrossCorrelationCC (void *pvObject, float *pfaSamplesA, int piNrSamplesInA, float *pfaSamplesB, int piNrSamplesInB, int piNormalizationFlag)
 Compute the cross-correlation of two vectors of samples.
CORRELATIONLIB_API void ComputeWindowedCrossCorrelationPerTrialCC (void *pvObject, float *pfaSamplesA, int piNrSamplesInA, float *pfaSamplesB, int piNrSamplesInB, int piFromOffsetInTrial, int piToOffsetInTrial, int piNormalizationFlag)
 Compute the cross-correlation of two digitized continuous signals, on a partial window of the trial.
CORRELATIONLIB_API float * GetCrossCorrelogramCC (void *pvObject)
 Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowCC (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthCC (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersCC (void *pvObject, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int CrossCorrelationGetCorrelationWindowCC (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int CrossCorrelationGetTrialLengthCC (void *pvObject)
 Get the trial length in original sampling units.
CORRELATIONLIB_API void * CreateCrossCorrelationComputerBC (int piCorrelationWindow, int piTrialLength, int &piIsError)
 Creates an object that computes cross-correlation on a pair of binary - continuous signals.
CORRELATIONLIB_API void FreeCrossCorrelationComputerBC (void *pvObject)
 Destructor for cross-correlation objects on binary-continuous input pairs; always call this to cleanup your data space.
CORRELATIONLIB_API void ComputeCrossCorrelationBC (void *pvObject, int *piaTimeStampsA, int piNrTimeStampsInA, float *pfaSamplesB, int piNrSamplesInB, int pbNormalizeCorrelogram)
 Compute the cross-correlation of one binary signal with one continuos signal.
CORRELATIONLIB_API float * GetCrossCorrelogramBC (void *pvObject)
 Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowBC (void *pvObject, int piNewCorrelationWindow)
 Set the size of the correlation window; for example for a window of -100..+100 pass 100 as a parameter.
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthBC (void *pvObject, int piNewTrialLength)
 Set the length of the trial in original sampling units.
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersBC (void *pvObject, int piNewCorrelationWindow, int piNewTrialLength)
 Sets all parameters at once.
CORRELATIONLIB_API int CrossCorrelationGetCorrelationWindowBC (void *pvObject)
 Get the size of the correlation window.
CORRELATIONLIB_API int CrossCorrelationGetTrialLengthBC (void *pvObject)
 Get the trial length in original sampling units.

Define Documentation

#define ERR_NULL_OBJECT   -5

Function Documentation

CORRELATIONLIB_API void ComputeCrossCorrelationBB ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
int *  piaTimeStampsB,
int  piNrTimeStampsInB,
int  pbNormalizeCorrelogram 
)

Compute the cross-correlation of two vectors of time stamps.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
piaTimeStampsA- The vector holding the time stamps of the first binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
piaTimeStampsB- The vector holding the time stamps of the second binary variable
piNrTimeStampsInB- Number of time stamps in the second vector
pbNormalizeCorrelogram- Set to 1 to normalize the correlogram; normalization is made by dividing the correlogram to the number of time stamps in the first buffer (rate-normalized correlogram)
CORRELATIONLIB_API void ComputeCrossCorrelationBC ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  pbNormalizeCorrelogram 
)

Compute the cross-correlation of one binary signal with one continuos signal.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
piaTimeStampsA- The vector holding the time stamps of the binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
pfaSamplesB- The vector holding samples of the continuous signal
piNrSamplesInB- Number of samples in the second vector
pbNormalizeCorrelogram- Set to 1 to normalize the correlogram; ; normalization is made by dividing to the number of time stamps used to compute the correlogram
Warning:
The sampling frequency of the continuous and binary signals has to be the same! Also the trial lengths have to match!
The time stamps of the binary signal must match the samples of the continuous signal, i.e. the first sample of the continuous signal corresponds to time stamp 0.
CORRELATIONLIB_API void ComputeCrossCorrelationCC ( void *  pvObject,
float *  pfaSamplesA,
int  piNrSamplesInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  piNormalizationFlag 
)

Compute the cross-correlation of two vectors of samples.

If the number of samples passed is larger than the size of one trial, then the signals are divided into trials and the results are eventually averaged over trials

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
pfaSamplesA- The vector holding the samples of the first signal
piNrSamplesInA- Number of samples in the first vector
pfaSamplesB- The vector holding the samples of the second signal
piNrSamplesInB- Number of samples in the second vector
piNormalizationFlag- Flag that decides how to normalize the correlogram: 0 - unnormalized, biased; 1 - normalized, biased; 2 - unnormalized, unbiased; 3 - normalized, unbiased; normalization removes the dependency on the length of the signals and gives values in cross-product units of the continuous variables; unbias removes the dependency on the finite length of signal windows
CORRELATIONLIB_API void ComputeScaledCorrelationBB ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
int *  piaTimeStampsB,
int  piNrTimeStampsInB,
int  pbUseFisherZTransform 
)

Compute the scaled correlation of two vectors of time stamps.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piaTimeStampsA- The vector holding the time stamps of the first binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
piaTimeStampsB- The vector holding the time stamps of the second binary variable
piNrTimeStampsInB- Number of time stamps in the second vector
pbUseFisherZTransform- Set to 1 to use the Fisher Z transform to average the coefficients of correlation; set to 0 for normal computation;
CORRELATIONLIB_API void ComputeScaledCorrelationBC ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  pbUseFisherZTransform 
)

Compute the scaled correlation of one binary signal with one continuos signal.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piaTimeStampsA- The vector holding the time stamps of the binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
pfaSamplesB- The vector holding samples of the continuous signal
piNrSamplesInB- Number of samples in the second vector
pbUseFisherZTransform- Set to 1 to use the Fisher Z transform to average the coefficients of correlation; set to 0 for normal computation;
Warning:
The sampling frequency of the continuous and binary signals has to be the same! Also the trial lengths have to match!
The time stamps of the binary signal must match the samples of the continuous signal, i.e. the first sample of the continuous signal corresponds to time stamp 0.
CORRELATIONLIB_API void ComputeScaledCorrelationCC ( void *  pvObject,
float *  pfaSamplesA,
int  piNrSamplesInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  pbUseFisherZTransform 
)

Compute the scaled correlation of two digitized continuous signals.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
pfaSamplesA- The vector holding the first signal's input samples
piNrSamplesInA- Number of samples in the first vector
pfaSamplesB- The vector holding the second signal's input samples
piNrSamplesInB- Number of samples in the second vector
pbUseFisherZTransform- Set to 1 to use the Fisher Z transform to average the coefficients of correlation; set to 0 for normal computation;
CORRELATIONLIB_API void ComputeWindowedCrossCorrelationPerTrialBB ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
int *  piaTimeStampsB,
int  piNrTimeStampsInB,
int  piFromOffsetInTrial,
int  piToOffsetInTrial,
int  pbNormalizeCorrelogram 
)

Compute the cross-correlation of two vectors of time stamps, on a partial window of the trial. ONLY ACCEPTS ONE TRIAL!!!

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
piaTimeStampsA- The vector holding the time stamps of the first binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
piaTimeStampsB- The vector holding the time stamps of the second binary variable
piNrTimeStampsInB- Number of time stamps in the second vector
piFromOffsetInTrial- The start offset in the trial where the desired window starts (time stamp)
piToOffsetInTrial- The end offset in the trial where the desired window stops (time stamp)
pbNormalizeCorrelogram- Set to 1 to normalize the correlogram
CORRELATIONLIB_API void ComputeWindowedCrossCorrelationPerTrialCC ( void *  pvObject,
float *  pfaSamplesA,
int  piNrSamplesInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  piFromOffsetInTrial,
int  piToOffsetInTrial,
int  piNormalizationFlag 
)

Compute the cross-correlation of two digitized continuous signals, on a partial window of the trial.

Warning:
ONLY ACCEPTS ONE TRIAL so do not pass signals longer than the size of a single trial! Subsequent trials will be discarded.
Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
pfaSamplesA- The vector holding the samples of the first signal
piNrSamplesInA- Number of samples in the first vector
pfaSamplesB- The vector holding the samples of the second signal
piNrSamplesInB- Number of samples in the second vector
piFromOffsetInTrial- The start offset in the trial where the desired window starts
piToOffsetInTrial- The end offset in the trial where the desired window stops
piNormalizationFlag- Flag that decides how to normalize the correlogram: 0 - unnormalized, biased; 1 - normalized, biased; 2 - unnormalized, unbiased; 3 - normalized, unbiased; normalization removes the dependency on the length of the signals and gives values in cross-product units of the continuous variables; unbias removes the dependency on the finite length of signal windows
CORRELATIONLIB_API void ComputeWindowedScaledCorrelationPerTrialBB ( void *  pvObject,
int *  piaTimeStampsA,
int  piNrTimeStampsInA,
int *  piaTimeStampsB,
int  piNrTimeStampsInB,
int  piFromOffsetInTrial,
int  piToOffsetInTrial,
int  pbUseFisherZTransform 
)

Compute the scaled correlation of two vectors of time stamps, on a partial window of the trial; ONLY ACCEPTS ONE TRIAL!!!

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piaTimeStampsA- The vector holding the time stamps of the first binary variable
piNrTimeStampsInA- Number of time stamps in the first vector
piaTimeStampsB- The vector holding the time stamps of the second binary variable
piNrTimeStampsInB- Number of time stamps in the second vector
piFromOffsetInTrial- The start offset in the trial where the desired window starts (time stamp)
piToOffsetInTrial- The end offset in the trial where the desired window stops (time stamp)
pbUseFisherZTransform- Set to 1 to use the Fisher Z transform to average the coefficients of correlation; set to 0 for normal computation
CORRELATIONLIB_API void ComputeWindowedScaledCorrelationPerTrialCC ( void *  pvObject,
float *  pfaSamplesA,
int  piNrSamplesInA,
float *  pfaSamplesB,
int  piNrSamplesInB,
int  piFromOffsetInTrial,
int  piToOffsetInTrial,
int  pbUseFisherZTransform 
)

Compute the scaled correlation of two digitized continuous signals, on a partial window of the trial; ONLY ACCEPTS ONE TRIAL!!!

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
pfaSamplesA- The vector holding the first signal's input samples
piNrSamplesInA- Number of samples in the first vector
pfaSamplesB- The vector holding the second signal's input samples
piNrSamplesInB- Number of samples in the second vector
piFromOffsetInTrial- The start offset in the trial where the desired window starts
piToOffsetInTrial- The end offset in the trial where the desired window stops
pbUseFisherZTransform- Set to 1 to use the Fisher Z transform to average the coefficients of correlation; set to 0 for normal computation;
CORRELATIONLIB_API void* CreateCrossCorrelationComputerBB ( int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes cross-correlation on a pair of binary - binary signals.

Parameters:
piCorrelationWindow- The size of the cross-correlation window (eg. 80 for a cross-correlation with laggs from -80 to +80); use the same units as the sampling of your samples
piTrialLength- The size of the trial in units of your samples
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetCrossCorrelogramBB() function will return NULL
Returns:
An untyped pointer to the created object!
CORRELATIONLIB_API void* CreateCrossCorrelationComputerBC ( int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes cross-correlation on a pair of binary - continuous signals.

Parameters:
piCorrelationWindow- The size of the cross-correlation window (eg. 80 for a cross-correlation with lags of -80..+80); use the same units as the sampling units
piTrialLength- The size of the trial in original sampling units
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetCrossCorrelogram() function will return NULL
Warning:
The sampling frequency of the continuous and binary signals has to be the same! Also the trial lengths have to match!
Returns:
An untyped pointer to the created object.
CORRELATIONLIB_API void* CreateCrossCorrelationComputerCC ( int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes cross-correlation on a pair of continuous - continuous signals.

Parameters:
piCorrelationWindow- The size of the cross-correlation window (eg. 80 for a cross-correlation with laggs from -80 to +80); use the same units as the sampling of your samples
piTrialLength- The size of the trial in units of your samples
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetCrossCorrelogram() function will return NULL
Returns:
An untyped pointer to the created object.
CORRELATIONLIB_API void* CreateScaledCorrelationComputerBB ( int  piScaleWindow,
int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes scaled correlation on a pair of binary - binary signals.

Parameters:
piScaleWindow- The scale on which you compute the scaled correlation; use the same units as the sampling unit of your time stamps
piCorrelationWindow- The size of the cross correlation window (eg. 80 for a cross correlation with lags of -80..+80); use the same units as the sampling of your time stamps
piTrialLength- The size of the trial in units of your time stamps
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetScaledCorrelogram() function will return NULL
Returns:
An untyped pointer to the created object
CORRELATIONLIB_API void* CreateScaledCorrelationComputerBC ( int  piScaleWindow,
int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes scaled correlation on a pair of binary - continuous signals.

Parameters:
piScaleWindow- The scale on which you compute the scaled correlation; use the same units as the sampling unit of your time stamps
piCorrelationWindow- The size of the cross-correlation window (eg. 80 for a cross-correlation with lags of -80..+80); use again the same units as the sampling of your time stamps
piTrialLength- The size of the trial in original sampling units
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetScaledCorrelogram() function will return NULL
Warning:
The sampling frequency of the continuous and binary signals has to be the same! Also the trial lengths have to match!
Returns:
An untyped pointer to the created object!
CORRELATIONLIB_API void* CreateScaledCorrelationComputerCC ( int  piScaleWindow,
int  piCorrelationWindow,
int  piTrialLength,
int &  piIsError 
)

Creates an object that computes scaled correlation on a pair of continuous - continuous signals.

Parameters:
piScaleWindow- The scale on which you compute the scaled correlation; use the same units as the sampling unit of your signals
piCorrelationWindow- The size of the cross correlation window (eg. 80 for a cross correlation with lags of -80..+80); use again the same units as the sampling of your signals
piTrialLength- The size of the trial in sampling units of your signals
piIsError- A return parameter, set to 0 on success. It is set to -1 by the constructor if there is a mismatch of window sizes and the GetScaledCorrelogram() function will return NULL
Returns:
An untyped pointer to the created object

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
Returns:
The size of the correlation window

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
Returns:
The size of the correlation window

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
Returns:
The size of the correlation window

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
Returns:
The length of the trial in sampling units

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
Returns:
The length of the trial in sampling units

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
Returns:
The trial length in sampling units
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersBB ( void *  pvObject,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
piNewCorrelationWindow- The new correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new correlation window is too small; -2 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersBC ( void *  pvObject,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
piNewCorrelationWindow- The new correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new correlation window is too small; -2 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int CrossCorrelationModifyAllParametersCC ( void *  pvObject,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
piNewCorrelationWindow- The new correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new correlation window is too small; -2 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowBB ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
piNewCorrelationWindow- The new correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowBC ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; for example for a window of -100..+100 pass 100 as a parameter.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
piNewCorrelationWindow- Specifies the new correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial;
CORRELATIONLIB_API int CrossCorrelationModifyCorrelationWindowCC ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
piNewCorrelationWindow- Specifies the new correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial;
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthBB ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthBC ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int CrossCorrelationModifyTrialLengthCC ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the correlation window
BOOL APIENTRY DllMain ( HANDLE  hModule,
DWORD  ul_reason_for_call,
LPVOID  lpReserved 
)

Entry into the Dll space.

Destructor for cross-correlation objects on binary-binary input pairs; always call this to cleanup your data space.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBB function

Destructor for cross-correlation objects on binary-continuous input pairs; always call this to cleanup your data space.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function

Destructor for cross-correlation objects on continuous-continuous input pairs; always call this to cleanup your data space.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function

Destructor for scaled correlation objects on binary-binary pairs; always call this to cleanup your data space.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function

Destructor for scaled correlation objects on binary-continuous input pairs; always call this to cleanup your data space.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function

Destructor for scaled correlation objects on continuous-continuous input pairs; always call this to cleanup your data space.

Parameters:
pvObject- pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
CORRELATIONLIB_API float* GetCrossCorrelogramBB ( void *  pvObject)

Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the cross correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow.

Parameters:
pvObject- Pointer to the object that computes the cross correlation; please instantiate first using the CreateCrossCorrelationComputerBB function
Returns:
Returns a pointer to the internal cross-correlation buffer. Do not write into the buffer!
The buffer is filled with NAN (Not A Number) = -100000000.0 if one of the input buffers was empty and thus the correlation was not defined; please check in your code for this!!!!
CORRELATIONLIB_API float* GetCrossCorrelogramBC ( void *  pvObject)

Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the cross correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow.

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerBC function
Returns:
Returns a pointer to the internal cross-correlation buffer. Do not write into the buffer!
The buffer is filled with NAN (Not A Number) = -100000000.0 if one of the input buffers was empty and thus the correlation was not defined; please check in your code for this!!!!
CORRELATIONLIB_API float* GetCrossCorrelogramCC ( void *  pvObject)

Returns the buffer with the computed cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the cross-correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow;

Parameters:
pvObject- Pointer to the object that computes the cross-correlation; please instantiate first using the CreateCrossCorrelationComputerCC function
Returns:
Returns a pointer to the internal cross-correlation buffer. Do not write into the buffer!
The buffer is filled with NAN (Not A Number) = -100000000.0 if one of the input buffers was empty and thus the correlation was not defined; please check in your code for this!!!!
CORRELATIONLIB_API int* GetDistributionOfCorrelationCoefficientsBB ( void *  pvObject,
int &  piNumberOfBins,
float &  pfBinSize 
)

Returns the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piNumberOfBins- The number of bins in the distribution (output parameter)
pfBinSize- The size of one bin of the distribution (output parameter)
Returns:
- A pointer to the internal buffer that holds the distribution of correlation coefficients
- The number of bins in the distribution (piNumberOfBins); this is equal to the size of the buffer
- The size of one bin of the distribution (pfBinSize); the size of the bin is in sampling units of the original signals
CORRELATIONLIB_API int* GetDistributionOfCorrelationCoefficientsBC ( void *  pvObject,
int &  piNumberOfBins,
float &  pfBinSize 
)

Returns the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piNumberOfBins- The number of bins in the distribution (output parameter)
pfBinSize- The size of one bin of the distribution (output parameter)
Returns:
A pointer to the internal buffer that holds the distribution of correlation coefficients
The number of bins in the distribution (piNumberOfBins); this is equal to the size of the buffer
The size of one bin of the distribution (pfBinSize); the size of the bin is in sampling units of the original signals

Get the number of bins of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns the number of bins used to compute the distribution of correlation coefficients; the value equals the size of the internal buffer that stores the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficientsBB)

Get the number of bins of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns the number of bins used to compute the distribution of correlation coefficients; the value equals the size of the internal buffer that stores the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficients)

Get the number of bins of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns the number of bins used to compute the distribution of correlation coefficients; the value equals the size of the internal buffer that stores the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficientsCC)

Get the size of a bin of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns the size of the bins used to compute the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficientsBB)

Get the size of a bin of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns the size of the bins used to compute the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficients)

Get the size of a bin of the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns the size of the bins used to compute the distribution of correlation coefficients (see also function: GetDistributionOfCorrelationCoefficientsCC)
CORRELATIONLIB_API int* GetDistributionOfCorrelationCoefficientsCC ( void *  pvObject,
int &  piNumberOfBins,
float &  pfBinSize 
)

Returns the distribution of coefficients of correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
piNumberOfBins- The number of bins in the distribution (output parameter)
pfBinSize- The size of one bin of the distribution (output parameter)
Returns:
A pointer to the internal buffer that holds the distribution of correlation coefficients
The number of bins in the distribution (piNumberOfBins); this is equal to the size of the buffer
The size of one bin of the distribution (pfBinSize); the size of the bin is in sampling units of the original signals
CORRELATIONLIB_API int* GetFiCoefficientCountsBB ( void *  pvObject)

Returns how many Fi coefficients of correlation have been averaged for each bin of the scaled cross correlogram.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
A pointer to the internal buffer containing the counts of "Fi" correlation coefficients averaged for each bin. The size of the buffer is (2*iCorrelationWindow+1), and the count of valid Fi coefficients, that were averaged to compute the scaled cross correlogram at lag 0, is at position iCorrelationWindow
CORRELATIONLIB_API float* GetFiCoefficientSumsBB ( void *  pvObject)

Returns the sum of valid Fi coefficients of correlation for each bin of the correlogram.

The size of the buffer is (2*iCorrelationWindow+1), and the sum of coefficients for lag 0 is at position iCorrelationWindow. Use this function to get the sum of all valid coefficients that were used to compute the average correlation coefficient for each bin of the ScaledCrossCorrelogram: ScaledCrossCorrelogram[i] = FiCoefficientSums[i] / FiCoefficientCounts[i].

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
A pointer to a buffer holding the sum of correlation coefficients for each bin (without dividing them to the counts; the scaled correlogram = the sum of coefficients / the count of coefficients).
Warning:
If no valid coefficient was found for a given bin, the buffer containes a value of NAN at that position. Please check for this in the code!
CORRELATIONLIB_API int* GetPBsCoefficientCountsBC ( void *  pvObject)

Returns how many Point Biserial coefficients of correlation have been averaged for each bin of the scaled cross correlogram.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
A pointer to the internal buffer containing the counts of Point Biserial correlation coefficients averaged for each bin. The size of the buffer is (2*iCorrelationWindow+1), and the count of valid Point Biserial coefficients, that were averaged to compute the scaled correlogram at lag 0, is at position iCorrelationWindow
CORRELATIONLIB_API float* GetPBsCoefficientSumsBC ( void *  pvObject)

Returns the sum of valid Point Biserial coefficients of correlation for each bin of the correlogram.

The size of the buffer is (2*iCorrelationWindow+1), and the sum of coefficients for lag 0 is at position iCorrelationWindow. Use this function to get the sum of all valid coefficients that were used to compute the average correlation coefficient for each bin of the ScaledCrossCorrelogram: ScaledCrossCorrelogram[i] = PBsCoefficientSums[i] / PBsCoefficientCounts[i].

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
A pointer to a buffer holding the sum of correlation coefficients for each bin (without dividing them to the counts; the scaled correlogram = the sum of coefficients / the count of coefficients).
Warning:
If no valid coefficient was found for a given bin, the buffer containes a value of NAN at that position. Please check for this in the code!
Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
A pointer to the internal buffer containing the counts of correlation coefficients averaged for each bin. The size of the buffer is (2*iCorrelationWindow+1), and the count of coefficients that were averaged for lag 0 is at position iCorrelationWindow.
CORRELATIONLIB_API float* GetPearsonCoefficientSumsCC ( void *  pvObject)

Returns the sum of valid Pearson coefficients of correlation for each bin of the correlogram.

The size of the buffer is (2*iCorrelationWindow+1), and the sum of coefficients for lag 0 is at position iCorrelationWindow. Use this function to get the sum of all valid coefficients that were used to compute the average correlation coefficient for each bin of the ScaledCrossCorrelogram: ScaledCrossCorrelogram[i] = PearsonCoefficientSums[i] / PearsonCoefficientCounts[i].

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
A pointer to a buffer holding the sum of correlation coefficients for each bin (without dividing them to the counts; the scaled correlogram = the sum of coefficients / the count of coefficients).
Warning:
If no valid coefficient was found for a given bin, the buffer containes a value of NAN at that position. Please check for this in the code!
CORRELATIONLIB_API float* GetScaledCrossCorrelogramBB ( void *  pvObject)

Returns the buffer with the computed scaled-cross-correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the scaled correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow;

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns a pointer to the internal scaled correlation buffer. Do not write into the buffer!
The buffer has a NotANumber (NAN = -100000000.0) value for bins where correlation could not be defined because of lack of variance in the input vectors
CORRELATIONLIB_API float* GetScaledCrossCorrelogramBC ( void *  pvObject)

Returns the buffer with the computed scaled correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the scaled correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow;

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns a pointer to the internal scaled correlation buffer. Do not write into the buffer!
The buffer has a NotANumber (NAN = -100000000.0) value for bins where correlation could not be defined because of lack of variance in the original signals.
CORRELATIONLIB_API float* GetScaledCrossCorrelogramCC ( void *  pvObject)

Returns the buffer with the computed scaled correlogram; returns NULL if there was an error; please check the buffer for NULL before using it!!

The size of the scaled correlogram buffer is (2*iCorrelationWindow+1), and element with lag 0 is at position iCorrelationWindow;

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns a pointer to the internal scaled correlation buffer. Do not write into the buffer!
The buffer has a NotANumber (NAN = -100000000.0) value for bins where correlation could not be defined because of lack of variance in the input signals

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns the size of the correlation window

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns the size of the correlation window

Get the size of the correlation window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns the size of the correlation window

Get the size of the current scale window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns the size of the scale segment window

Get the size of the current scale window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns the size of the scale segment window

Get the size of the current scale window.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns the size of the scale segment window

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
Returns:
Returns the length of the trial in original sampling units

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
Returns:
Returns the length of the trial in original sampling units

Get the trial length in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
Returns:
Returns the length of the trial in original sampling units
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersBB ( void *  pvObject,
int  piNewScale,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piNewScale- The new size of the scale segment
piNewCorrelationWindow- The new size of the correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new scale window is too small; -2 if the new correlation window is too small; -3 if the new scale window is larger than the trial size; -4 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersBC ( void *  pvObject,
int  piNewScale,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piNewScale- The new size of the scale segment
piNewCorrelationWindow- The new size of the correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new scale window is too small; -2 if the new correlation window is too small; -3 if the new scale window is larger than the trial size; -4 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int ScaledCorrelationModifyAllParametersCC ( void *  pvObject,
int  piNewScale,
int  piNewCorrelationWindow,
int  piNewTrialLength 
)

Sets all parameters at once.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
piNewScale- The new size of the scale segment
piNewCorrelationWindow- The new size of the correlation window
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success, -1 if the new scale window is too small; -2 if the new correlation window is too small; -3 if the new scale window is larger than the trial size; -4 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowBB ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piNewCorrelationWindow- The new size of the correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowBC ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter;.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piNewCorrelationWindow- The new size of the correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial
CORRELATIONLIB_API int ScaledCorrelationModifyCorrelationWindowCC ( void *  pvObject,
int  piNewCorrelationWindow 
)

Set the size of the correlation window; the parameter specifies the correlation window; for example for a window of -100..+100 pass 100 as a parameter.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
piNewCorrelationWindow- The new size of the correlation window
Returns:
Returns 0 on success, -1 if the window is too small; -2 if the window is larger than the length of the trial
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowBB ( void *  pvObject,
int  piNewScale 
)

Changes the scale window for the scaled correlation;.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piNewScale- The new size of the scale segment
Returns:
Returns 0 on success, -1 if the scale window is too small; -2 if the new scale window is larger than the trial size
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowBC ( void *  pvObject,
int  piNewScale 
)

Changes the scale window for the scaled correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piNewScale- The new size of the scale segment
Returns:
Returns 0 on success, -1 if the scale window is too small; -2 if the new scale window is larger than the trial size
CORRELATIONLIB_API int ScaledCorrelationModifyScaleWindowCC ( void *  pvObject,
int  piNewScale 
)

Changes the scale segment size for the scaled correlation.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
piNewScale- The new size of the scale segment
Returns:
Returns 0 on success, -1 if the scale window is too small; -2 if the new scale window is larger than the trial size
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthBB ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBB function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the scale window; -2 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthBC ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerBC function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the scale window; -2 if the trial length is smaller than the correlation window
CORRELATIONLIB_API int ScaledCorrelationModifyTrialLengthCC ( void *  pvObject,
int  piNewTrialLength 
)

Set the length of the trial in original sampling units.

Parameters:
pvObject- Pointer to the object that computes the scaled correlation; please instantiate first using the CreateScaledCorrelationComputerCC function
piNewTrialLength- The new length of the trial
Returns:
Returns 0 on success and -1 if the trial length is smaller than the scale window; -2 if the trial length is smaller than the correlation window