Class CoexpressionServiceImpl
java.lang.Object
ubic.gemma.persistence.service.association.coexpression.CoexpressionServiceImpl
- All Implemented Interfaces:
CoexpressionService
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncountLinks(ExpressionExperiment ee, Gene gene) countOldLinks(Collection<Gene> genes) voidcreateOrUpdate(ExpressionExperiment ee, List<NonPersistentNonOrderedCoexpLink> links, LinkCreator c, Set<Gene> genesTested) Maintenance method.voiddeleteLinks(ExpressionExperiment experiment) Maintenance method.findCoexpressionRelationships(Gene gene, Collection<Long> bas, int maxResults, boolean quick) Find links which are common to all of the given data sets.findCoexpressionRelationships(Gene gene, Collection<Long> bas, int stringency, int maxResults, boolean quick) Search for coexpression across all available data sets, for the given genes considered individually, subject to a stringency constraint.findCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int maxResults, boolean quick) Find coexpression links for the genes that are common to all the given datasets (that is, the stringency is equal to the size of the set of datasets)findCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int stringency, int maxResults, boolean quick) Find coexpression links for the genes that are common to at least stringency of the given datasets.findInterCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int stringency, boolean quick) Return coexpression relationships among the given genes in the given data sets, in a map of query gene to coexpression objects.getCoexpression(ExpressionExperiment experiment, boolean quick) booleanCheck if a given dataset has coexpression links.initializeLinksFromOldData(Gene g, Map<Long, Gene> idMap, Map<NonPersistentNonOrderedCoexpLink, SupportDetails> linksSoFar, Set<Long> skipGenes) void
-
Constructor Details
-
CoexpressionServiceImpl
public CoexpressionServiceImpl()
-
-
Method Details
-
hasLinks
Description copied from interface:CoexpressionServiceCheck if a given dataset has coexpression links.- Specified by:
hasLinksin interfaceCoexpressionService
-
countLinks
- Specified by:
countLinksin interfaceCoexpressionService- Parameters:
ee- bio assay setgene- gene- Returns:
- the number of links the gene has in the given data set ("node degree")
-
createOrUpdate
@Transactional public void createOrUpdate(ExpressionExperiment ee, List<NonPersistentNonOrderedCoexpLink> links, LinkCreator c, Set<Gene> genesTested) Description copied from interface:CoexpressionServiceMaintenance method.- Specified by:
createOrUpdatein interfaceCoexpressionService- Parameters:
ee- should be all of them for the bioAssaySet (not a batch)links- linksc- link creatorgenesTested- genes which were tested
-
deleteLinks
Description copied from interface:CoexpressionServiceMaintenance method. Remove coexpression information from the database about the experiment in question (this does not remove the analysis object).- Specified by:
deleteLinksin interfaceCoexpressionService- Parameters:
experiment- experiment
-
findCoexpressionRelationships
@Transactional(readOnly=true) public List<CoexpressionValueObject> findCoexpressionRelationships(Gene gene, Collection<Long> bas, int maxResults, boolean quick) Description copied from interface:CoexpressionServiceFind links which are common to all of the given data sets.- Specified by:
findCoexpressionRelationshipsin interfaceCoexpressionService- Parameters:
gene- genebas- data sets the link must be supported by; that is, the stringency is implied by bas.size(). Assumed to be security-filtered.maxResults- max resultsquick- quick- Returns:
- coexpression results.
-
findCoexpressionRelationships
@Transactional(readOnly=true) public List<CoexpressionValueObject> findCoexpressionRelationships(Gene gene, Collection<Long> bas, int stringency, int maxResults, boolean quick) Description copied from interface:CoexpressionServiceSearch for coexpression across all available data sets, for the given genes considered individually, subject to a stringency constraint.- Specified by:
findCoexpressionRelationshipsin interfaceCoexpressionService- Parameters:
gene- genebas- assumed to be security-filtered.stringency- the minimum number of data sets for which the coexpression must be observed, among the given datasets.maxResults- max resultsquick- quick- Returns:
- coexpression results.
-
findCoexpressionRelationships
@Transactional(readOnly=true) public Map<Long,List<CoexpressionValueObject>> findCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int maxResults, boolean quick) Description copied from interface:CoexpressionServiceFind coexpression links for the genes that are common to all the given datasets (that is, the stringency is equal to the size of the set of datasets)- Specified by:
findCoexpressionRelationshipsin interfaceCoexpressionService- Parameters:
t- taxongenes- genesbas- - assumed to already be security-filteredmaxResults- max resultsquick- quick- Returns:
- a map of gene IDs to coexpression results.
-
findCoexpressionRelationships
@Transactional(readOnly=true) public Map<Long,List<CoexpressionValueObject>> findCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int stringency, int maxResults, boolean quick) Description copied from interface:CoexpressionServiceFind coexpression links for the genes that are common to at least stringency of the given datasets.- Specified by:
findCoexpressionRelationshipsin interfaceCoexpressionService- Parameters:
t- taxongenes- genesbas- assumed to already be security-filteredstringency- the minimum number of data sets for which the coexpression must be observed, among the given datasets.maxResults- limit to the number of results per gene, but connections among the query genes (if there is more than one) are given priority and not subject to the limit.quick- quick- Returns:
- a map of gene IDs to coexpression results.
-
findInterCoexpressionRelationships
@Transactional(readOnly=true) public Map<Long,List<CoexpressionValueObject>> findInterCoexpressionRelationships(Taxon t, Collection<Long> genes, Collection<Long> bas, int stringency, boolean quick) Description copied from interface:CoexpressionServiceReturn coexpression relationships among the given genes in the given data sets, in a map of query gene to coexpression objects.- Specified by:
findInterCoexpressionRelationshipsin interfaceCoexpressionService- Parameters:
t- taxongenes- genesbas- data sets to be considered, presumed to be security filtered alreadystringency- Must be less than or equal to the number of data sets datasets.quick- quick- Returns:
- a map of gene IDs to coexpression results.
-
getCoexpression
@Transactional(readOnly=true) public Collection<CoexpressionValueObject> getCoexpression(ExpressionExperiment experiment, boolean quick) - Specified by:
getCoexpressionin interfaceCoexpressionService- Parameters:
experiment- experimentquick- quick- Returns:
- all the coexpression links for the given experiment, but not including flipped versions
-
updateNodeDegrees
- Specified by:
updateNodeDegreesin interfaceCoexpressionService
-
getNodeDegree
- Specified by:
getNodeDegreein interfaceCoexpressionService
-
getNodeDegrees
@Transactional(readOnly=true) public Map<Long,GeneCoexpressionNodeDegreeValueObject> getNodeDegrees(Collection<Long> g) - Specified by:
getNodeDegreesin interfaceCoexpressionService
-
initializeLinksFromOldData
@Transactional public Map<SupportDetails,Gene2GeneCoexpression> initializeLinksFromOldData(Gene g, Map<Long, Gene> idMap, Map<NonPersistentNonOrderedCoexpLink, SupportDetails> linksSoFar, Set<Long> skipGenes) - Specified by:
initializeLinksFromOldDatain interfaceCoexpressionService- Parameters:
g- geneidMap- id maplinksSoFar- links so farskipGenes- skip genes- Returns:
- links that were made
-
countOldLinks
- Specified by:
countOldLinksin interfaceCoexpressionService
-