Class SVDServiceImpl
- java.lang.Object
-
- ubic.gemma.core.analysis.preprocess.svd.SVDServiceImpl
-
- All Implemented Interfaces:
SVDService
@Service public class SVDServiceImpl extends Object implements SVDService
Perform SVD on expression data and store the results.- Author:
- paul
- See Also:
PrincipalComponentAnalysisService
-
-
Constructor Summary
Constructors Constructor Description SVDServiceImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<ExperimentalFactor>
getImportantFactors(ExpressionExperiment ee, Collection<ExperimentalFactor> experimentalFactors, Double importanceThreshold)
SVDResult
getSvd(ExpressionExperiment ee)
Get the SVD information for experiment with id given.SVDResult
getSvdFactorAnalysis(PrincipalComponentAnalysis pca)
Compare ExperimentalFactors and BioAssay.processingDates to the PCs.SVDResult
getSvdFactorAnalysis(ExpressionExperiment ee)
Compare ExperimentalFactors and BioAssay.processingDates to the PCs.Map<ProbeLoading,DoubleVectorValueObject>
getTopLoadedVectors(ExpressionExperiment ee, int component, int count)
boolean
hasPca(ExpressionExperiment ee)
static void
populateBMFMap(Map<ExperimentalFactor,Map<BioMaterial,Number>> bioMaterialFactorMap, BioMaterial bm)
Retrieve relationships between factors, biomaterials and factor values.SVDResult
svd(ExpressionExperiment ee)
-
-
-
Method Detail
-
populateBMFMap
public static void populateBMFMap(Map<ExperimentalFactor,Map<BioMaterial,Number>> bioMaterialFactorMap, BioMaterial bm)
Retrieve relationships between factors, biomaterials and factor values.Continuous factor values are converted to a
Double
if possible, otherwise theFactorValue.getId()
is used. This is the case for categorical measurement.- Parameters:
bioMaterialFactorMap
- to be populated, of experimental factor -> biomaterial ID -> factor value (double value if possible otherwise ID)bm
- to populate for
-
getSvd
@Transactional(readOnly=true) public SVDResult getSvd(ExpressionExperiment ee)
Get the SVD information for experiment with id given.- Specified by:
getSvd
in interfaceSVDService
- Returns:
- value or null if there isn't one.
-
svd
@Transactional public SVDResult svd(ExpressionExperiment ee) throws SVDException
- Specified by:
svd
in interfaceSVDService
- Throws:
SVDException
-
getTopLoadedVectors
@Transactional(readOnly=true) public Map<ProbeLoading,DoubleVectorValueObject> getTopLoadedVectors(ExpressionExperiment ee, int component, int count)
- Specified by:
getTopLoadedVectors
in interfaceSVDService
-
hasPca
@Transactional(readOnly=true) public boolean hasPca(ExpressionExperiment ee)
- Specified by:
hasPca
in interfaceSVDService
-
getImportantFactors
@Transactional(readOnly=true) public Set<ExperimentalFactor> getImportantFactors(ExpressionExperiment ee, Collection<ExperimentalFactor> experimentalFactors, Double importanceThreshold)
- Specified by:
getImportantFactors
in interfaceSVDService
- Parameters:
ee
- the expression experimentexperimentalFactors
- to considerimportanceThreshold
- threshold for pvalue of association with factor. Suggested value might be 0.01.- Returns:
- factors which are "significantly" associated with one of the first three PCs
-
getSvdFactorAnalysis
@Transactional(readOnly=true) public SVDResult getSvdFactorAnalysis(ExpressionExperiment ee)
Description copied from interface:SVDService
Compare ExperimentalFactors and BioAssay.processingDates to the PCs.- Specified by:
getSvdFactorAnalysis
in interfaceSVDService
- Parameters:
ee
- the experiment- Returns:
- SVD VO
-
getSvdFactorAnalysis
@Transactional(readOnly=true) public SVDResult getSvdFactorAnalysis(PrincipalComponentAnalysis pca)
Description copied from interface:SVDService
Compare ExperimentalFactors and BioAssay.processingDates to the PCs.- Specified by:
getSvdFactorAnalysis
in interfaceSVDService
- Parameters:
pca
- PCA- Returns:
- SVD VO
-
-