Skip to content

Commit

Permalink
Merge pull request #625 from apete/master
Browse files Browse the repository at this point in the history
Update ojAlgo to v51.3.0
  • Loading branch information
harmjanwestra authored Apr 30, 2024
2 parents 8262f39 + e3efbe5 commit 4cb7b89
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion genetica-libraries/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
<dependency>
<groupId>org.ojalgo</groupId>
<artifactId>ojalgo</artifactId>
<version>47.0.0</version>
<version>51.3.0</version>
</dependency>
<dependency>
<groupId>net.sf.trove4j</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
package umcg.genetica.math;

import Jama.EigenvalueDecomposition;
import com.sun.j3d.utils.geometry.Primitive;
import org.ojalgo.matrix.PrimitiveMatrix;

import org.ojalgo.matrix.Primitive64Matrix;
import org.ojalgo.matrix.decomposition.Eigenvalue;
import org.ojalgo.matrix.store.MatrixStore;
import org.ojalgo.matrix.store.PrimitiveDenseStore;
import org.ojalgo.matrix.store.RawStore;

import umcg.genetica.math.matrix2.DoubleMatrixDataset;
import umcg.genetica.math.stats.concurrent.ConcurrentCorrelation;
import umcg.genetica.text.Strings;
import umcg.genetica.util.RunTimer;

public class PCAojAlgo {

Expand Down Expand Up @@ -110,10 +110,10 @@ public void PCAojAlgo() {

public void eigenValueDecomposition(double[][] data) {
System.out.println("Performing eigenvector decomposition on " + data.length + " x " + data[data.length - 1].length + " matrix ");
PrimitiveMatrix matrix = PrimitiveMatrix.FACTORY.rows(data);
RawStore matrix = RawStore.wrap(data);


eig = Eigenvalue.make(matrix, true);
eig = Eigenvalue.PRIMITIVE.make(matrix, true);

if (!eig.decompose(matrix)) {
throw new RuntimeException("Decomposition failed");
Expand Down

0 comments on commit 4cb7b89

Please sign in to comment.