Skip to content
Prev 332776 / 398506 Next

Fitting multiple horizontal lines to data

On Nov 6, 2013, at 9:19 AM, Sashikanth Chandrasekaran wrote:

            
The human brain searches for patterns and often finds them where there is no underlying mechanism. If you are asking for a regime-change method that is statistically based and will replicate your brain-driven pencil-and-paper methods you will probably be disappointed.
If you want a method that is driven by the magnitude of the shift in adjacent values, then this would find some but not all of your proposed breakpoints:
[1] 11 13 22 25 26

You could perhaps refine that set of candidates by requiring that the next value have some other defining feature but I was unable to come up with a simple rule-set that agreed with your candidates . There are packages that do segmented regression but hey are not generall set up to assume all regression coefficients are 0 and that you are only interested in
David Winsemius
Alameda, CA, USA