### Name: findSegments
### Title: Fit a piecewise constant curve to a sequence of numbers -
###   OBSOLETE, please use function segment instead.
### Aliases: findSegments
### Keywords: manip

### ** Examples

 x = rep( sin((0:4)/2*pi), each=3) + rnorm(3*5, sd=0.1)
 res = findSegments(x, maxcp=6, maxk=15)



