From 1962417fff4ec572d81825b30690d5fad9bb80fd Mon Sep 17 00:00:00 2001 From: Guillaume Poirier-Morency Date: Fri, 7 Jun 2024 14:34:41 -0700 Subject: [PATCH] Revert "Use getId() directly instead of a transformer" This reverts commit f557095414fbecf53dcb8a0b57d5ac82afea2d35. --- .../analysis/expression/diff/LinearModelAnalyzerImpl.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzerImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzerImpl.java index 2acd7f5802..ffa311c810 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzerImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzerImpl.java @@ -22,6 +22,8 @@ import cern.colt.matrix.DoubleMatrix1D; import cern.colt.matrix.impl.DenseDoubleMatrix1D; import lombok.extern.apachecommons.CommonsLog; +import org.apache.commons.collections4.Transformer; +import org.apache.commons.collections4.TransformerUtils; import org.apache.commons.lang3.ArrayUtils; import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.time.StopWatch; @@ -692,6 +694,7 @@ private DifferentialExpressionAnalysis doAnalysis( BioAssaySet bioAssaySet, /* * Create result objects for each model fit. Keeping things in order is important. */ + final Transformer rowNameExtractor = TransformerUtils.invokerTransformer( "getId" ); boolean warned = false; // int notUsable = 0; int processed = 0; @@ -701,7 +704,7 @@ private DifferentialExpressionAnalysis doAnalysis( BioAssaySet bioAssaySet, LinearModelAnalyzerImpl.log.info( "Processed results for " + processed + " elements ..." ); } - LinearModelSummary lm = rawResults.get( el.getId().toString() ); + LinearModelSummary lm = rawResults.get( rowNameExtractor.transform( el ).toString() ); if ( LinearModelAnalyzerImpl.log.isDebugEnabled() ) LinearModelAnalyzerImpl.log.debug( el.getName() + "\n" + lm );