[ 
https://issues.apache.org/jira/browse/MATH-1046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Hugo Ferrira closed MATH-1046.
------------------------------

       Resolution: Not A Problem
    Fix Version/s: 3.2

We can circumvent the issue with a wrapper class. 
See last comment. 

> math3.stat.Frequency: Allow Null keys (comparable objects)
> ----------------------------------------------------------
>
>                 Key: MATH-1046
>                 URL: https://issues.apache.org/jira/browse/MATH-1046
>             Project: Commons Math
>          Issue Type: Improvement
>    Affects Versions: 3.2
>         Environment: Linux, JDK 7
>            Reporter: Hugo Ferrira
>            Priority: Trivial
>              Labels: features
>             Fix For: 3.2
>
>
> The class {{math3.stat.Frequency}} uses a {{TreeMap}} which does not allow
> for the use of null keys ({{public void addValue(Comparable<?> v)}} with {{v 
> = null}}). I am analyzing data (matrix) whose values may 
> contain nulls. I need to get the counts for elements in a given column.
> This includes knowing how many are null. This information will be used
> for data cleaning/pre-processing.
>  A simple change would be substituting {{TreeMap}} with 
> {{java.util.HashMap<K,V>}}. 



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to