2 #include <creativity/data/Treatment.hpp> 50 double value(
const std::string &field)
const;
56 : source_(source), row_(rownum) {}
64 std::unique_ptr<const StageProperties>
pre;
69 std::unique_ptr<const StageProperties>
piracy;
74 std::unique_ptr<const StageProperties>
policy;
102 std::function<
bool(
const Properties&)> filter,
103 std::function<
bool(
bool pre,
bool piracy,
bool policy,
bool short_run)> stage_filter = [](
bool,
bool,
bool,
bool) {
return true; }
Extension to Treatment that applies a filter to an existing Treatment variable, resulting in a new Tr...
Definition: TreatmentFilter.hpp:36
std::unique_ptr< const StageProperties > policy
A pointer to the Properties values for the LR policy row associated with this row.
Definition: TreatmentFilter.hpp:74
Primary namespace for all Creativity library code.
Definition: config.hpp:4
std::unique_ptr< const StageProperties > pre
A pointer to the Properties value for the pre row associated with this row.
Definition: TreatmentFilter.hpp:64
std::string source
The source data simulation filename.
Definition: TreatmentFilter.hpp:86
std::unique_ptr< const StageProperties > piracy
A pointer to the Properties values for the LR piracy row associated with this row.
Definition: TreatmentFilter.hpp:69
std::unique_ptr< const StageProperties > policy_SR
A pointer to the Properties values for the SR public row associated with this row.
Definition: TreatmentFilter.hpp:84
This class converts raw simulation data into multiple data rows, with piracy/policy, SR/LR as treatment effects on the base (pre-piracy, pre-policy) row.
Definition: Treatment.hpp:14
Data properties for rows filtered by TreatmentFilter()
Definition: TreatmentFilter.hpp:61
Provides a simple interface to accessing the value of a field for a single observation.
Definition: TreatmentFilter.hpp:39
double value(const std::string &field) const
Returns the value associated with the given stage field name.
std::unique_ptr< const StageProperties > piracy_SR
A pointer to the Properties values for the SR piracy row associated with this row.
Definition: TreatmentFilter.hpp:79