Jack
One of these perhaps:
(>/@i.(>./,<./)) 3 1 4 5 NB. compare first occurrences of max , min
1
((i.>./) > (i.<./)) 3 1 4 5 NB. compare 1st occcurence of max with
that of min
1
... but if you want to detect a trend in some random process, you might
need to
consider the statistical significance of this result.
Mike
Jack Andrews wrote:
hi,
i can find the magnitude of the largest difference:
(>./ - <./) 3 1 4 5
4
but how can i tell that the first minimum came
before the first maximum?
(and so, that there was a trend upwards)
ta, jack
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm