Re: How about extending JAMA
Just to chime in here: This is one of the hopes and dreams I think we
have at Apache for the Jakarta Commons Math package. I think that Apache
represents a good neutral location for the advancement of such an open
and shared API. We already maintain a library of functions that can be
utilized to implement such Matrix operations.
http://jakarta.apache.org/commons/math
http://jakarta.apache.org/commons/math/apidocs/org/apache/commons/math/linear/RealMatrix.html
http://jakarta.apache.org/commons/math/apidocs/org/apache/commons/math/stat/StatUtils.html
We would gladly take any contributions and would enjoy others
involvement in advancing an open math java api further. All developers
are welcome.
-Mark
Sionep wrote:
>
> I like this idea that Kim is proposing here. I myself has extended
> JAMA for my own work and make most methods (in Extended Jama)
> equivalent to MatLab. This mean that I code in Java (JAMA) but think
> in MatLab. Some of the methods Kim have mentioned , I have already
> made available in my JAMA extension , because they are standard MatLab
> function call.
>
> In MatLab:
> ----------
>
> B = A(p ,:) - 'p' is the index of that row [getRow(int row)]
>
> B = A(: ,p) - 'p' is the index of that column [getColumn(int
> column)]
>
> B = mean(A ,2) - '2' is reference to mean of columns
> [getColumnMeans()]
>
> B = mean(A ,1) - '1' is reference to mean of rows [getRwoMeans()]
>
> B = diff(A ,1 ,1) - '1' and '1' are the "difference order" (first
> order in this case) and reference to 'rows' [differenceByRowMeans()]
>
> B = diff(A ,1 ,2) - '1' and '2' are the "difference order" (first
> order in this case) and reference to 'columns'
> [differenceByColumnMeans()]
>
> Just a suggestion to Ron and Cleve , if it is possible to make Jama
> evolve with users can make contributions so that Jama is regularly
> updated with the progress of each new version be made available from
> NIST. This will result in incremental new versions for Jama.
>
> Cheers,
> Sione.
>
>
> Kim van der Linde wrote:
>
>>
>> Hi All,
>>
>> I have a question. I have added several methods to the Matrix class
>> in Jama, such as:
>> public Matrix getRow(int row) // returns a 1xn matrix
>> public Matrix getColumn(int column) // returns a mx1 matrix
>> public double[] getColumnMeans()
>> public double[] getRowMeans()
>> public String toString() // gives back a tab separated row and column
>> correct string
>> public Matrix differenceByColumnMeans()
>> public Matrix differenceByRowMeans()
>>
>> Furthermore, I made a convinience class (Matrices) which returns
>> standard matrices such as SSCP, covariance and correlation matrices.
>>
>> I needed some of these for matrix calculations involving mahalanobis
>> distances of multivariate data sets and related outlier detection
>> using the Minimum Volume Ellipsoid (MVE) method.
>>
>> In the near future, I will make available a jar file with the MVE
>> module, and I need to incorporate a class with the added methods.
>> What would be the proper way to proceed. Included the amended
>> Jama.Matrix class, rename the class to kim.math.Matrix? How about
>> copyright notices? And if including the amended Jama.Matrix class is
>> preferred, how do I prevent mixing up with the original class?
>>
>> Cheers,
>>
>> Kim
>
>
--
Mark R. Diggory
Software Developer
Harvard MIT Data Center
http://www.hmdc.harvard.edu
Date Index |
Thread Index |
Problems or questions? Contact list-master@nist.gov