-
Notifications
You must be signed in to change notification settings - Fork 76
Description
Describe breaks on Number columns. This happens because the Iterable<Number>.std() function accepts Number but doesn't convert them to Double (like mean() does).
There are a couple more missing actually:
-
cumSum- Misses
Byte,Short HasDataColumnoverloads but notIterable/Sequence
- Misses
-
meanHasSequence<Double | Float>but not for otherNumbertypes
-
median- Misses
Float,Byte,Short,Number(it only works onComparable) - Needs to handle other types consistently
NoSequenceoverloads- Cannot
skipNA(if applicable)
- Misses
-
minandmax- internal
Iterable<T>.minandmaxare not used and can be removed. Stdlib functions for Comparable sequences and iterables are used instead. - Misses
Number(it only works onComparable) ShortandByteare converted toIntfor some reason
- internal
-
std- Breaks if type is
Number ShortandByteare cast toIntwhich works but is a bit iffyIterable overloads missing forNumber,Short,ByteSequence overloads missingNullable overloads missing for Iterable (and sequence)
- Breaks if type is
-
varianceAndMean- also provides
std(ddof: Int)function without docs of what ddof even means, as well ascount. Could have a better name. Also can produce nulls?? this screams for documentation. - variance functions are missing on DataColumns entirely (had to be added separately for Kandy)
- Misses
Short,Byte,Number, and nullable overloads Misses Sequence overloads
- also provides
-
sum- Has
TODOs where types are amiss - Misses
Float(!),Short,Byte,Numberin variousIterableoverloads.
- Has
-
All are also missing
BigIntegeras we're supportingBigDecimaltoo. -
There are plenty of public overloads on
IterableandSequence. It's fine to have them internally, but I feel like we're clogging the public scope here.mean, for instance, is already covered in the stdlib. -
We need to honor some conversion table (see below)
-
Describe now only shows min, median, and max for
<T : Comparable<T>>columns, so notNumber. This makes sense, but not from a user-perspective. We can just convert to Double first, then calculate it.