largeRCRF-Java/src/main/java/ca/joeltherrien/randomforest/CovariateRow.java
Joel Therrien e96a578ac9 Refactored code to allow for a class of covariates to determine which
SplitRules are tested.

Most of the refactoring involved the creation of a Covariate class (one
instance per column); with SplitRule and Value being folded in as inner
classes.
2018-07-03 17:00:02 -07:00

26 lines
475 B
Java

package ca.joeltherrien.randomforest;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import java.util.Map;
@RequiredArgsConstructor
public class CovariateRow {
private final Map<String, Covariate.Value> valueMap;
@Getter
private final int id;
public Covariate.Value<?> getCovariateValue(String name){
return valueMap.get(name);
}
@Override
public String toString(){
return "CovariateRow " + this.id;
}
}