strange([]) is the only dispersion function not returning %nan for input []
Reported by Samuel GOUGEON (@sgougeon)
BUG DESCRIPTION:
----------------
All functions that are statistical estimators of data dispersion return %nan for no input data = [].
Excepted strange(), that returns [] instead.
I do not clearly understand why %nan is returned instead of [] by most of these functions.
But for consistency, we could prefer that strange([]) returns %nan as well:
--> strange([])
ans =
[]
--> // while
--> [ stdev([]) stdevf([],[]) variance([]) variancef([],[])
> iqr([]) mad([]) moment([],2) cmoment([],2) ]
ans =
Nan Nan Nan Nan
Nan Nan Nan Nan
ERROR LOG:
----------
HOW TO REPRODUCE THE BUG:
-------------------------
strange([])
// while
[ stdev([]) stdevf([],[]) variance([]) variancef([],[])
iqr([]) mad([]) moment([],2) cmoment([],2) ]