StateFrequency

class StateFrequency(numStates: Int, name: String? = null) : IdentityIfc

Parameters

numStates

the number of states to observe

Constructors

Link copied to clipboard
constructor(numStates: Int, name: String? = null)

Properties

Link copied to clipboard

Returns a copy of the cells in a list ordered by the value of each cell, 0th element is cell with the smallest value, etc

Link copied to clipboard

Returns an array of size getNumberOfCells() containing the frequencies by value

Link copied to clipboard
open override val id: Int
Link copied to clipboard
open override var label: String?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override val name: String
Link copied to clipboard

Returns the number of cells tabulated This is also the total number of different integers observed

Link copied to clipboard

Returns an array of size getNumberOfCells() containing the proportion by value

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

The total count associated with the values

Link copied to clipboard
Link copied to clipboard

Returns Map holding the values and cumulative proportions as arrays with keys "values" and "cumulativeProportions"

Link copied to clipboard

Returns Map holding the values and frequencies as arrays with keys "values" and "frequencies"

Link copied to clipboard

Returns Map holding the values and proportions as arrays with keys "values" and "proportions"

Link copied to clipboard

Returns an array of size getNumberOfCells() containing the values increasing by value

Functions

Link copied to clipboard
Link copied to clipboard
fun collect(states: Array<State>)
fun collect(states: List<State>)

fun collect(state: State)

Tabulate statistics on the state occurrences

Link copied to clipboard
Link copied to clipboard

Returns the cumulative frequency up to an including i

Link copied to clipboard

Returns the cumulative proportion up to an including i

Link copied to clipboard

Interprets the elements of x[] as values and returns an array representing the frequency for each value

Link copied to clipboard

Returns the current frequency for the provided integer

Link copied to clipboard
fun frequencyPlot(proportions: Boolean = false): StateFrequencyPlot

Creates a plot for the state frequencies. The parameter, proportions indicates whether proportions (true) or frequencies (false) will be shown on the plot. The default is false.

Link copied to clipboard
operator fun get(index: Int): State
Link copied to clipboard

Gets the proportion of the observations that are equal to the supplied integer

Link copied to clipboard
fun reset()

Resets the statistical collection

Link copied to clipboard
fun state(index: Int): State
Link copied to clipboard
Link copied to clipboard
open override fun toString(): String