public class GenericStatisticalDataStructure extends java.lang.Object implements StatisticalDataStructure
Modifier and Type | Field and Description |
---|---|
protected DataSet |
dataSet |
protected boolean |
isInterceptModel |
protected Matrix |
matrixX |
protected Matrix |
vectorY |
Constructor and Description |
---|
GenericStatisticalDataStructure(DataSet dataSet)
General constructor.
|
Modifier and Type | Method and Description |
---|---|
protected Matrix |
computeDummyVariables(int fieldIndex,
java.lang.String refClass) |
void |
constructMatrices(java.lang.String modelDefinition)
This method builds the matrices that are required to fit the model.
|
DataSet |
getDataSet()
This method returns the DataSet instance behind the StatisticalDataStructure.
|
Matrix |
getMatrixX()
Return the design matrix of the fixed effects.
|
int |
getNumberOfObservations()
Returns the number of observations in the data structure.
|
Matrix |
getVectorY()
Return the vector of response variables.
|
boolean |
isInterceptModel()
This method returns true if the model has an intercept or false otherwise.
|
void |
setInterceptModel(boolean isInterceptModel)
This method determines whether the model has an intercept
|
protected DataSet dataSet
protected boolean isInterceptModel
protected Matrix vectorY
protected Matrix matrixX
public GenericStatisticalDataStructure(DataSet dataSet)
dataSet
- the DataSet instance from which the structure is going to be extractedprotected Matrix computeDummyVariables(int fieldIndex, java.lang.String refClass) throws StatisticalDataException
StatisticalDataException
public boolean isInterceptModel()
StatisticalDataStructure
isInterceptModel
in interface StatisticalDataStructure
public void setInterceptModel(boolean isInterceptModel)
StatisticalDataStructure
setInterceptModel
in interface StatisticalDataStructure
isInterceptModel
- true if the model has an intercept or false otherwisepublic Matrix getMatrixX()
StatisticalDataStructure
getMatrixX
in interface StatisticalDataStructure
public Matrix getVectorY()
StatisticalDataStructure
getVectorY
in interface StatisticalDataStructure
public void constructMatrices(java.lang.String modelDefinition) throws StatisticalDataException
StatisticalDataStructure
constructMatrices
in interface StatisticalDataStructure
modelDefinition
- the definition of the model that serves to design the matricesStatisticalDataException
public int getNumberOfObservations()
StatisticalDataStructure
getNumberOfObservations
in interface StatisticalDataStructure
public DataSet getDataSet()
StatisticalDataStructure
getDataSet
in interface StatisticalDataStructure