42 Pds::Matrix X(Pds::Ra::TextFormat,
"../test/hard-data-x.txt");
43 Pds::Vector Y(Pds::Ra::TextFormat,
"../test/hard-data-y.txt");
46 Pds::Octave::DAspect=
true;
47 Pds::Octave::XLabel=
"x_1";
48 Pds::Octave::YLabel=
"x_2";
49 Pds::Octave::Plot::PointsX2DY(X,Y,
"testando.m",
"example_logisticregression_w0_data.png");
53 W0.T().Print(
"W0=Pds::LogisticModel::GetW0MeanMethod(X);\n");
57 Pds::Octave::Plot::PointsX2DYW(X,Yp,W0,
"testando.m",
"example_logisticregression_w0_mean.png");
61 W0.T().Print(
"W0=Pds::LogisticModel::GetW0CornerMeanMethod(X);\n");
65 Pds::Octave::Plot::PointsX2DYW(X,Yp,W0,
"testando_corner.m",
"example_logisticregression_w0_meancorner.png");
69 W0.T().Print(
"W0=Pds::LogisticModel::GetW0MeanSquareMethod(X);\n");
73 Pds::Octave::Plot::PointsX2DYW(X,Yp,W0,
"testando.m",
"example_logisticregression_w0_meansquare.png");
Pds::Vector GetW0CornerMeanMethod(const Pds::Matrix &X, double Delta=0.001)
Obtiene de forma rapida un vector inicial para usar en regresion logistica.
Pds::Vector Classify(const Pds::Vector &W, const Pds::Matrix &X)
Calculo del resultado del clasificador.
Pds::Vector GetW0MeanMethod(const Pds::Matrix &X)
Obtiene de forma rapida un vector inicial para usar en regresion logistica.
Pds::Vector GetW0MeanSquareMethod(const Pds::Matrix &X)
Obtiene de forma rapida un vector inicial para usar en regresion logistica.