CardMK: Number of segmentations in K segments

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/Profiles.R

Description

Number of all possible segmentations in K segments

Usage

1
CardMK(n,K)

Arguments

n

Integer giving length of dataset.

K

Integer giving number of segments in segmentation.

Details

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

Value

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

Author(s)

Alice Cleynen

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

1
2
3
4
# number of partitions of {1, 100} in 5 segments: 
n<-100
K<-5
CardMK(n,K)

EBS documentation built on May 29, 2017, 5:49 p.m.