|
TPCCLIB
|
Functions for using Akaike's information criteria. More...
#include "tpcclibConfig.h"#include <stdio.h>#include <stdlib.h>#include <math.h>#include <time.h>#include <string.h>#include "tpcextensions.h"#include "tpcmodels.h"Go to the source code of this file.
Functions | |
| double | aicSS (double ss, const unsigned int n, const unsigned int k) |
| Calculate corrected AIC. | |
| unsigned int | parFreeNr (const unsigned int n, double *pLower, double *pUpper) |
| Calculate the number of free parameters. | |
Functions for using Akaike's information criteria.
Definition in file aic.c.
| double aicSS | ( | double | ss, |
| const unsigned int | n, | ||
| const unsigned int | k ) |
Calculate corrected AIC.
Calculate AICc in the special case of sum-of-squares optimization from the SS, number of fitted samples, and number of fitted parameters.
If variance is different between the data points, weighted SS must be given.
| ss | Sum-of-Squares of the fit (weighted, if necessary). |
| n | Sample size, i.e. number of fitted samples; do not include samples with zero weight. |
| k | Number of fitted model parameters; do not include fixed parameters; AICc calculation is valid only when (n-k)>1. |
Definition at line 29 of file aic.c.
| unsigned int parFreeNr | ( | const unsigned int | n, |
| double * | pLower, | ||
| double * | pUpper ) |
Calculate the number of free parameters.
Model parameters can be fixed by setting lower and upper limit to equal values. This function simply checks the limits for each parameter.
| n | Nr of parameters |
| pLower | Lower limits (array of length n) |
| pUpper | Upper limits (array of length n) |
Definition at line 60 of file aic.c.