I have a lot of time-range values, simple statistics chart, but some time can meet wrong values, for example:
[1000, 1010, 1025, 1005, 1, 1015]
[1000, 1010, 1025, 1005, 1030, 1, 2, 5]
Can you advise any logic or algorithm to determine the wrong values?
UPDATE: wrong values - values that will dramatically differ from previous and always will be lower. It should not differ more than twice, e.g. next value can not be twice lower than previous.