Learn R Programming

EBS (version 3.1)

CardMK: Number of segmentations in K segments

Description

Number of all possible segmentations in K segments

Usage

CardMK(n,K)

Arguments

n
Integer giving length of dataset.
K
Integer giving number of segments in segmentation.

Value

A numeric object giving the number of possible segmentations of [1,n] in K segments.

Details

Returns the number of possible segmentations of [1,n] in K segments

References

Rigaill, Lebarbier & Robin (2012): Exact posterior distributions over the segmentation space and model selection for multiple change-point detection problems Statistics and Computing

See Also

PriorDistrib

Examples

Run this code
# number of partitions of {1, 100} in 5 segments: 
n<-100
K<-5
CardMK(n,K)

Run the code above in your browser using DataLab