UQTk: Uncertainty Quantification Toolkit
3.1.1
|
Command-line utility for linear regression. More...
#include <iostream>
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <math.h>
#include <assert.h>
#include "Array1D.h"
#include "Array2D.h"
#include "PCSet.h"
#include "lreg.h"
#include <getopt.h>
#include "tools.h"
#include "arraytools.h"
#include "arrayio.h"
Macros | |
#define | XFILE "xdata.dat" |
default x-file More... | |
#define | YFILE "ydata.dat" |
default y-file More... | |
#define | BTYPE "PC" |
default basis type More... | |
#define | METH "lsq" |
default method More... | |
#define | MSC "m" |
default flag to output mean (m), mean+std (ms) or mean+std+cov (msc) More... | |
#define | INTPAR 5 |
default int parameter More... | |
#define | STRPAR "LU" |
default string parameter More... | |
#define | MINDEXFILE "mindex.dat" |
default multiindex file More... | |
#define | ETADEFAULT 1.e-3 |
default tolerance for bcs More... | |
Functions | |
int | usage () |
Displays information about this program. More... | |
int | main (int argc, char *argv[]) |
Main program of linear regression given data. More... | |
Command-line utility for linear regression.
#define BTYPE "PC" |
default basis type
#define ETADEFAULT 1.e-3 |
default tolerance for bcs
#define INTPAR 5 |
default int parameter
#define METH "lsq" |
default method
#define MINDEXFILE "mindex.dat" |
default multiindex file
#define MSC "m" |
default flag to output mean (m), mean+std (ms) or mean+std+cov (msc)
#define STRPAR "LU" |
default string parameter
#define XFILE "xdata.dat" |
default x-file
#define YFILE "ydata.dat" |
default y-file
int main | ( | int | argc, |
char * | argv[] | ||
) |
Main program of linear regression given data.
Set the default values
Read the user input
Sanity checks
Print the input information on screen
Read data
Read validation check data, if any
Declare the 'parent' regression object
Go through options, RBF, PC, PC_MI, POL, POL_MI
Initialize regression
Set the regression model
Setup data
Set the regularization parameters
Go through methods, lsq, wbcs
Write out coefficients
Get the data variance
Evaluate at validation points
Print standard error measures for the lsq method
int usage | ( | ) |
Displays information about this program.