Class TableMultiWay.BalancedTable
- Enclosing class:
- TableMultiWay
-
Method Summary
Modifier and TypeMethodDescriptionint[]Returns an array of lengthnKeyscontaining in its i-th element (i=0,1,...nKeys-1), the number of levels or categories of the i-th classification variable (column).double[]getTable()Returns an array containing the frequencies for each variable.double[]Returns the values of the classification variables.
-
Method Details
-
getNvalues
public int[] getNvalues()Returns an array of lengthnKeyscontaining in its i-th element (i=0,1,...nKeys-1), the number of levels or categories of the i-th classification variable (column).- Returns:
- an
intarray containing the number of levels or for each variable (column) inx.
-
getTable
public double[] getTable()Returns an array containing the frequencies for each variable. The array is of length
nValues[0] x nValues[1] x ... x nValues[nKeys]containing the frequencies in the cells of the table to be fit, wherenValuescontains the result fromgetNValues.Empty cells are included in table, and each element of table is nonnegative. The cells of table are sequenced so that the first variable cycles through its
nValues[0]categories one time, the second variable cycles through itsnValues[1]categoriesnValues[0]times, the third variable cycles through itsnValues[2]categoriesnValues[0] * nValues[1]times, etc., up to thenKeys-th variable, which cycles through itsnValues[nKeys - 1]categoriesnValues[0] * nValues[1] * ... * nValues[nKeys - 2]times.- Returns:
- a
doublearray containing the frequencies for each variable inx.
-
getValues
public double[] getValues()Returns the values of the classification variables.getValuesreturns an array of lengthnValues[0] + nValues[1] + ... + nValues[nKeys - 1]The firstnValues[0]elements contain the values for the first classification variable. The nextnValues[1]contain the values for the second variable. The lastnValues[nKeys - 1]positions contain the values for the last classification variable, wherenValuescontains the result fromgetNValues.- Returns:
- a
doublearray containing the values of the classification variables.
-