STK++ 0.9.13
tutoStatFactors.cpp File Reference
#include "STKpp.h"
Include dependency graph for tutoStatFactors.cpp:

Go to the source code of this file.

Functions

int main (int argc, char **argv)
 

Function Documentation

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 3 of file tutoStatFactors.cpp.

4{
6 fac <<'b','a','a', 'c','b','a', 'b','a','a', 'c','a','a', 'd','a','a'
7 ,'b','b','a', 'd','c','b', 'c','c','b', 'b','c','b', 'd','b','b'
8 ,'b','a','b', 'd','a','b', 'c','c','b';
9
11 f1d.run();
12 stk_cout << "nbLevels= " << f1d.nbLevels() << "\n";
13 stk_cout << "asInteger=\n"<< f1d.asInteger().transpose() << "\n";
14 stk_cout << "Levels: " << f1d.levels().transpose();
15 stk_cout << "Levels counts: " << f1d.counts().transpose();
16
18 f2d.run();
19 stk_cout << "nbLevels= " << f2d.nbLevels() << "\n";
20 stk_cout << "asInteger=\n"<< f2d.asInteger().transpose() << "\n";
21 for (int i=f2d.levels().begin(); i<f2d.levels().end(); ++i)
22 stk_cout <<"Levels "<< i <<": "<< f2d.levels()[i].transpose();
23 stk_cout << "\n";
24 for (int i=f2d.levels().begin(); i<f2d.levels().end(); ++i)
25 stk_cout <<"Counts "<< i << ": "<< f2d.counts()[i].transpose();
26 return 0;
27}
#define stk_cout
Standard stk output stream.
virtual bool run()
run the computations.
The MultidimRegression class allows to regress a multidimensional output variable among a multivariat...
Computation of the Factors of a 1D Container.
Computation of the MultiFactors of a 2D Container.

References STK::Stat::Factor< Array >::asInteger(), STK::Stat::MultiFactor< Array >::asInteger(), STK::ICArray< Derived >::col(), STK::Stat::Factor< Array >::counts(), STK::Stat::MultiFactor< Array >::counts(), STK::Stat::Factor< Array >::levels(), STK::Stat::MultiFactor< Array >::levels(), STK::Stat::Factor< Array >::nbLevels(), STK::Stat::MultiFactor< Array >::nbLevels(), STK::Stat::Factor< Array >::run(), STK::Stat::MultiFactor< Array >::run(), stk_cout, and STK::ArrayBase< Derived >::transpose().