Learn R Programming

prob (version 0.9-1)

noorder: Sort and Merge Probability Space Outcomes

Description

This function sorts the rows (outcomes) of a data frame probability space, effectively removing the original order present) and aggregates the sorted rows into a new probability data frame with unique, sorted outcomes.

Usage

noorder( space )

Arguments

space
a data frame probability space or a subset of one.

Value

  • A data frame with a probs column and sorted, unique rows.

Details

The data frame space must have at least two non-probs columns or an error will result.

See Also

addrv, marginal

Examples

Run this code
S <- tosscoin(3, makespace = TRUE)
noorder(S)

Run the code above in your browser using DataLab