|
ppforest2 v0.1.0
Projection Pursuit Decision Trees and Random Forests
|
Abstract strategy for projection pursuit optimization. More...
#include <PPStrategy.hpp>
Public Member Functions | |
| virtual types::Feature | index (types::FeatureMatrix const &x, stats::GroupPartition const &group_spec, Projector const &projector) const =0 |
| Evaluate the projection pursuit index for a given projector. | |
| Projector | operator() (types::FeatureMatrix const &x, stats::GroupPartition const &group_spec) const |
| Convenience operator: optimize and return the projector only. | |
| virtual PPResult | optimize (types::FeatureMatrix const &x, stats::GroupPartition const &group_spec) const =0 |
| Find the optimal projection for the data. | |
Public Member Functions inherited from Strategy< PPStrategy > | |
| virtual | ~Strategy ()=default |
| virtual std::string | display_name () const=0 |
| Human-readable name for display in summaries. | |
| virtual void | to_json (nlohmann::json &j) const=0 |
| Serialize this strategy's configuration to JSON. | |
Additional Inherited Members | |
Public Types inherited from Strategy< PPStrategy > | |
| using | Factory |
| Factory function type for deserializing a strategy from JSON. | |
| using | Ptr |
Static Public Member Functions inherited from Strategy< PPStrategy > | |
| static Ptr | from_json (nlohmann::json const &j) |
| Construct a strategy from its JSON representation. | |
| static bool | register_strategy (std::string const &name, Factory factory) |
| Register a concrete strategy for JSON deserialization. | |
Abstract strategy for projection pursuit optimization.
Defines how to evaluate a projection (via an index function) and how to find the optimal projection for a given dataset and group partition.
Implementations must also provide to_json() for serialization.
|
pure virtual |
Evaluate the projection pursuit index for a given projector.
| x | Feature matrix (n × p). |
| group_spec | Group partition. |
| projector | Projection vector (p). |
Implemented in ppforest2::pp::PPPDAStrategy.
|
inline |
Convenience operator: optimize and return the projector only.
|
pure virtual |
Find the optimal projection for the data.
| x | Feature matrix (n × p). |
| group_spec | Group partition. |
Implemented in ppforest2::pp::PPPDAStrategy.