diff --git a/.editorconfig b/.editorconfig index 76c98d911f..5933aeedee 100644 --- a/.editorconfig +++ b/.editorconfig @@ -41,4 +41,7 @@ indent_style=tab indent_style=tab [dwrServices.js] -indent_size=4 \ No newline at end of file +indent_size=4 + +[typo.css] +indent_style=tab \ No newline at end of file diff --git a/.jenkins/Jenkinsfile b/.jenkins/Jenkinsfile index 3476c1dad5..cf66ad7e89 100644 --- a/.jenkins/Jenkinsfile +++ b/.jenkins/Jenkinsfile @@ -6,6 +6,9 @@ def dataDir = '/space/gemmaData' def deployDir = '/var/local/tomcat/gemma' def cliDir = '/space/grp/gemma-cli' +// either hotfix or release, we only have one staging server +def stagingBranch = 'hotfix' + void setBuildStatus(String context, String message, String state) { step([ $class: "GitHubCommitStatusSetter", @@ -32,13 +35,13 @@ pipeline { if (env.BRANCH_NAME == "master" && gemmaVersion.endsWith("-SNAPSHOT")) { error("A production build must not have a -SNAPSHOT suffix.") } - if (env.BRANCH_NAME == "development" && !gemmaVersion.endsWith("-SNAPSHOT")) { + if (env.BRANCH_NAME != "master" && !gemmaVersion.endsWith("-SNAPSHOT")) { error("A development build must have a -SNAPSHOT suffix.") } if (env.BRANCH_NAME == 'development') { dataDir = '/space/sandboxgemmaData' } - if (env.BRANCH_NAME =~ '^(hotfix|release)-.*') { + if (env.BRANCH_NAME =~ '^' + stagingBranch + '-.*') { dataDir = '/space/staginggemmaData' } if (env.BRANCH_NAME == 'master') { @@ -46,7 +49,7 @@ pipeline { } else { deployDir = 'chalmers:' + deployDir } - if (env.BRANCH_NAME =~ '^(hotfix|release)-.*') { + if (env.BRANCH_NAME =~ '^' + stagingBranch + '-.*') { deployDir += '-staging' } if (env.BRANCH_NAME != 'master') { @@ -65,10 +68,7 @@ pipeline { archiveArtifacts artifacts: '**/target/*.jar, **/target/*.war', fingerprint: true setBuildStatus "Build", "Build #${env.BUILD_NUMBER} succeeded.", 'SUCCESS' } - failure { - setBuildStatus "Build", "Build #${env.BUILD_NUMBER} failed.", 'ERROR' - } - unstable { + unsuccessful { setBuildStatus "Build", "Build #${env.BUILD_NUMBER} failed.", 'FAILURE' } } @@ -85,10 +85,7 @@ pipeline { success { setBuildStatus "Tests", "Tests for build #${env.BUILD_NUMBER} have passed.", 'SUCCESS' } - failure { - setBuildStatus "Tests", "Tests for build #${env.BUILD_NUMBER} failed.", 'ERROR' - } - unstable { + unsuccessful { setBuildStatus "Tests", "Tests for build #${env.BUILD_NUMBER} failed.", 'FAILURE' } } @@ -105,10 +102,8 @@ pipeline { parallel { stage('Run slow unit tests and integration tests') { when { - anyOf { - branch 'hotfix-*' - branch 'release-*' - branch 'development' + not { + branch 'master' } } steps { @@ -126,34 +121,17 @@ pipeline { success { setBuildStatus "Integration tests", "Integration tests for build #${env.BUILD_NUMBER} have passed.", 'SUCCESS' } - failure { - setBuildStatus "Integration tests", "Integration tests for build #${env.BUILD_NUMBER} failed.", 'ERROR' - } - unstable { + unsuccessful { setBuildStatus "Integration tests", "Integration tests for build #${env.BUILD_NUMBER} failed.", 'FAILURE' } } } stage('Deploy artifacts') { - when { - anyOf { - branch 'master' - branch 'development' - } - } steps { sh 'mvn -B deploy -DskipTests' } } stage ('Deploy Maven website') { - when { - anyOf { - branch 'master' - branch 'hotfix-*' - branch 'release-*' - branch 'development' - } - } steps { sh 'mvn -B site-deploy' sh "ln -Tsf ${siteDir}/gemma/gemma-${gemmaVersion} ${dataDir}/gemma-devsite" @@ -164,8 +142,7 @@ pipeline { when { anyOf { branch 'master' - branch 'hotfix-*' - branch 'release-*' + branch stagingBranch + '-*' branch 'development' } } @@ -176,10 +153,8 @@ pipeline { } stage ('Deploy Gemma CLI') { when { - anyOf { - branch 'master' - branch 'hotfix-*' - branch 'release-*' + not { + branch 'development' } } steps { @@ -193,7 +168,7 @@ pipeline { fixed { slackSend color: 'good', message: "${env.JOB_NAME} - #${env.BUILD_NUMBER} Back to normal (<${env.BUILD_URL}|Open>)" } - unstable { + unsuccessful { slackSend color: 'danger', message: "${env.JOB_NAME} - #${env.BUILD_NUMBER} Failure (<${env.BUILD_URL}|Open>)" } } diff --git a/gemma-cli/pom.xml b/gemma-cli/pom.xml index a7a31ac050..eba8b0470c 100644 --- a/gemma-cli/pom.xml +++ b/gemma-cli/pom.xml @@ -3,7 +3,7 @@ gemma gemma - 1.31.1 + 1.31.2 4.0.0 gemma-cli diff --git a/gemma-cli/src/main/config/bash_completion.d/gemma-cli b/gemma-cli/src/main/config/bash_completion.d/gemma-cli index 433803351e..db7d4bce20 100644 --- a/gemma-cli/src/main/config/bash_completion.d/gemma-cli +++ b/gemma-cli/src/main/config/bash_completion.d/gemma-cli @@ -4,7 +4,7 @@ function __gemma_cli_complete() { current_option="${COMP_WORDS[$COMP_CWORD-1]}" if ! [[ " $words " =~ ' '(affyFromCel|pubmedSearchAndSave|gwasDownload|migrateFactorValues|makePlatformAnnotFiles|platformSubsumptionTest|listExternalDatabases|printExperimentalDesign|mergePlatforms|pubmedLoad|getDataMatrix|findObsoleteTerms|vectorMerge|generateDataFile|loadTaxa|rnaseqBatchInfo|platformMapSummary|loadGenesFromFile|dgaDownload|mapPlatformToGenes|probeRename|searchIndex|pubmedAssociateToExperiments|makePrivate|addGEOData|updateExternalDatabase|splitExperiment|importDesign|makeProcessedData|affyCollapse|deletePlatformElements|diffExAnalyze|omimDownload|geneUpdate|makePublic|deleteExperiments|detachSequences|dumpForNIF|updateMultifunc|deletePhenotypes|sfariDownload|platformRepeatScan|addTSVData|pca|updateGOAnnots|ctdDownload|viewExpDesigns|affyAltsUpdate|blackList|deleteDiffEx|fillBatchInfo|genericPlatform|orderVectorsByDesign|adATcleanup|replaceData|rgdDownload|runGeeq|rnaseqDataAdd|seqCleanup|listGEOData|fetchMeshTerms|evidenceImport|switchExperimentPlatform|addPlatformSequences|coexpAnalyze|blatPlatform|corrMat|updatePubMeds|loadEvidenceForClassifier|findDatasetPubs|addExternalDatabase)' ' ]]; then if ! [[ "$current_option" =~ (--logger|-v|--verbosity|-cs|--completion-shell|-logger) ]]; then - mapfile -t -O "${#COMPREPLY[@]}" COMPREPLY < <(compgen -W "'-version' '--testing' '-ha' '--version' '-v' '--completion-shell' '-logger' '-testing' '--help' '--logger' '-c' '--completion' '--verbosity' '-h' '-cs' '--help-all'" -- "$2") + mapfile -t -O "${#COMPREPLY[@]}" COMPREPLY < <(compgen -W "'-version' '-ha' '--version' '-v' '--completion-shell' '-logger' '-testdb' '--help' '--testdb' '--logger' '-c' '--completion' '--verbosity' '-h' '-cs' '--help-all'" -- "$2") fi mapfile -t -O "${#COMPREPLY[@]}" COMPREPLY < <(compgen -W "'affyFromCel' 'pubmedSearchAndSave' 'gwasDownload' 'migrateFactorValues' 'makePlatformAnnotFiles' 'platformSubsumptionTest' 'listExternalDatabases' 'printExperimentalDesign' 'mergePlatforms' 'pubmedLoad' 'getDataMatrix' 'findObsoleteTerms' 'vectorMerge' 'generateDataFile' 'loadTaxa' 'rnaseqBatchInfo' 'platformMapSummary' 'loadGenesFromFile' 'dgaDownload' 'mapPlatformToGenes' 'probeRename' 'searchIndex' 'pubmedAssociateToExperiments' 'makePrivate' 'addGEOData' 'updateExternalDatabase' 'splitExperiment' 'importDesign' 'makeProcessedData' 'affyCollapse' 'deletePlatformElements' 'diffExAnalyze' 'omimDownload' 'geneUpdate' 'makePublic' 'deleteExperiments' 'detachSequences' 'dumpForNIF' 'updateMultifunc' 'deletePhenotypes' 'sfariDownload' 'platformRepeatScan' 'addTSVData' 'pca' 'updateGOAnnots' 'ctdDownload' 'viewExpDesigns' 'affyAltsUpdate' 'blackList' 'deleteDiffEx' 'fillBatchInfo' 'genericPlatform' 'orderVectorsByDesign' 'adATcleanup' 'replaceData' 'rgdDownload' 'runGeeq' 'rnaseqDataAdd' 'seqCleanup' 'listGEOData' 'fetchMeshTerms' 'evidenceImport' 'switchExperimentPlatform' 'addPlatformSequences' 'coexpAnalyze' 'blatPlatform' 'corrMat' 'updatePubMeds' 'loadEvidenceForClassifier' 'findDatasetPubs' 'addExternalDatabase'" -- "$2") fi diff --git a/gemma-cli/src/main/config/fish/completions/gemma-cli.fish b/gemma-cli/src/main/config/fish/completions/gemma-cli.fish index bf78b23aab..1dabe553fb 100644 --- a/gemma-cli/src/main/config/fish/completions/gemma-cli.fish +++ b/gemma-cli/src/main/config/fish/completions/gemma-cli.fish @@ -5,7 +5,7 @@ complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSear complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -o version -l version --description 'Show Gemma version' complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -o logger -l logger -r --description 'Configure a specific logger verbosity (0=silent, 5=very verbose; default is custom, see log4j.properties). For example, '"'"'--logger ubic.gemma=5'"'"' or '"'"'--logger org.hibernate.SQL=5'"'"'' complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -s v -l verbosity -r --description 'Set verbosity level for all loggers (0=silent, 5=very verbose; default is custom, see log4j.properties)' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -o testing -l testing --description 'Use the test environment' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -o testdb -l testdb --description 'Use the test database as described by gemma.testdb.* configuration' complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'addGEOData' --description 'Load data from GEO' complete -c gemma-cli -n '__fish_seen_subcommand_from addGEOData' -f complete -c gemma-cli -n '__fish_seen_subcommand_from addGEOData' -s h -l help -f --description 'Print this message' @@ -375,7 +375,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from vectorMerge' -s q -l expre complete -c gemma-cli -n '__fish_seen_subcommand_from vectorMerge' -o batchFormat -r -f --description 'Format to use to the batch summary' complete -c gemma-cli -n '__fish_seen_subcommand_from vectorMerge' -o batchOutputFile -r --description 'Output file to use for the batch summary (default is standard output)' complete -c gemma-cli -n '__fish_seen_subcommand_from vectorMerge' -o force -l force -f --description 'Ignore other reasons for skipping experiments (e.g., trouble) and overwrite existing data (see documentation for this tool to see exact behavior if not clear)' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'adATcleanup' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'adATcleanup' complete -c gemma-cli -n '__fish_seen_subcommand_from adATcleanup' -f complete -c gemma-cli -n '__fish_seen_subcommand_from adATcleanup' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n '__fish_seen_subcommand_from adATcleanup' -s a -l array -r -f --description 'Array design name (or short name); or comma-delimited list' @@ -398,7 +398,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from addPlatformSequences' -s y complete -c gemma-cli -n '__fish_seen_subcommand_from addPlatformSequences' -s s -l sequence -r -f --description 'A single accession to update' complete -c gemma-cli -n '__fish_seen_subcommand_from addPlatformSequences' -o force -f --description 'Force overwriting of existing sequences; If biosequences are encountered that already have sequences filled in, they will be overwritten; default is to leave them.' complete -c gemma-cli -n '__fish_seen_subcommand_from addPlatformSequences' -s t -r -f --description 'Taxon common name (e.g., human) for sequences (only required if array design is '"'"'naive'"'"')' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'affyCollapse' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'affyCollapse' complete -c gemma-cli -n '__fish_seen_subcommand_from affyCollapse' -f complete -c gemma-cli -n '__fish_seen_subcommand_from affyCollapse' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n '__fish_seen_subcommand_from affyCollapse' -s a -l array -r -f --description 'Array design name (or short name); or comma-delimited list' @@ -421,7 +421,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from blatPlatform' -o sensitive complete -c gemma-cli -n '__fish_seen_subcommand_from blatPlatform' -s t -r -f --description 'Taxon common name (e.g., human); if platform name not given (analysis will be restricted to sequences on that platform for taxon given), blat will be run for all ArrayDesigns from that taxon (overrides -a and -b)' complete -c gemma-cli -n '__fish_seen_subcommand_from blatPlatform' -s s -l scoreThresh -r -f --description 'Threshold (0-1.0) for acceptance of BLAT alignments [Default = 0.7]' complete -c gemma-cli -n '__fish_seen_subcommand_from blatPlatform' -s b -l blatfile -r --description 'Blat result file in PSL format (if supplied, BLAT will not be run; will not work with settings that indicate multiple platforms to run); -t option overrides' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'deletePlatformElements' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'deletePlatformElements' complete -c gemma-cli -n '__fish_seen_subcommand_from deletePlatformElements' -f complete -c gemma-cli -n '__fish_seen_subcommand_from deletePlatformElements' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n '__fish_seen_subcommand_from deletePlatformElements' -s a -l array -r -f --description 'Array design name (or short name); or comma-delimited list' @@ -516,7 +516,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from platformSubsumptionTest' - complete -c gemma-cli -n '__fish_seen_subcommand_from platformSubsumptionTest' -o batchOutputFile -r --description 'Output file to use for the batch summary (default is standard output)' complete -c gemma-cli -n '__fish_seen_subcommand_from platformSubsumptionTest' -s o -l other -r -f --description 'Short name(s) of platforms to compare to the first one, comma-delimited' complete -c gemma-cli -n '__fish_seen_subcommand_from platformSubsumptionTest' -o all -f --description 'Test all platforms listed against all (not just to the first one)' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'probeRename' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'probeRename' complete -c gemma-cli -n '__fish_seen_subcommand_from probeRename' -f complete -c gemma-cli -n '__fish_seen_subcommand_from probeRename' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n '__fish_seen_subcommand_from probeRename' -s a -l array -r -f --description 'Array design name (or short name); or comma-delimited list' @@ -553,7 +553,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from listGEOData' -o output -r complete -c gemma-cli -n '__fish_seen_subcommand_from listGEOData' -o platforms -f --description 'Fetch a list of all platforms instead of experiments (date and gselimit ignored)' complete -c gemma-cli -n '__fish_seen_subcommand_from listGEOData' -o startat -r -f --description 'Attempt to '"'"'fast-rewind'"'"' to the given GSE ID and continue retreiving from there ' complete -c gemma-cli -n '__fish_seen_subcommand_from listGEOData' -o startdate -r -f --description 'Attempt to '"'"'fast-rewind'"'"' to the given date (yyyy.MM.dd) and continue retreiving from there ' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'platformMapSummary' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'platformMapSummary' complete -c gemma-cli -n '__fish_seen_subcommand_from platformMapSummary' -f complete -c gemma-cli -n '__fish_seen_subcommand_from platformMapSummary' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n '__fish_seen_subcommand_from platformMapSummary' -s a -l array -r -f --description 'Array design name (or short name); or comma-delimited list' @@ -602,7 +602,7 @@ complete -c gemma-cli -n '__fish_seen_subcommand_from evidenceImport' -s c -f -- complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'gwasDownload' --description 'Creates a .tsv file of lines of evidence from GWAS publications, to be used with evidenceImport to import into Phenocarta.' complete -c gemma-cli -n '__fish_seen_subcommand_from gwasDownload' -f complete -c gemma-cli -n '__fish_seen_subcommand_from gwasDownload' -s h -l help -f --description 'Print this message' -complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'loadEvidenceForClassifier' --description 'No description provided' +complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'loadEvidenceForClassifier' complete -c gemma-cli -n '__fish_seen_subcommand_from loadEvidenceForClassifier' -f complete -c gemma-cli -n '__fish_seen_subcommand_from loadEvidenceForClassifier' -s h -l help -f --description 'Print this message' complete -c gemma-cli -n 'not __fish_seen_subcommand_from affyFromCel pubmedSearchAndSave gwasDownload migrateFactorValues makePlatformAnnotFiles platformSubsumptionTest listExternalDatabases printExperimentalDesign mergePlatforms pubmedLoad getDataMatrix findObsoleteTerms vectorMerge generateDataFile loadTaxa rnaseqBatchInfo platformMapSummary loadGenesFromFile dgaDownload mapPlatformToGenes probeRename searchIndex pubmedAssociateToExperiments makePrivate addGEOData updateExternalDatabase splitExperiment importDesign makeProcessedData affyCollapse deletePlatformElements diffExAnalyze omimDownload geneUpdate makePublic deleteExperiments detachSequences dumpForNIF updateMultifunc deletePhenotypes sfariDownload platformRepeatScan addTSVData pca updateGOAnnots ctdDownload viewExpDesigns affyAltsUpdate blackList deleteDiffEx fillBatchInfo genericPlatform orderVectorsByDesign adATcleanup replaceData rgdDownload runGeeq rnaseqDataAdd seqCleanup listGEOData fetchMeshTerms evidenceImport switchExperimentPlatform addPlatformSequences coexpAnalyze blatPlatform corrMat updatePubMeds loadEvidenceForClassifier findDatasetPubs addExternalDatabase' -f -a 'omimDownload' --description 'Creates a .tsv file of lines of evidence from OMIM, to be used with evidenceImport to import into Phenocarta.' diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/AffyProbeCollapseCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/AffyProbeCollapseCli.java index 6a39f592a3..4160da3584 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/AffyProbeCollapseCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/AffyProbeCollapseCli.java @@ -28,6 +28,7 @@ import ubic.gemma.model.expression.designElement.CompositeSequence; import ubic.gemma.model.genome.biosequence.BioSequence; +import javax.annotation.Nullable; import java.io.IOException; import java.util.Collection; @@ -60,6 +61,12 @@ public String getCommandName() { return "affyCollapse"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + @Override protected void buildOptions( Options options ) { super.buildOptions( options ); diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignAuditTrailCleanupCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignAuditTrailCleanupCli.java index b7c7be16e7..2c3c238e17 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignAuditTrailCleanupCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignAuditTrailCleanupCli.java @@ -30,6 +30,8 @@ import ubic.gemma.model.common.auditAndSecurity.eventType.AuditEventType; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; +import javax.annotation.Nullable; + /** * work in progress * @@ -47,6 +49,12 @@ public String getCommandName() { return "adATcleanup"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + /* * (non-Javadoc) * diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignMapSummaryCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignMapSummaryCli.java index bb4a6481e0..9cb63c67a3 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignMapSummaryCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignMapSummaryCli.java @@ -22,6 +22,7 @@ import ubic.gemma.core.analysis.sequence.CompositeSequenceMapSummary; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; +import javax.annotation.Nullable; import java.util.Collection; /** @@ -36,6 +37,12 @@ public String getCommandName() { return "platformMapSummary"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + @Override protected void doWork() throws Exception { ArrayDesignMapResultService arrayDesignMapResultService = this.getBean( ArrayDesignMapResultService.class ); diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeCleanupCLI.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeCleanupCLI.java index 19bade4309..7974e66b66 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeCleanupCLI.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeCleanupCLI.java @@ -30,6 +30,7 @@ import ubic.gemma.persistence.service.expression.bioAssayData.RawAndProcessedExpressionDataVectorService; import ubic.gemma.persistence.service.expression.designElement.CompositeSequenceService; +import javax.annotation.Nullable; import java.io.*; /** @@ -70,6 +71,12 @@ public String getCommandName() { return "deletePlatformElements"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + @Override protected void doWork() throws Exception { File f = new File( file ); diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeRenamerCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeRenamerCli.java index 987871cda6..eac1764a8d 100755 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeRenamerCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ArrayDesignProbeRenamerCli.java @@ -29,6 +29,7 @@ import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.designElement.CompositeSequence; +import javax.annotation.Nullable; import java.io.*; import java.util.HashMap; import java.util.Map; @@ -77,6 +78,12 @@ public String getCommandName() { return "probeRename"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + @Override protected void doWork() throws Exception { if ( fileName == null ) { diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExperimentalDesignViewCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExperimentalDesignViewCli.java index ae647468dc..2a5d5a1b7e 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExperimentalDesignViewCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExperimentalDesignViewCli.java @@ -83,7 +83,7 @@ protected void doWork() throws Exception { if ( f.getCharacteristics().size() > 0 ) { for ( Characteristic c : f.getCharacteristics() ) { - if ( c.getCategory().equals( category ) ) { + if ( Objects.equals( c.getCategory(), category ) ) { String value = c.getValue(); diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataCorrMatCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataCorrMatCli.java index 454b2d475a..bd4fef27d7 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataCorrMatCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataCorrMatCli.java @@ -75,9 +75,11 @@ private void processExperiment( ExpressionExperiment ee ) { ee = eeService.thawLiter( ee ); try { if ( force ) { - sampleCoexpressionAnalysisService.compute( ee ); + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); } else { - sampleCoexpressionAnalysisService.computeIfNecessary( ee ); + if ( sampleCoexpressionAnalysisService.retrieveExisting( ee ) == null ) { + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); + } } addSuccessObject( ee ); } catch ( Exception e ) { diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataMatrixWriterCLI.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataMatrixWriterCLI.java index 52fd8eb606..3cee04b32e 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataMatrixWriterCLI.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/ExpressionDataMatrixWriterCLI.java @@ -28,7 +28,9 @@ import ubic.gemma.model.expression.experiment.BioAssaySet; import ubic.gemma.model.expression.experiment.ExpressionExperiment; +import java.io.File; import java.io.IOException; +import java.util.Optional; /** * Prints preferred data matrix to a file. @@ -84,7 +86,12 @@ protected void doWork() throws Exception { } try { - fs.writeDataFile( ( ExpressionExperiment ) ee, filter, fileName, false ); + Optional f = fs.writeProcessedExpressionDataFile( ( ExpressionExperiment ) ee, filter, fileName, false ); + if ( f.isPresent() ) { + addSuccessObject( ee, "Written expression data to " + f ); + } else { + addErrorObject( ee, "No processed expression data vectors to write." ); + } } catch ( IOException e ) { addErrorObject( ee, e ); } diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/GemmaCLI.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/GemmaCLI.java index 723e4fa2a3..1bc5d7076b 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/GemmaCLI.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/GemmaCLI.java @@ -23,12 +23,12 @@ import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.exception.ExceptionUtils; import org.springframework.context.ApplicationContext; +import org.springframework.context.ConfigurableApplicationContext; import org.springframework.security.core.context.SecurityContextHolder; import ubic.gemma.core.logging.LoggingConfigurer; import ubic.gemma.core.logging.log4j.Log4jConfigurer; import ubic.gemma.core.util.*; import ubic.gemma.persistence.util.SpringContextUtil; -import ubic.gemma.persistence.util.SpringProfiles; import javax.annotation.Nullable; import java.io.PrintWriter; @@ -55,7 +55,7 @@ public class GemmaCLI { VERSION_OPTION = "version", LOGGER_OPTION = "logger", VERBOSITY_OPTION = "v", - TESTING_OPTION = "testing"; // historically named '-testing', but now '--testing' is also accepted + TESTDB_OPTION = "testdb"; /** * Pattern used to match password in the CLI arguments. @@ -66,6 +66,8 @@ public class GemmaCLI { private static final LoggingConfigurer loggingConfigurer = new Log4jConfigurer(); + private static ApplicationContext ctx = null; + public static void main( String[] args ) { Option logOpt = Option.builder( VERBOSITY_OPTION ) .longOpt( "verbosity" ).hasArg() @@ -84,26 +86,26 @@ public static void main( String[] args ) { .addOption( VERSION_OPTION, "version", false, "Show Gemma version" ) .addOption( otherLogOpt ) .addOption( logOpt ) - .addOption( TESTING_OPTION, "testing", false, "Use the test environment" ); + .addOption( TESTDB_OPTION, "testdb", false, "Use the test database as described by gemma.testdb.* configuration" ); CommandLine commandLine; try { commandLine = new DefaultParser().parse( options, args, true ); } catch ( ParseException e ) { - System.exit( 1 ); + exit( 1 ); return; // that's silly... } // quick help without loading the context if ( commandLine.hasOption( HELP_OPTION ) ) { GemmaCLI.printHelp( options, null, new PrintWriter( System.out, true ) ); - System.exit( 0 ); + exit( 0 ); return; } if ( commandLine.hasOption( VERSION_OPTION ) ) { - BuildInfo buildInfo = BuildInfo.fromSettings(); + BuildInfo buildInfo = BuildInfo.fromClasspath(); System.out.printf( "Gemma version %s%n", buildInfo ); - System.exit( 0 ); + exit( 0 ); return; } @@ -114,7 +116,7 @@ public static void main( String[] args ) { System.err.printf( "Failed to parse the %s option: %s.%n", VERBOSITY_OPTION, ExceptionUtils.getRootCauseMessage( e ) ); GemmaCLI.printHelp( options, null, new PrintWriter( System.err, true ) ); - System.exit( 1 ); + exit( 1 ); return; } } @@ -124,7 +126,7 @@ public static void main( String[] args ) { String[] vals = value.split( "=" ); if ( vals.length != 2 ) { System.err.println( "Logging value must in format [loggerName]=[value]." ); - System.exit( 1 ); + exit( 1 ); } String loggerName = vals[0]; try { @@ -134,7 +136,7 @@ public static void main( String[] args ) { loggerName, ExceptionUtils.getRootCauseMessage( e ) ); GemmaCLI.printHelp( options, null, new PrintWriter( System.err, true ) ); - System.exit( 1 ); + exit( 1 ); return; } } @@ -150,9 +152,9 @@ public static void main( String[] args ) { List profiles = new ArrayList<>(); profiles.add( "cli" ); - // check for the -testing/--testing flag to load the appropriate application context - if ( commandLine.hasOption( TESTING_OPTION ) ) { - profiles.add( SpringProfiles.TEST ); + // enable the test database + if ( commandLine.hasOption( TESTDB_OPTION ) ) { + profiles.add( "testdb" ); } ApplicationContext ctx = SpringContextUtil.getApplicationContext( profiles.toArray( new String[0] ) ); @@ -220,7 +222,7 @@ public static void main( String[] args ) { if ( commandLine.getArgList().isEmpty() ) { System.err.println( "No command was supplied." ); GemmaCLI.printHelp( options, commandGroups, new PrintWriter( System.err, true ) ); - System.exit( 1 ); + exit( 1 ); } // the first element of the remaining args is the command and the rest are the arguments @@ -248,7 +250,7 @@ public static void main( String[] args ) { } } - System.exit( statusCode ); + exit( statusCode ); } /** @@ -267,6 +269,7 @@ private static void printHelp( Options options, @Nullable SortedMap> entry : commands.entrySet() ) { @@ -274,8 +277,17 @@ private static void printHelp( Options options, @Nullable SortedMap commandsInGroup = entry.getValue(); footer.append( "---- " ).append( entry.getKey() ).append( " ----" ).append( '\n' ); + int longestCommandInGroup = commandsInGroup.keySet().stream() + .map( String::length ) + .max( Integer::compareTo ) + .orElse( 0 ); for ( Map.Entry e : commandsInGroup.entrySet() ) { - footer.append( e.getKey() ).append( " - " ).append( e.getValue().getShortDesc() ).append( '\n' ); + footer.append( e.getKey() ) + .append( StringUtils.repeat( ' ', longestCommandInGroup - e.getKey().length() ) ) + // FIXME: use a tabulation, but it creates newlines in IntelliJ's console + .append( " " ) + .append( StringUtils.defaultIfBlank( e.getValue().getShortDesc(), "No description provided" ) ) + .append( '\n' ); } footer.append( '\n' ); } @@ -289,6 +301,16 @@ private static void printHelp( Options options, @Nullable SortedMap MAX_EMPTY_CHUNKS_IN_A_ROW ) { - log.info("Have already skipped " + numSkippedChunks + " chunks, still no records: bailing"); + if ( numSkippedChunks > MAX_EMPTY_CHUNKS_IN_A_ROW ) { + log.info( "Have already skipped " + numSkippedChunks + " chunks, still no records: bailing" ); break; } start += NCBI_CHUNK_SIZE; @@ -368,11 +368,11 @@ protected void doWork() throws Exception { + "\t" + geoRecord.getSubSeriesOf() + "\t" + geoRecord.getPubMedIds() + "\t" + geoRecord.getTitle() - + "\t" + geoRecord.getSummary() + + "\t" + clean(geoRecord.getSummary()) + "\t" + geoRecord.getMeshHeadings() - + "\t" + geoRecord.getSampleDetails() - + "\t" + geoRecord.getLibraryStrategy() - + "\t" + geoRecord.getOverallDesign() + "\n" ); + + "\t" + clean(geoRecord.getSampleDetails()) + + "\t" + clean(geoRecord.getLibraryStrategy()) + + "\t" + clean(geoRecord.getOverallDesign()) + "\n" ); seen.add( geoRecord.getGeoAccession() ); @@ -387,4 +387,14 @@ protected void doWork() throws Exception { } + + /** + * Replace any 'tab' characters with spaces. + * @param s + * @return + */ + String clean( String s ) { + return s.replace( '\t', ' ' ); + } + } diff --git a/gemma-cli/src/main/java/ubic/gemma/core/apps/LoadExpressionDataCli.java b/gemma-cli/src/main/java/ubic/gemma/core/apps/LoadExpressionDataCli.java index 404cd50674..447560724b 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/apps/LoadExpressionDataCli.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/apps/LoadExpressionDataCli.java @@ -75,6 +75,7 @@ public class LoadExpressionDataCli extends AbstractAuthenticatedCLI { private boolean splitByPlatform = false; private boolean suppressPostProcessing = false; private boolean updateOnly = false; + private String softFile = null; @Override public CommandGroup getCommandGroup() { @@ -124,6 +125,8 @@ protected void buildOptions( Options options ) { options.addOption( Option.builder( "nopost" ).desc( "Suppress postprocessing steps" ).build() ); + options.addOption( Option.builder( "softfile" ).desc( "Load directly from soft.gz file; use with single accession via -e" ).hasArg().argName( "soft file path" ).build() ); + /* * add 'allowsub/super' series option; */ @@ -141,6 +144,14 @@ protected void doWork() throws Exception { "You must specific either a file or accessions on the command line" ); } + if ( softFile != null ) { + Collection ees = geoService.loadFromSoftFile( accessions, softFile, platformOnly, doMatching, splitByPlatform ); + for ( Object object : ees ) { + addSuccessObject( object ); + } + return; + } + if ( accessions != null ) { AbstractCLI.log.info( "Got accession(s) from command line " + accessions ); String[] accsToRun = StringUtils.split( accessions, ',' ); @@ -228,6 +239,13 @@ protected void processOptions( CommandLine commandLine ) { this.suppressPostProcessing = commandLine.hasOption( "nopost" ); + if ( commandLine.hasOption( "softfile" ) ) { + this.softFile = commandLine.getOptionValue( "softfile" ); + if ( accessions == null || accessions.split( "," ).length > 1 ) { + throw new IllegalArgumentException( "You must specify exactly one accession to load from a SOFT file" ); + } + + } } private void processAccession( String accession ) { diff --git a/gemma-cli/src/main/java/ubic/gemma/core/loader/association/phenotype/LoadEvidenceForClassifier.java b/gemma-cli/src/main/java/ubic/gemma/core/loader/association/phenotype/LoadEvidenceForClassifier.java index f1bc663678..61835560d6 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/loader/association/phenotype/LoadEvidenceForClassifier.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/loader/association/phenotype/LoadEvidenceForClassifier.java @@ -25,6 +25,7 @@ import ubic.gemma.model.common.description.MedicalSubjectHeading; import ubic.gemma.persistence.util.Settings; +import javax.annotation.Nullable; import java.io.*; import java.util.HashSet; import java.util.Set; @@ -59,6 +60,12 @@ public String getCommandName() { return "loadEvidenceForClassifier"; } + @Nullable + @Override + public String getShortDesc() { + return null; + } + @Override protected void buildOptions( Options options ) { } diff --git a/gemma-cli/src/main/java/ubic/gemma/core/util/AbstractAuthenticatedCLI.java b/gemma-cli/src/main/java/ubic/gemma/core/util/AbstractAuthenticatedCLI.java index 2caf470887..273528c431 100644 --- a/gemma-cli/src/main/java/ubic/gemma/core/util/AbstractAuthenticatedCLI.java +++ b/gemma-cli/src/main/java/ubic/gemma/core/util/AbstractAuthenticatedCLI.java @@ -66,11 +66,6 @@ public abstract class AbstractAuthenticatedCLI extends AbstractCLI { @Autowired private ManualAuthenticationService manAuthentication; - @Override - public String getShortDesc() { - return "No description provided"; - } - /** * Indicate if the command requires authentication. *

diff --git a/gemma-cli/src/test/java/ubic/gemma/core/apps/NCBIGene2GOAssociationLoaderCLITest.java b/gemma-cli/src/test/java/ubic/gemma/core/apps/NCBIGene2GOAssociationLoaderCLITest.java index 3afdd45593..fcbf23dc57 100644 --- a/gemma-cli/src/test/java/ubic/gemma/core/apps/NCBIGene2GOAssociationLoaderCLITest.java +++ b/gemma-cli/src/test/java/ubic/gemma/core/apps/NCBIGene2GOAssociationLoaderCLITest.java @@ -1,6 +1,7 @@ package ubic.gemma.core.apps; import gemma.gsec.authentication.ManualAuthenticationService; +import org.junit.Ignore; import org.junit.Test; import org.junit.experimental.categories.Category; import org.springframework.beans.factory.annotation.Autowired; @@ -24,7 +25,6 @@ import static org.mockito.Mockito.*; import static ubic.gemma.core.util.test.Assumptions.assumeThatResourceIsAvailable; -@Category(SlowTest.class) @ContextConfiguration @TestExecutionListeners(WithSecurityContextTestExecutionListener.class) public class NCBIGene2GOAssociationLoaderCLITest extends BaseCliTest { @@ -79,6 +79,8 @@ public PersisterHelper persisterHelper() { private ExternalDatabaseService externalDatabaseService; @Test + @Ignore("This test is too slow, see https://github.com/PavlidisLab/Gemma/issues/1056 for details") + @Category(SlowTest.class) @WithMockUser(authorities = { "GROUP_ADMIN" }) public void test() throws Exception { assumeThatResourceIsAvailable( "ftp://ftp.ncbi.nih.gov/gene/DATA/gene2go.gz" ); diff --git a/gemma-cli/src/test/java/ubic/gemma/core/util/test/BaseCliTest.java b/gemma-cli/src/test/java/ubic/gemma/core/util/test/BaseCliTest.java index 4413c44cd1..6da0450626 100644 --- a/gemma-cli/src/test/java/ubic/gemma/core/util/test/BaseCliTest.java +++ b/gemma-cli/src/test/java/ubic/gemma/core/util/test/BaseCliTest.java @@ -2,12 +2,12 @@ import org.springframework.test.context.ActiveProfiles; import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; /** * Minimal setup */ -@ActiveProfiles({ "cli", SpringProfiles.TEST }) +@ActiveProfiles({ "cli", EnvironmentProfiles.TEST }) public abstract class BaseCliTest extends AbstractJUnit4SpringContextTests { } diff --git a/gemma-core/pom.xml b/gemma-core/pom.xml index 29d94a385f..31a8933710 100644 --- a/gemma-core/pom.xml +++ b/gemma-core/pom.xml @@ -3,7 +3,7 @@ gemma gemma - 1.31.1 + 1.31.2 4.0.0 gemma-core diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzer.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzer.java index 7ccf21a933..bb24b7c786 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzer.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/expression/diff/LinearModelAnalyzer.java @@ -27,6 +27,7 @@ import org.apache.commons.lang3.time.StopWatch; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.springframework.beans.factory.DisposableBean; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; import ubic.basecode.dataStructure.matrix.DenseDoubleMatrix; @@ -71,7 +72,7 @@ */ @Component @Scope(value = "prototype") -public class LinearModelAnalyzer extends AbstractDifferentialExpressionAnalyzer { +public class LinearModelAnalyzer extends AbstractDifferentialExpressionAnalyzer implements DisposableBean { /** * Preset levels for which we will store the HitListSizes. @@ -123,7 +124,7 @@ public static DoubleMatrix makeDataMatrix( ObjectMatrix columnsToUse ) { + public static BioAssayDimension createBADMap( List columnsToUse ) { /* * Indices of the biomaterials in the original matrix. */ @@ -143,6 +144,18 @@ private static BioAssayDimension createBADMap( List columnsToUse ) return reorderedDim; } + /** + * Executor used for performing analyses in the background while the current thread is reporting progress. + *

+ * This bean is using the prototype scope, so a single-thread executor is suitable to prevent concurrent analyses. + */ + private final ExecutorService executorService = Executors.newSingleThreadExecutor(); + + @Override + public void destroy() throws Exception { + executorService.shutdown(); + } + /** * Determine if any factor should be treated as the intercept term. */ @@ -383,10 +396,6 @@ public Collection run( ExpressionExperiment expr throw new RuntimeException( String.format( "There are no processed EVs for %s.", expressionExperiment ) ); } - /* - * FIXME remove flagged outlier samples ... at some point; so we don't carry NaNs around unnecessarily. - */ - return this.run( expressionExperiment, dmatrix, config ); } @@ -1097,7 +1106,7 @@ private DifferentialExpressionAnalysis makeAnalysisEntity( BioAssaySet bioAssayS expressionAnalysis.setDescription( "Linear model with " + config.getFactorsToInclude().size() + " factors" + ( interceptFactor == null ? "" : " with intercept treated as factor" ) + ( interactionFactorLists.isEmpty() ? "" : " with interaction" ) - + ( subsetFactorValue == null ? "" : "Using subset " + bioAssaySet + " subset value= " + subsetFactorValue ) ); + + ( subsetFactorValue == null ? "" : " Using subset " + bioAssaySet + " subset value= " + subsetFactorValue ) ); expressionAnalysis.setSubsetFactorValue( subsetFactorValue ); Set resultSets = this @@ -1367,7 +1376,7 @@ private Map runAnalysis( final DoubleMatrix> f = Executors.newSingleThreadExecutor().submit( () -> { + Future> f = executorService.submit( () -> { StopWatch timer = new StopWatch(); timer.start(); LeastSquaresFit fit; diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceImpl.java index 68017a9183..da5e4e9780 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceImpl.java @@ -69,8 +69,8 @@ public MeanVarianceRelation create( ExpressionExperiment ee, boolean forceRecomp } ExpressionDataDoubleMatrix intensities = expressionDataMatrixService.getProcessedExpressionDataMatrix( ee ); - if ( intensities == null ) { - throw new IllegalStateException( "Could not locate intensity matrix for " + ee.getShortName() ); + if ( intensities == null || intensities.rows() == 0 ) { + throw new IllegalStateException( "Could not locate intensity matrix, or it was empty, for " + ee.getShortName() ); } QuantitationType qt = expressionExperimentService.getPreferredQuantitationType( ee ); @@ -83,6 +83,11 @@ public MeanVarianceRelation create( ExpressionExperiment ee, boolean forceRecomp log.warn( "Problem log transforming data. Check that the appropriate log scale is used. Mean-variance will be computed as is." ); } + if ( intensities.rows() < 3 ) { + // this data is pretty much useless altogether, so an exception is the right way to go. + throw new IllegalStateException( "Not enough data left after filtering to proceed (" + intensities.rows() + " rows for " + ee.getShortName() + ")" ); + } + mvr = expressionExperimentService.updateMeanVarianceRelation( ee, calculateMeanVariance( intensities ) ); auditTrailService.addUpdateEvent( ee, MeanVarianceUpdateEvent.class, "Mean-variance has been updated." ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/OutlierDetectionServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/OutlierDetectionServiceImpl.java index 1fb0724c8e..a1a31870ae 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/OutlierDetectionServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/OutlierDetectionServiceImpl.java @@ -54,7 +54,7 @@ public Collection getOutlierDetails( ExpressionExperiment ee ) { public Collection identifyOutliersByMedianCorrelation( ExpressionExperiment ee ) { DoubleMatrix cormat = sampleCoexpressionAnalysisService.loadBestMatrix( ee ); if ( cormat == null ) { - cormat = sampleCoexpressionAnalysisService.computeIfNecessary( ee ); + cormat = sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); } if ( cormat.rows() == 0 ) { OutlierDetectionServiceImpl.log.warn( "Correlation matrix is empty, cannot check for outliers" ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/PreprocessorServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/PreprocessorServiceImpl.java index e36367a1f5..9429f437d9 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/PreprocessorServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/PreprocessorServiceImpl.java @@ -248,7 +248,7 @@ private void processForPca( ExpressionExperiment ee ) throws SVDRelatedPreproces */ private void processForSampleCorrelation( ExpressionExperiment ee ) throws SampleCoexpressionRelatedPreprocessingException { try { - sampleCoexpressionAnalysisService.compute( ee ); + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); } catch ( RuntimeException e ) { auditTrailService.addUpdateEvent( ee, FailedSampleCorrelationAnalysisEvent.class, null, e ); throw new SampleCoexpressionRelatedPreprocessingException( ee, e ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/TwoChannelMissingValuesImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/TwoChannelMissingValuesImpl.java index 297874fd6a..cab485b9e4 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/TwoChannelMissingValuesImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/TwoChannelMissingValuesImpl.java @@ -108,6 +108,16 @@ public Collection computeMissingValues( ExpressionExper ee = expressionExperimentService.thawLite( ee ); Collection usefulQuantitationTypes = ExpressionDataMatrixBuilder .getUsefulQuantitationTypes( ee ); + + // check that we don't already have a missing value QT + for ( QuantitationType qt : usefulQuantitationTypes ) { + if ( StandardQuantitationType.PRESENTABSENT.equals(qt.getType()) ) { + log.warn( "This experiment already has a missing value quantitation type, no action will be taken and empty collection returned" ); + return new HashSet<>(); + } + } + + StopWatch timer = new StopWatch(); timer.start(); TwoChannelMissingValuesImpl.log.info( "Loading vectors ..." ); @@ -239,7 +249,7 @@ private Collection computeMissingValues( ExpressionExpe TwoChannelMissingValuesImpl.log.info( "Finished: " + count + " vectors examined for missing values" ); log.info( "Persisting " + results.size() + " vectors ... " ); - // saving twice is needed to get the QT filled in properly. + // saving twice is needed to get the QT filled in properly. ??Why?? source = expressionExperimentService.save( source ); source.getRawExpressionDataVectors().addAll( results ); source = expressionExperimentService.save( source ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/BatchConfoundUtils.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/BatchConfoundUtils.java index 4c8568933b..618a8dbe83 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/BatchConfoundUtils.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/BatchConfoundUtils.java @@ -175,6 +175,12 @@ private static Collection factorBatchConfoundTest( BioAssaySet ee factorValueIndexes.put( fv.getId(), index++ ); } + + if ( factorValueIndexes.size() < 2 ) { + // This can happen if we're looking at a subset by this factor + continue; // to the next factor + } + Map factorValueMembership = new HashMap<>(); for ( Long bmId : bmToFv.keySet() ) { diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ComBat.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ComBat.java index d592160a86..97cbb6ed2c 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ComBat.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ComBat.java @@ -71,7 +71,6 @@ public class ComBat { private final ObjectMatrix sampleInfo; private final DoubleMatrix data; - private boolean hasMissing = false; private int numSamples; private int numBatches; @@ -104,19 +103,26 @@ public class ComBat { */ private DoubleMatrix2D x; - public ComBat( DoubleMatrix data, ObjectMatrix sampleInfo ) { - if ( data.columns() < 4 ) { - throw new IllegalArgumentException( "Cannot run ComBat with fewer than 4 samples" ); - } + /** + * Constructor that can be used just for testing correctability (data is not provided) - FIXME refactor so it's not a constructor. + * @param sampleInfo + * @throws ComBatException + */ + public ComBat( ObjectMatrix sampleInfo ) throws ComBatException { + this.sampleInfo = sampleInfo; + solver = new Algebra(); + computeDesignMatrix(); + this.data = null; + } + + public ComBat( DoubleMatrix data, ObjectMatrix sampleInfo ) throws ComBatException { this.data = data; this.sampleInfo = sampleInfo; solver = new Algebra(); y = new DenseDoubleMatrix2D( data.asArray() ); this.initPartA(); - // DesignMatrix dm = new DesignMatrix( sampleInfo ); - // this.x = dm.getMatrix(); x = this.computeDesignMatrix(); } @@ -133,8 +139,7 @@ public DoubleMatrix2D getDesignMatrix() { */ public void plot( String filePrefix ) { - if ( this.gammaHat == null ) - throw new IllegalArgumentException( "You must call 'run' first" ); + if ( this.gammaHat == null ) throw new IllegalArgumentException( "You must call 'run' first" ); /* * View the distribution of gammaHat, which we assume will have a normal distribution @@ -206,6 +211,10 @@ public DoubleMatrix2D run() throws ComBatException { */ public DoubleMatrix2D run( boolean parametric ) throws ComBatException { + if ( data.columns() < 4 ) { + throw new IllegalArgumentException( "Cannot run ComBat with fewer than 4 samples" ); + } + StopWatch timer = new StopWatch(); timer.start(); @@ -228,11 +237,9 @@ public DoubleMatrix2D run( boolean parametric ) throws ComBatException { gammaBar = new DoubleArrayList(); t2 = new DoubleArrayList(); for ( int batchIndex = 0; batchIndex < gammaHat.rows(); batchIndex++ ) { - double mean = DescriptiveWithMissing - .mean( new DoubleArrayList( gammaHat.viewRow( batchIndex ).toArray() ) ); + double mean = DescriptiveWithMissing.mean( new DoubleArrayList( gammaHat.viewRow( batchIndex ).toArray() ) ); gammaBar.add( mean ); - t2.add( DescriptiveWithMissing - .sampleVariance( new DoubleArrayList( gammaHat.viewRow( batchIndex ).toArray() ), mean ) ); + t2.add( DescriptiveWithMissing.sampleVariance( new DoubleArrayList( gammaHat.viewRow( batchIndex ).toArray() ), mean ) ); } // assertEquals( -0.092144, gammaBar.get( 0 ), 0.001 ); @@ -276,9 +283,9 @@ public DoubleMatrix2D run( boolean parametric ) throws ComBatException { /** * Special standardization: partial regression of covariates * - * @param b b - * @param A A - * @return double matrix 2d + * @param b the data matrix + * @param A the design matrix + * @return double matrix 2d representing the data with the covariates regressed out and standardized */ DoubleMatrix2D standardize( DoubleMatrix2D b, DoubleMatrix2D A ) { @@ -311,8 +318,7 @@ DoubleMatrix2D standardize( DoubleMatrix2D b, DoubleMatrix2D A ) { } varpooled = var; } else { - varpooled = y.copy().assign( solver.transpose( solver.mult( x, beta ) ), Functions.minus ) - .assign( Functions.pow( 2 ) ); + varpooled = y.copy().assign( solver.transpose( solver.mult( x, beta ) ), Functions.minus ).assign( Functions.pow( 2 ) ); DoubleMatrix2D scale = new DenseDoubleMatrix2D( numSamples, 1 ); scale.assign( 1.0 / numSamples ); varpooled = solver.mult( varpooled, scale ); @@ -355,9 +361,7 @@ private void writePlot( OutputStream os, XYSeries empirical, XYSeries theory ) { XYSeriesCollection xySeriesCollection = new XYSeriesCollection(); xySeriesCollection.addSeries( empirical ); xySeriesCollection.addSeries( theory ); - JFreeChart chart = ChartFactory - .createXYLineChart( "", "Magnitude", "Density", xySeriesCollection, PlotOrientation.VERTICAL, false, - false, false ); + JFreeChart chart = ChartFactory.createXYLineChart( "", "Magnitude", "Density", xySeriesCollection, PlotOrientation.VERTICAL, false, false, false ); chart.getXYPlot().setRangeGridlinesVisible( false ); chart.getXYPlot().setDomainGridlinesVisible( false ); XYItemRenderer renderer = chart.getXYPlot().getRenderer(); @@ -386,9 +390,7 @@ private void runParametric( final DoubleMatrix2D sdata, DoubleMatrix2D gammastar DoubleMatrix1D[] batchResults; - batchResults = this.itSol( batchData, gammaHat.viewRow( batchIndex ), deltaHat.viewRow( batchIndex ), - gammaBar.get( batchIndex ), t2.get( batchIndex ), aPrior.get( batchIndex ), - bPrior.get( batchIndex ) ); + batchResults = this.itSol( batchData, gammaHat.viewRow( batchIndex ), deltaHat.viewRow( batchIndex ), gammaBar.get( batchIndex ), t2.get( batchIndex ), aPrior.get( batchIndex ), bPrior.get( batchIndex ) ); for ( int j = 0; j < batchResults[0].size(); j++ ) { double v = batchResults[0].get( j ); @@ -430,8 +432,7 @@ public void run() { for ( int k = firstBatch; k < lastBatch; k++ ) { String batchId = batchIds[k]; DoubleMatrix2D batchData = ComBat.this.getBatchData( sdata, batchId ); - DoubleMatrix1D[] batchResults = ComBat.this - .nonParametricFit( batchData, gammaHat.viewRow( k ), deltaHat.viewRow( k ) ); + DoubleMatrix1D[] batchResults = ComBat.this.nonParametricFit( batchData, gammaHat.viewRow( k ), deltaHat.viewRow( k ) ); results.put( batchId, batchResults ); } } @@ -529,19 +530,36 @@ private DoubleMatrix2D computeDesignMatrix() { * Find the batch */ DesignMatrix d = null; - int batchFactorColumnIndex = sampleInfo.getColIndexByName( ComBat.BATCH_COLUMN_NAME ); - Object[] batchFactor = sampleInfo.getColumn( batchFactorColumnIndex ); + int batchFactorColumnIndex = this.sampleInfo.getColIndexByName( ComBat.BATCH_COLUMN_NAME ); + Object[] batchFactor = this.sampleInfo.getColumn( batchFactorColumnIndex ); if ( batchFactor != null ) { d = new DesignMatrix( batchFactor, 1, ComBat.BATCH_COLUMN_NAME ); } if ( d == null ) { throw new IllegalStateException( "No batch factor was found" ); } - ObjectMatrix sampleInfoWithoutBatchFactor = this - .getSampleInfoWithoutBatchFactor( batchFactorColumnIndex ); + ObjectMatrix sampleInfoWithoutBatchFactor = this.getSampleInfoWithoutBatchFactor( batchFactorColumnIndex ); + + // Check if the experimental design is going to be usable. + DesignMatrix nonBatchFactorDesign = new DesignMatrix( sampleInfoWithoutBatchFactor ); + int nonbatchrank = solver.rank( nonBatchFactorDesign.getDoubleMatrix() ); + if ( nonbatchrank < nonBatchFactorDesign.getDoubleMatrix().columns() ) { + /* + FIXME If this is because of duplicate columns, we _could_ try to fix it. + */ + throw new ComBatException( "Non-batch factor part of the model matrix is not of full rank (Rank " + nonbatchrank + " < " + nonBatchFactorDesign.getDoubleMatrix().columns() + " columns); batch correction cannot proceed" ); + } d.add( sampleInfoWithoutBatchFactor ); design = d.getDoubleMatrix(); + + // guard against problems. + int ranka = solver.rank( design ); + if ( ranka < design.columns() ) { + // if we get here, it probably means there is a confound between the batches and the other factors. + throw new ComBatException( "Model matrix is not of full rank (Rank " + ranka + " < " + design.columns() + " columns); batch correction cannot proceed" ); + } + return design; } @@ -590,16 +608,14 @@ private DoubleMatrix2D getBatchDesign( String batchId ) { } private ObjectMatrix getSampleInfoWithoutBatchFactor( int batchFactorColumnIndex ) { - ObjectMatrix sampleInfoWithoutBatchFactor = new ObjectMatrixImpl<>( sampleInfo.rows(), - sampleInfo.columns() - 1 ); + ObjectMatrix sampleInfoWithoutBatchFactor = new ObjectMatrixImpl<>( sampleInfo.rows(), sampleInfo.columns() - 1 ); boolean warned = false; int r = 0; for ( int i = 0; i < sampleInfo.rows(); i++ ) { int c = 0; for ( int j = 0; j < sampleInfo.columns(); j++ ) { - if ( j == batchFactorColumnIndex ) - continue; + if ( j == batchFactorColumnIndex ) continue; if ( i == 0 ) { sampleInfoWithoutBatchFactor.addColumnName( sampleInfo.getColName( j ) ); } @@ -655,8 +671,7 @@ private void initPartA() { */ for ( String batchId : batches.keySet() ) { if ( batches.get( batchId ).size() < 2 ) { - throw new IllegalArgumentException( - "Batch correction not possible with less than 2 samples in any batch. Consider combining batches." ); + throw new IllegalArgumentException( "Batch correction not possible with less than 2 samples in any batch. Consider combining batches." ); } } @@ -664,8 +679,7 @@ private void initPartA() { numProbes = y.rows(); } - private DoubleMatrix1D[] itSol( DoubleMatrix2D matrix, DoubleMatrix1D gHat, DoubleMatrix1D dHat, double gbar, - double t2b, double a, double b ) throws ComBatException { + private DoubleMatrix1D[] itSol( DoubleMatrix2D matrix, DoubleMatrix1D gHat, DoubleMatrix1D dHat, double gbar, double t2b, double a, double b ) throws ComBatException { DoubleMatrix1D n = this.rowNonMissingCounts( matrix ); DoubleMatrix1D gold = gHat; @@ -681,11 +695,9 @@ private DoubleMatrix1D[] itSol( DoubleMatrix2D matrix, DoubleMatrix1D gHat, Doub DoubleMatrix1D sum2 = this.stepSum( matrix, gnew ); DoubleMatrix1D dnew = this.postVar( sum2, n, a, b ); - DoubleMatrix1D gnewtmp = gnew.copy().assign( gold, Functions.minus ).assign( Functions.abs ) - .assign( gold, Functions.div ); + DoubleMatrix1D gnewtmp = gnew.copy().assign( gold, Functions.minus ).assign( Functions.abs ).assign( gold, Functions.div ); - DoubleMatrix1D dnewtmp = dnew.copy().assign( dold, Functions.minus ).assign( Functions.abs ) - .assign( dold, Functions.div ); + DoubleMatrix1D dnewtmp = dnew.copy().assign( dold, Functions.minus ).assign( Functions.abs ).assign( dold, Functions.div ); double gnewmax; double dnewmax; if ( hasMissing ) { @@ -706,9 +718,7 @@ private DoubleMatrix1D[] itSol( DoubleMatrix2D matrix, DoubleMatrix1D gHat, Doub * For certain data sets, we just flail around; for example if there are only two samples. This is a * bailout for exceptional circumstances. */ - throw new ComBatException( - "Failed to converge within " + MAXITERS + " iterations, last delta was " + String - .format( "%.2g", change ) ); + throw new ComBatException( "Failed to converge within " + MAXITERS + " iterations, last delta was " + String.format( "%.2g", change ) ); } } @@ -740,8 +750,7 @@ private DoubleMatrix1D[] nonParametricFit( DoubleMatrix2D matrix, DoubleMatrix1D double sumdLH = 0.0; for ( int j = 0; j < matrix.rows(); j++ ) { - if ( j == i ) - continue; + if ( j == i ) continue; double g = gHat.getQuick( j ); double d = dHat.getQuick( j ); @@ -756,8 +765,7 @@ private DoubleMatrix1D[] nonParametricFit( DoubleMatrix2D matrix, DoubleMatrix1D double LH = ( 1.0 / Math.pow( twopi * d, no2 ) ) * Math.exp( -sum2 / ( 2 * d ) ); - if ( Double.isNaN( LH ) ) - continue; + if ( Double.isNaN( LH ) ) continue; double gLH = g * LH; double dLH = d * LH; @@ -778,12 +786,10 @@ private DoubleMatrix1D[] nonParametricFit( DoubleMatrix2D matrix, DoubleMatrix1D return new DoubleMatrix1D[] { gstar, dstar }; } - private DoubleMatrix1D postMean( DoubleMatrix1D ghat, double gbar, DoubleMatrix1D n, DoubleMatrix1D dstar, - double t2b ) { + private DoubleMatrix1D postMean( DoubleMatrix1D ghat, double gbar, DoubleMatrix1D n, DoubleMatrix1D dstar, double t2b ) { DoubleMatrix1D result = new DenseDoubleMatrix1D( ghat.size() ); for ( int i = 0; i < ghat.size(); i++ ) { - result.set( i, ( t2b * n.get( i ) * ghat.get( i ) + dstar.get( i ) * gbar ) / ( t2b * n.get( i ) + dstar - .get( i ) ) ); + result.set( i, ( t2b * n.get( i ) * ghat.get( i ) + dstar.get( i ) * gbar ) / ( t2b * n.get( i ) + dstar.get( i ) ) ); } return result; } @@ -807,8 +813,7 @@ private DoubleMatrix2D rawAdjust( DoubleMatrix2D sdata, DoubleMatrix2D gammastar DoubleMatrix2D Xbb = this.getBatchDesign( batchId ); - DoubleMatrix2D adjustedBatch = batchData.copy() - .assign( solver.transpose( solver.mult( Xbb, gammastar ) ), Functions.minus ); + DoubleMatrix2D adjustedBatch = batchData.copy().assign( solver.transpose( solver.mult( Xbb, gammastar ) ), Functions.minus ); DoubleMatrix1D deltaStarRow = deltastar.viewRow( batchNum ); deltaStarRow.assign( Functions.sqrt ); @@ -849,8 +854,7 @@ private DoubleMatrix2D restoreScale( DoubleMatrix2D adjustedData ) { private DoubleMatrix1D rowNonMissingCounts( DoubleMatrix2D matrix ) { DoubleMatrix1D result = new DenseDoubleMatrix1D( matrix.rows() ); for ( int i = 0; i < matrix.rows(); i++ ) { - result.set( i, DescriptiveWithMissing - .sizeWithoutMissingValues( new DoubleArrayList( matrix.viewRow( i ).toArray() ) ) ); + result.set( i, DescriptiveWithMissing.sizeWithoutMissingValues( new DoubleArrayList( matrix.viewRow( i ).toArray() ) ) ); } return result; } @@ -871,8 +875,7 @@ private DoubleMatrix1D stepSum( DoubleMatrix2D matrix, DoubleMatrix1D gnew ) { * subtract column gnew from each column of data; square; then sum over each row. */ - DoubleMatrix2D deltas = matrix.copy().assign( ( s.mult( s.transpose( g ), a ) ), Functions.minus ) - .assign( Functions.square ); + DoubleMatrix2D deltas = matrix.copy().assign( ( s.mult( s.transpose( g ), a ) ), Functions.minus ).assign( Functions.square ); DoubleMatrix1D sumsq = new DenseDoubleMatrix1D( deltas.rows() ); sumsq.assign( 0.0 ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ExpressionExperimentBatchCorrectionServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ExpressionExperimentBatchCorrectionServiceImpl.java index 9f9948ba07..ecbd85d2c4 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ExpressionExperimentBatchCorrectionServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/batcheffects/ExpressionExperimentBatchCorrectionServiceImpl.java @@ -24,7 +24,9 @@ import ubic.basecode.dataStructure.matrix.ObjectMatrix; import ubic.basecode.dataStructure.matrix.ObjectMatrixImpl; import ubic.basecode.math.MatrixStats; +import ubic.basecode.math.linearmodels.DesignMatrix; import ubic.basecode.util.FileTools; +import ubic.gemma.core.analysis.expression.diff.LinearModelAnalyzer; import ubic.gemma.core.analysis.util.ExperimentalDesignUtils; import ubic.gemma.core.datastructure.matrix.ExpressionDataDoubleMatrix; import ubic.gemma.model.common.description.Characteristic; @@ -34,6 +36,7 @@ import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; import ubic.gemma.model.expression.biomaterial.BioMaterial; import ubic.gemma.model.expression.designElement.CompositeSequence; +import ubic.gemma.model.expression.experiment.BatchEffectType; import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.model.expression.experiment.FactorValue; @@ -65,20 +68,19 @@ public class ExpressionExperimentBatchCorrectionServiceImpl implements Expressio @Override public boolean checkCorrectability( ExpressionExperiment ee ) { -// for ( QuantitationType qt : expressionExperimentService.getQuantitationTypes( ee ) ) { -// if ( qt.getIsBatchCorrected() ) { // this avoids batch correcting when we don't need to -// ExpressionExperimentBatchCorrectionServiceImpl.log -// .info( "Experiment already has a batch-corrected quantitation type: " + ee + ": " + qt ); -// return false; -// } -// } - ExperimentalFactor batch = this.getBatchFactor( ee ); if ( batch == null ) { ExpressionExperimentBatchCorrectionServiceImpl.log.info( "No batch factor found: " + ee ); return false; } + BatchEffectType bet = expressionExperimentService.getBatchEffect( ee ); + if ( BatchEffectType.NO_BATCH_EFFECT_SUCCESS.equals( bet ) || BatchEffectType.SINGLE_BATCH_SUCCESS.equals( bet ) ) { + ExpressionExperimentBatchCorrectionServiceImpl.log.info( "Experiment does not require batch correction as " + + "batch effect is negligible or it's a single batch: " + ee ); + return false; + } + if ( expressionExperimentService.getArrayDesignsUsed( ee ).size() > 1 ) { log.info( String.format( "%s cannot be batch-corrected: multiplatform; you must switch/merge first.", ee ) ); return false; @@ -111,10 +113,6 @@ public boolean checkCorrectability( ExpressionExperiment ee ) { } } } - /* - * consider merging batches. - we already do this when we create the batch factor, so in general batches should - * always have at least 2 samples - */ for ( Long batchId : batches.keySet() ) { if ( batches.get( batchId ) < 2 ) { ExpressionExperimentBatchCorrectionServiceImpl.log @@ -124,6 +122,17 @@ public boolean checkCorrectability( ExpressionExperiment ee ) { } } + /* + Get the experimental design matrix we would use for batch correction. If this is not full rank we can't proceed. + */ + ObjectMatrix design = this.getDesign( ee ); + ObjectMatrix designU = this.convertFactorValuesToStrings( design ); + try { + new ComBat( designU ); // without data, just to check + } catch ( ComBatException c ) { // probably because it's not full rank. + log.info( c.getMessage() ); + return false; + } return true; } @@ -144,10 +153,41 @@ public ExpressionDataDoubleMatrix comBat( ExpressionDataDoubleMatrix originalDat return null; } - ObjectMatrix design = this.getDesign( ee, originalDataMatrix ); + ExpressionDataDoubleMatrix finalMatrix = removeOutliers( originalDataMatrix, ee ); + + ObjectMatrix design = this.getDesign( ee, finalMatrix ); + + return this.doComBat( ee, finalMatrix, design ); + + } + + /** + * Remove outlier samples from the data matrix, based on outliers that were flagged in the experiment (not just candidate outliers) + * @param originalDataMatrix + * @param ee + * @return the original matrix, or if outliers were present, a new matrix with the outliers removed + */ + public static ExpressionDataDoubleMatrix removeOutliers( ExpressionDataDoubleMatrix originalDataMatrix, ExpressionExperiment ee ) { + + List columnsToKeep = new ArrayList<>(); + for ( BioAssay ba : ee.getBioAssays() ) { + if ( !ba.getIsOutlier() ) { + + /* + Find the index of this bioassay in the originalDataMatrix + */ + columnsToKeep.add( ba.getSampleUsed() ); - return this.doComBat( ee, originalDataMatrix, design ); + } else { + log.info( "Dropping outlier sample: " + ba + " from batch correction" ); + } + } + ExpressionDataDoubleMatrix finalMatrix = originalDataMatrix; + if ( columnsToKeep.size() < originalDataMatrix.columns() ) { + finalMatrix = new ExpressionDataDoubleMatrix( originalDataMatrix, columnsToKeep, LinearModelAnalyzer.createBADMap( columnsToKeep ) ); + } + return finalMatrix; } @Override @@ -212,7 +252,8 @@ private ObjectMatrix convertFactorValuesToStrings( return designU; } - private ExpressionDataDoubleMatrix doComBat( ExpressionExperiment ee, ExpressionDataDoubleMatrix originalDataMatrix, + private ExpressionDataDoubleMatrix doComBat( ExpressionExperiment ee, ExpressionDataDoubleMatrix + originalDataMatrix, ObjectMatrix design ) { ObjectMatrix designU = this.convertFactorValuesToStrings( design ); DoubleMatrix matrix = originalDataMatrix.getMatrix(); @@ -239,7 +280,8 @@ private ExpressionDataDoubleMatrix doComBat( ExpressionExperiment ee, Expression try { results = comBat.run( true ); // false: NONPARAMETRIC } catch ( ComBatException e ) { - throw new IllegalStateException( "ComBat failed likely due to confounds between batching and other factors: " + e.getMessage(), e ); + log.error( e.getMessage() ); + return null; } // note these plots always reflect the parametric setup. @@ -274,13 +316,18 @@ private ExpressionDataDoubleMatrix doComBat( ExpressionExperiment ee, Expression return correctedExpressionDataMatrix; } + + private ObjectMatrix getDesign( ExpressionExperiment ee ) { + return this.getDesign( ee, null ); + } + /** * Extract sample information, format into something ComBat can use. * * Certain factors are removed at this stage, notably "DE_Exclude/Include" factors. * * @param ee - * @param mat + * @param mat only used to get sample ordering? * @return design matrix */ private ObjectMatrix getDesign( ExpressionExperiment ee, @@ -291,8 +338,13 @@ private ObjectMatrix getDesign( Express /* remove experimental factors that are for DE_Exclude */ List retainedFactors = experimentalFactors.stream().filter( ef -> retainForBatchCorrection( ef ) ).collect( Collectors.toList() ); - List orderedSamples = ExperimentalDesignUtils.getOrderedSamples( mat, retainedFactors ); - + List orderedSamples = new ArrayList<>(); + if ( mat == null ) { + // we're using this in a mode where we don't care about the order. + orderedSamples = ee.getBioAssays().stream().map( BioAssay::getSampleUsed ).collect( Collectors.toList() ); + } else { + orderedSamples = ExperimentalDesignUtils.getOrderedSamples( mat, retainedFactors ); + } return ExperimentalDesignUtils.sampleInfoMatrix( retainedFactors, orderedSamples, ExperimentalDesignUtils.getBaselineConditions( orderedSamples, retainedFactors ) ); } @@ -303,7 +355,7 @@ private ObjectMatrix getDesign( Express * @return true if the factor should be used in the model for batch correction */ private boolean retainForBatchCorrection( ExperimentalFactor ef ) { - if ( ef.getCategory().getCategoryUri() != null && ef.getCategory().getCategoryUri().equals( COLLECTION_OF_MATERIAL_URI ) ) { + if ( ef.getCategory() != null && COLLECTION_OF_MATERIAL_URI.equals( ef.getCategory().getCategoryUri() ) ) { for ( FactorValue fv : ef.getFactorValues() ) { for ( Characteristic c : fv.getCharacteristics() ) { if ( c.getValueUri() != null && ( c.getValueUri().equals( DE_EXCLUDE_URI ) || c.getValueUri().equals( DE_INCLUDE_URI ) ) ) { @@ -313,6 +365,7 @@ private boolean retainForBatchCorrection( ExperimentalFactor ef ) { } } } + log.info( "Retaining factor " + ef.getName() + " for batch correction model" ); return true; } @@ -346,7 +399,8 @@ private QuantitationType makeNewQuantitationType( QuantitationType oldQt ) { * * @return updated designU */ - private ObjectMatrix orderMatrix( DoubleMatrix matrix, + private ObjectMatrix orderMatrix + ( DoubleMatrix matrix, ObjectMatrix designU ) { ObjectMatrix result = new ObjectMatrixImpl<>( designU.rows(), designU.columns() ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/filter/ExpressionExperimentFilter.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/filter/ExpressionExperimentFilter.java index a9e4a2f32c..115e1307b9 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/filter/ExpressionExperimentFilter.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/filter/ExpressionExperimentFilter.java @@ -108,6 +108,8 @@ public static ExpressionDataDoubleMatrix tooFewDistinctValues( ExpressionDataDou } /** + * @param matrix the data matrix + * @param threshold fraction of values that must be distinct. Thus if set to 0.5, a vector of 10 values must have at 5 distinct values. * @param tolerance differences smaller than this are counted as "the same value". */ public static ExpressionDataDoubleMatrix tooFewDistinctValues( ExpressionDataDoubleMatrix matrix, diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/svd/SVDServiceHelperImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/svd/SVDServiceHelperImpl.java index b81392d5b7..86a706b52b 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/svd/SVDServiceHelperImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/preprocess/svd/SVDServiceHelperImpl.java @@ -37,10 +37,7 @@ import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; import ubic.gemma.model.expression.biomaterial.BioMaterial; import ubic.gemma.model.expression.designElement.CompositeSequence; -import ubic.gemma.model.expression.experiment.ExperimentalFactor; -import ubic.gemma.model.expression.experiment.ExpressionExperiment; -import ubic.gemma.model.expression.experiment.ExpressionExperimentValueObject; -import ubic.gemma.model.expression.experiment.FactorValue; +import ubic.gemma.model.expression.experiment.*; import ubic.gemma.persistence.service.analysis.expression.pca.PrincipalComponentAnalysisService; import ubic.gemma.persistence.service.common.auditAndSecurity.AuditTrailService; import ubic.gemma.persistence.service.expression.bioAssayData.ProcessedExpressionDataVectorService; @@ -100,28 +97,34 @@ public static void populateBMFMap( Map> bi for ( FactorValue fv : bm.getFactorValues() ) { ExperimentalFactor experimentalFactor = fv.getExperimentalFactor(); double valueToStore; - if ( fv.getMeasurement() != null ) { - switch ( fv.getMeasurement().getRepresentation() ) { - case INT: - valueToStore = Integer.parseInt( fv.getMeasurement().getValue() ); - break; - case LONG: - valueToStore = Long.parseLong( fv.getMeasurement().getValue() ); - break; - case DOUBLE: - valueToStore = Double.parseDouble( fv.getMeasurement().getValue() ); - break; - default: - // non-numerical measurement can be treated as categorical - valueToStore = fv.getId().doubleValue(); + if ( experimentalFactor.getType().equals( FactorType.CONTINUOUS ) ) { + if ( fv.getMeasurement() != null && fv.getMeasurement().getValue() != null ) { // continuous + try { + switch ( fv.getMeasurement().getRepresentation() ) { + case INT: + valueToStore = Integer.parseInt( fv.getMeasurement().getValue() ); + break; + case LONG: + valueToStore = Long.parseLong( fv.getMeasurement().getValue() ); + break; + case DOUBLE: + valueToStore = Double.parseDouble( fv.getMeasurement().getValue() ); + break; + default: + // non-numerical measurement can be treated as categorical + valueToStore = fv.getId().doubleValue(); + } + } catch ( NumberFormatException e ) { + valueToStore = Double.NaN; // due to a missing value + } + } else { + valueToStore =Double.NaN; } } else { - /* - * This is a hack so we don't need special datastructures for - * continuous and categorical. We're storing the ID but as a double. - */ + // for categorical factors, we use the ids as dummy values. valueToStore = fv.getId().doubleValue(); } + bioMaterialFactorMap .computeIfAbsent( experimentalFactor, k -> new HashMap<>() ) .put( bm.getId(), valueToStore ); @@ -506,7 +509,7 @@ private void analyzeComponent( SVDValueObject svo, int componentNumber, DoubleMa svo.setPCFactorCorrelationPval( componentNumber, ef, CorrelationStats.spearmanPvalue( factorCorrelation, eigenGeneWithoutMissing.size() ) ); } else { - // one-way ANOVA on ranks. + // one-way ANOVA on ranks. This test is pretty underpowered. double kwPVal = KruskalWallis.test( eigenGeneWithoutMissing, groupings ); svo.setPCFactorCorrelationPval( componentNumber, ef, kwPVal ); @@ -516,19 +519,20 @@ private void analyzeComponent( SVDValueObject svo, int componentNumber, DoubleMa double corrPvalue = CorrelationStats .spearmanPvalue( factorCorrelation, eigenGeneWithoutMissing.size() ); assert Math.abs( factorCorrelation ) < 1.0 + 1e-2; // sanity. + /* - * Avoid storing a pvalue, as it's hard to compare. If the regular linear correlation is strong, + * If the regular linear correlation is strong, * then we should just use that -- basically, it means the order we have the groups happens to be a - * good one. Of course we could just store pvalues, but that's not easy to use either. + * good one. */ if ( corrPvalue <= kwPVal ) { svo.setPCFactorCorrelation( componentNumber, ef, factorCorrelation ); + svo.setPCFactorCorrelationPval( componentNumber, ef, corrPvalue); } else { // hack. A bit like turning pvalues into prob it double approxCorr = CorrelationStats .correlationForPvalue( kwPVal, eigenGeneWithoutMissing.size() ); svo.setPCFactorCorrelation( componentNumber, ef, approxCorr ); - } } diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportService.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportService.java index 639a904037..e563397c84 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportService.java @@ -66,4 +66,6 @@ public interface ArrayDesignReportService { String getLastGeneMappingEvent( Long id ); + String getCreateDate( Long id ); + } \ No newline at end of file diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportServiceImpl.java index 046184861a..61b3d626e8 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/ArrayDesignReportServiceImpl.java @@ -87,6 +87,7 @@ public void generateAllArrayDesignReport() { adVo.setNumProbesToGenes( Long.toString( numCsGenes ) ); adVo.setNumGenes( Long.toString( numGenes ) ); adVo.setDateCached( timestamp ); + // remove file first File f = new File( ArrayDesignReportServiceImpl.HOME_DIR + File.separatorChar + ArrayDesignReportServiceImpl.ARRAY_DESIGN_REPORT_DIR + File.separatorChar @@ -97,10 +98,10 @@ public void generateAllArrayDesignReport() { return; } } - try (FileOutputStream fos = new FileOutputStream( ArrayDesignReportServiceImpl.HOME_DIR + File.separatorChar + try ( FileOutputStream fos = new FileOutputStream( ArrayDesignReportServiceImpl.HOME_DIR + File.separatorChar + ArrayDesignReportServiceImpl.ARRAY_DESIGN_REPORT_DIR + File.separatorChar + ArrayDesignReportServiceImpl.ARRAY_DESIGN_SUMMARY ); - ObjectOutputStream oos = new ObjectOutputStream( fos )) { + ObjectOutputStream oos = new ObjectOutputStream( fos ) ) { oos.writeObject( adVo ); } catch ( Throwable e ) { // cannot write to file. Just fail gracefully. @@ -172,8 +173,8 @@ public void generateArrayDesignReport( ArrayDesignValueObject adVo ) { } } - try (FileOutputStream fos = new FileOutputStream( reportFileName ); - ObjectOutputStream oos = new ObjectOutputStream( fos )) { + try ( FileOutputStream fos = new FileOutputStream( reportFileName ); + ObjectOutputStream oos = new ObjectOutputStream( fos ) ) { oos.writeObject( adVo ); } catch ( Throwable e ) { ArrayDesignReportServiceImpl.log.error( "Cannot write to file: " + reportFileName, e ); @@ -207,7 +208,7 @@ public ArrayDesignValueObject getSummaryObject( Long id ) { + File.separatorChar + ArrayDesignReportServiceImpl.ARRAY_DESIGN_REPORT_FILE_NAME_PREFIX + "." + id ); if ( f.exists() ) { - try (FileInputStream fis = new FileInputStream( f ); ObjectInputStream ois = new ObjectInputStream( fis )) { + try ( FileInputStream fis = new FileInputStream( f ); ObjectInputStream ois = new ObjectInputStream( fis ) ) { adVo = ( ArrayDesignValueObject ) ois.readObject(); @@ -230,7 +231,7 @@ public ArrayDesignValueObject getSummaryObject() { + ArrayDesignReportServiceImpl.ARRAY_DESIGN_REPORT_DIR + File.separatorChar + ArrayDesignReportServiceImpl.ARRAY_DESIGN_SUMMARY ); if ( f.exists() ) { - try (FileInputStream fis = new FileInputStream( f ); ObjectInputStream ois = new ObjectInputStream( fis )) { + try ( FileInputStream fis = new FileInputStream( f ); ObjectInputStream ois = new ObjectInputStream( fis ) ) { adVo = ( ArrayDesignValueObject ) ois.readObject(); } catch ( Throwable e ) { return null; @@ -293,6 +294,7 @@ public void fillEventInformation( Collection adVos ) { Map sequenceUpdateEvents = events.get( ArrayDesignSequenceUpdateEvent.class ); Map sequenceAnalysisEvents = events.get( ArrayDesignSequenceAnalysisEvent.class ); Map repeatAnalysisEvents = events.get( ArrayDesignRepeatAnalysisEvent.class ); + Map creationEvents = auditEventService.getCreateEvents( arrayDesigns ); for ( ArrayDesignValueObject adVo : adVos ) { @@ -326,6 +328,12 @@ public void fillEventInformation( Collection adVos ) { } } + if ( creationEvents.containsKey( ad ) ) { + AuditEvent event = creationEvents.get( ad ); + if ( event != null ) { + adVo.setCreateDate( event.getDate() ); + } + } } watch.stop(); @@ -404,7 +412,18 @@ public String getLastRepeatMaskEvent( Long id ) { @Override public String getLastGeneMappingEvent( Long id ) { return this.getLastEvent( id, ArrayDesignGeneMappingEvent.class ); + } + + @Override + public String getCreateDate( Long id ) { + ArrayDesign ad = arrayDesignService.load( id ); + + if ( ad == null ) + return ""; + List events = auditEventService.getEvents( ad ); + AuditEvent lastEvent = events.get( 0 ); + return DateFormatUtils.format( lastEvent.getDate(), "yyyy.MMM.dd hh:mm aa" ); } private String getLastEvent( Long id, Class eventType ) { diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/DatabaseViewGeneratorImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/DatabaseViewGeneratorImpl.java index f98c5769f5..14d022234c 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/report/DatabaseViewGeneratorImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/report/DatabaseViewGeneratorImpl.java @@ -144,7 +144,7 @@ private void generateDatasetTissueView( Integer limit, Collection> blatResultCoun String targetStarts = ( String ) row[17]; Long queryId = ( ( BigInteger ) row[18] ).longValue(); - int hash = 1; - int prime = 31; - hash = prime * hash + chromId.hashCode(); - hash = prime * hash + targetStart.hashCode(); - hash = prime * hash + targetEnd.hashCode(); - hash = prime * hash + targetStarts.hashCode(); - hash = prime * hash + queryId.hashCode(); + int hash = Objects.hash( chromId, targetStart, targetEnd, targetStarts, queryId ); EntityUtils.populateMapSet( blatResultCount, csId, hash ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileService.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileService.java index b585f60853..434a54dbe7 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileService.java @@ -25,17 +25,21 @@ import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.persistence.util.Settings; +import javax.annotation.Nullable; +import javax.annotation.ParametersAreNonnullByDefault; import java.io.File; import java.io.IOException; import java.io.Writer; import java.util.Collection; import java.util.List; import java.util.Map; +import java.util.Optional; /** * @author paul */ @SuppressWarnings("unused") // Possible external use +@ParametersAreNonnullByDefault public interface ExpressionDataFileService extends TsvFileService { String DATA_ARCHIVE_FILE_SUFFIX = ".zip"; @@ -56,7 +60,7 @@ void analysisResultSetsToString( Collection results List analysisResultSetToString( ExpressionAnalysisResultSet ears, Map geneAnnotations, StringBuilder buf, Map probe2String, - List sortedFirstColumnOfResults ); + @Nullable List sortedFirstColumnOfResults ); /** * Delete any existing coexpression, data, or differential expression data files. @@ -119,12 +123,10 @@ List analysisResultSetToString( Expression * @param compress compress? * @param fileName file name * @param filtered fitlered? - * @return file + * @return file, or empty if the experiment has no processed expression data * @throws IOException when there are IO problems */ - @SuppressWarnings("UnusedReturnValue") - // Possible external use - File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, boolean compress ) + Optional writeProcessedExpressionDataFile( ExpressionExperiment ee, boolean filtered, String fileName, boolean compress ) throws IOException, FilteringException; /** @@ -134,7 +136,7 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, * To write to a string, consider using {@link java.io.StringWriter}. * * @param ee the expression experiment - * @param qt a quantitation type to use, otherwise the preferred one is picked + * @param qt a quantitation type to use * @param writer the destination for the raw expression data * @throws IOException if operations with the writer fails */ @@ -150,7 +152,7 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, * @param writer the destination for the raw expression data * @throws IOException if operations with the writer fails */ - void writeProcessedExpressionData( ExpressionExperiment ee, QuantitationType qt, Writer writer ) throws IOException; + void writeProcessedExpressionData( ExpressionExperiment ee, Writer writer ) throws IOException; /** * Write or located the coexpression data file for a given experiment @@ -159,7 +161,7 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, * @param forceWrite whether to force write * @return file */ - File writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean forceWrite ); + Optional writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean forceWrite ); /** * Locate or create a data file containing the 'preferred and masked' expression data matrix, with filtering for low @@ -170,19 +172,19 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, * @param filtered filtered * @param forceWrite force re-write even if file already exists and is up to date. * @param ee the experiment - * @return file + * @return file, or empty if the experiment has no processed vectors */ - File writeOrLocateDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException; + Optional writeOrLocateProcessedDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException; /** * Locate or create a new data file for the given quantitation type. The output will include gene information if it * can be located from its own file. * * @param forceWrite To not return the existing file, but create it anew. - * @param type the quantitaion type + * @param type the quantitation type * @return file */ - File writeOrLocateDataFile( QuantitationType type, boolean forceWrite ); + File writeOrLocateRawExpressionDataFile( ExpressionExperiment ee, QuantitationType type, boolean forceWrite ); /** * Locate or create an experimental design file for a given experiment. @@ -205,14 +207,14 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, Collection writeOrLocateDiffExpressionDataFiles( ExpressionExperiment ee, boolean forceWrite ); /** - * @param filtered if the data should be filtered. - * @param ee the experiment - * @param forceWrite whether to force write - * @return file + * @see #writeOrLocateProcessedDataFile(ExpressionExperiment, boolean, boolean) */ - File writeOrLocateJSONDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException; + Optional writeOrLocateJSONProcessedExpressionDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException; - File writeOrLocateJSONDataFile( QuantitationType type, boolean forceWrite ); + /** + * @see #writeOrLocateRawExpressionDataFile(ExpressionExperiment, QuantitationType, boolean) + */ + File writeOrLocateJSONRawExpressionDataFile( ExpressionExperiment ee, QuantitationType type, boolean forceWrite ); void deleteDiffExArchiveFile( DifferentialExpressionAnalysis analysis ); @@ -229,5 +231,5 @@ File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, * @throws IOException when there was a problem during write */ void writeDiffExArchiveFile( BioAssaySet ee, DifferentialExpressionAnalysis analysis, - DifferentialExpressionAnalysisConfig config ) throws IOException; + @Nullable DifferentialExpressionAnalysisConfig config ) throws IOException; } \ No newline at end of file diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileServiceImpl.java index 2c37ab4911..9c1fde5c44 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataFileServiceImpl.java @@ -58,6 +58,8 @@ import ubic.gemma.persistence.util.EntityUtils; import ubic.gemma.persistence.util.Settings; +import javax.annotation.Nullable; +import javax.annotation.ParametersAreNonnullByDefault; import java.io.*; import java.nio.file.Paths; import java.util.*; @@ -74,6 +76,7 @@ * @author paul */ @Component +@ParametersAreNonnullByDefault public class ExpressionDataFileServiceImpl extends AbstractFileService implements ExpressionDataFileService { private static final Log log = LogFactory.getLog( ArrayDesignAnnotationServiceImpl.class.getName() ); @@ -142,12 +145,11 @@ public void analysisResultSetsToString( Collection @Override public List analysisResultSetToString( ExpressionAnalysisResultSet ears, Map geneAnnotations, StringBuilder buf, Map probe2String, - List sortedFirstColumnOfResults ) { + @Nullable List sortedFirstColumnOfResults ) { if ( sortedFirstColumnOfResults == null ) { // Sort P values in ears (because 1st column) sortedFirstColumnOfResults = new ArrayList<>( ears.getResults() ); - Collections.sort( sortedFirstColumnOfResults, - DifferentialExpressionAnalysisResultComparator.Factory.newInstance() ); + sortedFirstColumnOfResults.sort( DifferentialExpressionAnalysisResultComparator.Factory.newInstance() ); } // Generate a description of the factors involved "factor1_factor2", trying to be R-friendly @@ -234,7 +236,7 @@ public void deleteDiffExArchiveFile( DifferentialExpressionAnalysis analysis ) { @Override public File getDiffExpressionAnalysisArchiveFile( Long analysisId, boolean forceCreate ) { - DifferentialExpressionAnalysis analysis = this.differentialExpressionAnalysisService.load( analysisId ); + DifferentialExpressionAnalysis analysis = this.differentialExpressionAnalysisService.loadOrFail( analysisId ); return getDiffExpressionAnalysisArchiveFile( analysis, forceCreate ); } @@ -351,7 +353,7 @@ private File getNewestFile( File file ) { } @Override - public File writeDataFile( ExpressionExperiment ee, boolean filtered, String fileName, boolean compress ) + public Optional writeProcessedExpressionDataFile( ExpressionExperiment ee, boolean filtered, String fileName, boolean compress ) throws IOException, FilteringException { File f = new File( fileName ); return this.writeDataFile( ee, filtered, f, compress ); @@ -359,10 +361,13 @@ public File writeDataFile( ExpressionExperiment ee, boolean filtered, String fil @Override public void writeDiffExArchiveFile( BioAssaySet experimentAnalyzed, DifferentialExpressionAnalysis analysis, - DifferentialExpressionAnalysisConfig config ) throws IOException { + @Nullable DifferentialExpressionAnalysisConfig config ) throws IOException { Collection arrayDesigns = this.expressionExperimentService .getArrayDesignsUsed( experimentAnalyzed ); Map geneAnnotations = this.getGeneAnnotationsAsStrings( arrayDesigns ); + if ( analysis.getExperimentAnalyzed().getId() == null ) {// this can happen when using -nodb + analysis.getExperimentAnalyzed().setId( experimentAnalyzed.getId() ); + } String filename = this.getDiffExArchiveFileName( analysis ); File f = this.getOutputFile( filename ); @@ -419,12 +424,15 @@ public void writeRawExpressionData( ExpressionExperiment ee, QuantitationType qt @Override @Transactional(readOnly = true) - public void writeProcessedExpressionData( ExpressionExperiment ee, QuantitationType qt, Writer writer ) throws IOException { + public void writeProcessedExpressionData( ExpressionExperiment ee, Writer writer ) throws IOException { ee = expressionExperimentService.find( ee ); if ( ee == null ) { throw new IllegalArgumentException( "ExpressionExperiment has been removed." ); } - ExpressionDataDoubleMatrix matrix = expressionDataMatrixService.getProcessedExpressionDataMatrix( ee, qt ); + ExpressionDataDoubleMatrix matrix = expressionDataMatrixService.getProcessedExpressionDataMatrix( ee ); + if ( matrix == null ) { + throw new IllegalArgumentException( "ExpressionExperiment has no processed data vectors." ); + } Set ads = matrix.getDesignElements().stream() .map( CompositeSequence::getArrayDesign ) .collect( Collectors.toSet() ); @@ -432,7 +440,7 @@ public void writeProcessedExpressionData( ExpressionExperiment ee, QuantitationT } @Override - public File writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean forceWrite ) { + public Optional writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean forceWrite ) { ee = expressionExperimentService.thawLite( ee ); @@ -440,11 +448,14 @@ public File writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean File f = this.getOutputFile( this.getCoexpressionDataFilename( ee ) ); if ( !forceWrite && f.canRead() ) { ExpressionDataFileServiceImpl.log.info( f + " exists, not regenerating" ); - return f; + return Optional.of( f ); } - this.writeCoexpressionData( f, ee ); - return f; + if ( this.writeCoexpressionData( f, ee ) ) { + return Optional.of( f ); + } else { + return Optional.empty(); + } } catch ( IOException e ) { throw new RuntimeException( e ); } @@ -452,13 +463,13 @@ public File writeOrLocateCoexpressionDataFile( ExpressionExperiment ee, boolean } @Override - public File writeOrLocateDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException { + public Optional writeOrLocateProcessedDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException { try { File f = this.getOutputFile( ee, filtered ); Date check = expressionExperimentService.getLastArrayDesignUpdate( ee ); if ( this.checkFileOkToReturn( forceWrite, f, check ) ) { - return f; + return Optional.of( f ); } return this.writeDataFile( ee, filtered, f, true ); @@ -469,7 +480,7 @@ public File writeOrLocateDataFile( ExpressionExperiment ee, boolean forceWrite, } @Override - public File writeOrLocateDataFile( QuantitationType type, boolean forceWrite ) { + public File writeOrLocateRawExpressionDataFile( ExpressionExperiment ee, QuantitationType type, boolean forceWrite ) { try { File f = this.getOutputFile( type ); @@ -485,7 +496,7 @@ public File writeOrLocateDataFile( QuantitationType type, boolean forceWrite ) { Collection arrayDesigns = this.getArrayDesigns( vectors ); Map geneAnnotations = this.getGeneAnnotationsAsStringsByProbe( arrayDesigns ); - if ( vectors.size() == 0 ) { + if ( vectors.isEmpty() ) { ExpressionDataFileServiceImpl.log.warn( "No vectors for " + type ); return null; } @@ -533,27 +544,29 @@ public Collection writeOrLocateDiffExpressionDataFiles( ExpressionExperime } @Override - public File writeOrLocateJSONDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException { + public Optional writeOrLocateJSONProcessedExpressionDataFile( ExpressionExperiment ee, boolean forceWrite, boolean filtered ) throws FilteringException { try { File f = this.getOutputFile( ee, filtered ); if ( !forceWrite && f.canRead() ) { ExpressionDataFileServiceImpl.log.info( f + " exists, not regenerating" ); - return f; + return Optional.of( f ); } ExpressionDataFileServiceImpl.log.info( "Creating new JSON expression data file: " + f.getName() ); ExpressionDataDoubleMatrix matrix = this.getDataMatrix( ee, filtered ); - + if ( matrix == null ) { + return Optional.empty(); + } this.writeJson( f, matrix ); - return f; + return Optional.of( f ); } catch ( IOException e ) { throw new RuntimeException( e ); } } @Override - public File writeOrLocateJSONDataFile( QuantitationType type, boolean forceWrite ) { + public File writeOrLocateJSONRawExpressionDataFile( ExpressionExperiment ee, QuantitationType type, boolean forceWrite ) { try { File f = this.getJSONOutputFile( type ); @@ -566,7 +579,7 @@ public File writeOrLocateJSONDataFile( QuantitationType type, boolean forceWrite Collection vectors = rawAndProcessedExpressionDataVectorService.findAndThaw( type ); - if ( vectors.size() == 0 ) { + if ( vectors.isEmpty() ) { ExpressionDataFileServiceImpl.log.warn( "No vectors for " + type ); return null; } @@ -611,13 +624,27 @@ private String analysisResultSetWithContrastsToString( ExpressionAnalysisResultS for ( DifferentialExpressionAnalysisResult dear : resultSet.getResults() ) { StringBuilder rowBuffer = new StringBuilder(); - if ( geneAnnotations.isEmpty() ) { - rowBuffer.append( dear.getProbe().getName() ); - } else { - this.addGeneAnnotationsToLine( rowBuffer, dear, geneAnnotations ); +// if ( geneAnnotations.isEmpty() ) { +// rowBuffer.append( dear.getProbe().getName() ); +// } else { + this.addGeneAnnotationsToLine( rowBuffer, dear, geneAnnotations ); + // } + + /* + If there are no results for the DEAR then we wouldn't expect contrasts, so we just leave a blank. + */ + if ( dear.getPvalue() == null ) { + String contrastData = "\t\t"; + rowBuffer.append( contrastData ); + buf.append( rowBuffer ).append( '\n' ); + continue; } - assert dear.getContrasts().size() == 1; + + if ( dear.getContrasts().size() != 1 ) { + // + throw new IllegalStateException( "Expected exactly one contrast for continuous factor" ); + } ContrastResult contrast = dear.getContrasts().iterator().next(); @@ -642,7 +669,9 @@ private String analysisResultSetWithContrastsToString( ExpressionAnalysisResultS Collection usedFactorValueIds = new HashSet<>(); for ( DifferentialExpressionAnalysisResult dear : resultSet.getResults() ) { for ( ContrastResult contrast : dear.getContrasts() ) { - usedFactorValueIds.add( contrast.getFactorValue().getId() ); + if ( contrast.getFactorValue() != null ) { + usedFactorValueIds.add( contrast.getFactorValue().getId() ); + } } break; // only have to look at one. } @@ -690,7 +719,7 @@ private String analysisResultSetWithContrastsToString( ExpressionAnalysisResultS rowBuffer.append( s ); } - buf.append( rowBuffer.toString() ).append( '\n' ); + buf.append( rowBuffer ).append( '\n' ); } // resultSet.getResults() loop } @@ -733,7 +762,7 @@ private boolean checkFileOkToReturn( boolean forceWrite, File f, Date check ) { * @param analysis (might not be persistent) */ private String convertDiffExpressionAnalysisData( DifferentialExpressionAnalysis analysis, - Map geneAnnotations, DifferentialExpressionAnalysisConfig config ) { + Map geneAnnotations, @Nullable DifferentialExpressionAnalysisConfig config ) { if ( analysis.getId() != null ) analysis = differentialExpressionAnalysisService.thawFully( analysis ); Collection results = analysis.getResultSets(); @@ -756,7 +785,7 @@ private String convertDiffExpressionAnalysisData( DifferentialExpressionAnalysis * eneAnnotations */ private String convertDiffExpressionResultSetData( ExpressionAnalysisResultSet resultSet, - Map geneAnnotations, DifferentialExpressionAnalysisConfig config ) { + Map geneAnnotations, @Nullable DifferentialExpressionAnalysisConfig config ) { // Write header. // Write contrasts data. return this.makeDiffExpressionResultSetFileHeader( resultSet, geneAnnotations, config ) + this @@ -789,6 +818,7 @@ private String getDataFileName( ExpressionExperiment ee, String filteredAdd, Str return ee.getId() + "_" + FileTools.cleanForFileName( ee.getShortName() ) + "_expmat" + filteredAdd + suffix; } + @Nullable private ExpressionDataDoubleMatrix getDataMatrix( ExpressionExperiment ee, boolean filtered ) throws FilteringException { ee = expressionExperimentService.thawLite( ee ); ExpressionDataDoubleMatrix matrix; @@ -801,7 +831,7 @@ private ExpressionDataDoubleMatrix getDataMatrix( ExpressionExperiment ee, boole matrix = expressionDataMatrixService.getProcessedExpressionDataMatrix( ee ); } if ( matrix == null ) { - throw new RuntimeException( String.format( "%s has no processed expression vectors.", ee ) ); + log.warn( String.format( "%s has no processed expression vectors.", ee ) ); } return matrix; } @@ -860,12 +890,12 @@ private File getDiffExpressionAnalysisArchiveFile( DifferentialExpressionAnalysi return f; } - private String getFactorValueString( FactorValue fv ) { + private String getFactorValueString( @Nullable FactorValue fv ) { String result; if ( fv == null ) return "null"; - if ( fv.getCharacteristics() != null && fv.getCharacteristics().size() > 0 ) { + if ( fv.getCharacteristics() != null && !fv.getCharacteristics().isEmpty() ) { StringBuilder fvString = new StringBuilder(); for ( Characteristic c : fv.getCharacteristics() ) { fvString.append( c.getValue() ).append( "_" ); @@ -879,7 +909,7 @@ private String getFactorValueString( FactorValue fv ) { return "no_data"; // R-friendly, but no need to add "X" to the beginning since this is a suffix. - return result.replaceAll( "[\\W]+", "." ); + return result.replaceAll( "\\W+", "." ); } /** @@ -956,7 +986,7 @@ private String getOutputFilename( QuantitationType type ) { private String makeDiffExpressionFileHeader( DifferentialExpressionAnalysis analysis, Collection resultSets, Map geneAnnotations, - DifferentialExpressionAnalysisConfig config ) { + @Nullable DifferentialExpressionAnalysisConfig config ) { if ( analysis.getId() != null ) // It might not be a persistent analysis: using -nodb analysis = differentialExpressionAnalysisService.thaw( analysis ); @@ -983,7 +1013,7 @@ private String makeDiffExpressionFileHeader( DifferentialExpressionAnalysis anal } if ( config != null ) { - buf.append( config.toString() ); + buf.append( config ); } else if ( analysis.getProtocol() != null && StringUtils .isNotBlank( analysis.getProtocol().getDescription() ) ) { buf.append( analysis.getProtocol().getDescription() ); @@ -1027,7 +1057,7 @@ private String makeDiffExpressionFileHeader( DifferentialExpressionAnalysis anal } private String makeDiffExpressionResultSetFileHeader( ExpressionAnalysisResultSet resultSet, - Map geneAnnotations, DifferentialExpressionAnalysisConfig config ) { + Map geneAnnotations, @Nullable DifferentialExpressionAnalysisConfig config ) { StringBuilder buf = new StringBuilder(); BioAssaySet bas = resultSet.getAnalysis().getExperimentAnalyzed(); @@ -1100,8 +1130,7 @@ private String makeDiffExpressionResultSetFileHeader( ExpressionAnalysisResultSe /** * Loads the probe to probe coexpression link information for a given expression experiment and writes it to disk. */ - private void writeCoexpressionData( File file, ExpressionExperiment ee ) throws IOException { - + private boolean writeCoexpressionData( File file, ExpressionExperiment ee ) throws IOException { Taxon tax = expressionExperimentService.getTaxon( ee ); assert tax != null; @@ -1109,7 +1138,7 @@ private void writeCoexpressionData( File file, ExpressionExperiment ee ) throws if ( geneLinks.isEmpty() ) { log.warn( "No coexpression links for this experiment, file will not be created: " + ee ); - return; + return false; } ExpressionDataFileServiceImpl.log.info( "Creating new coexpression data file: " + file.getAbsolutePath() ); @@ -1139,20 +1168,23 @@ private void writeCoexpressionData( File file, ExpressionExperiment ee ) throws writer.write( buf.toString() ); } + return true; } /** * @param compress if true, file will be output in GZIP format. */ - private File writeDataFile( ExpressionExperiment ee, boolean filtered, File f, boolean compress ) + private Optional writeDataFile( ExpressionExperiment ee, boolean filtered, File f, boolean compress ) throws IOException, FilteringException { ExpressionDataFileServiceImpl.log.info( "Creating new expression data file: " + f.getName() ); ExpressionDataDoubleMatrix matrix = this.getDataMatrix( ee, filtered ); - + if ( matrix == null ) { + return Optional.empty(); + } Collection arrayDesigns = expressionExperimentService.getArrayDesignsUsed( ee ); Map geneAnnotations = this.getGeneAnnotationsAsStringsByProbe( arrayDesigns ); this.writeMatrix( f, geneAnnotations, matrix, compress ); - return f; + return Optional.of( f ); } /** @@ -1220,10 +1252,6 @@ private void writeVectors( File file, Collection vector @Override @Transactional(readOnly = true) public void writeTsv( ExpressionExperiment entity, Writer writer ) throws IOException { - QuantitationType qt = expressionExperimentService.getMaskedPreferredQuantitationType( entity ); - if ( qt == null ) { - throw new IllegalArgumentException( String.format( "%s lacks a preferred masked quantitation type.", entity ) ); - } - writeProcessedExpressionData( entity, qt, writer ); + writeProcessedExpressionData( entity, writer ); } } diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixService.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixService.java index 87010fb6fb..a60415c9aa 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixService.java @@ -14,15 +14,12 @@ */ package ubic.gemma.core.analysis.service; -import org.springframework.transaction.annotation.Transactional; import ubic.basecode.dataStructure.matrix.DoubleMatrix; import ubic.gemma.core.analysis.preprocess.filter.FilterConfig; import ubic.gemma.core.analysis.preprocess.filter.FilteringException; -import ubic.gemma.core.analysis.preprocess.filter.NoRowsLeftAfterFilteringException; import ubic.gemma.core.datastructure.matrix.ExpressionDataDoubleMatrix; import ubic.gemma.model.common.quantitationtype.QuantitationType; import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; -import ubic.gemma.model.expression.bioAssayData.RawExpressionDataVector; import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.model.genome.Gene; import ubic.gemma.persistence.service.expression.bioAssayData.ProcessedExpressionDataVectorDao; @@ -68,18 +65,10 @@ ExpressionDataDoubleMatrix getFilteredMatrix( String arrayDesignName, FilterConf @Nullable ExpressionDataDoubleMatrix getProcessedExpressionDataMatrix( ExpressionExperiment ee ); - /** - * Obtain a processed expression data matrix for a given quantitation type. - * @param quantitationType the quantitation type, or null to pick the preferred one - */ - @Nullable - ExpressionDataDoubleMatrix getProcessedExpressionDataMatrix( ExpressionExperiment ee, @Nullable QuantitationType quantitationType ); - /** * Obtain a raw expression data matrix for a given quantitation type - * @param quantitationType the quantitation type, or null to pick the preferred one */ - ExpressionDataDoubleMatrix getRawExpressionDataMatrix( ExpressionExperiment ee, @Nullable QuantitationType quantitationType ); + ExpressionDataDoubleMatrix getRawExpressionDataMatrix( ExpressionExperiment ee, QuantitationType quantitationType ); DoubleMatrix getRankMatrix( Collection genes, Collection ees, ProcessedExpressionDataVectorDao.RankMethod method ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixServiceImpl.java index 2ecb16d095..71b62a55bb 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/ExpressionDataMatrixServiceImpl.java @@ -112,16 +112,6 @@ public ExpressionDataDoubleMatrix getProcessedExpressionDataMatrix( ExpressionEx return new ExpressionDataDoubleMatrix( dataVectors ); } - @Override - @Transactional(readOnly = true) - public ExpressionDataDoubleMatrix getProcessedExpressionDataMatrix( ExpressionExperiment ee, QuantitationType quantitationType ) { - Collection vectors = processedExpressionDataVectorService.findByExpressionExperiment( ee, quantitationType ); - if ( vectors.isEmpty() ) { - return null; - } - return new ExpressionDataDoubleMatrix( vectors ); - } - @Override @Transactional(readOnly = true) public ExpressionDataDoubleMatrix getRawExpressionDataMatrix( ExpressionExperiment ee, QuantitationType quantitationType ) { diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/GeneMultifunctionalityPopulationServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/GeneMultifunctionalityPopulationServiceImpl.java index 6d8fe339d7..bfceeadc58 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/service/GeneMultifunctionalityPopulationServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/service/GeneMultifunctionalityPopulationServiceImpl.java @@ -39,7 +39,6 @@ import ubic.gemma.persistence.service.genome.taxon.TaxonService; import java.util.*; -import java.util.stream.Collectors; /** * Compute gene multifunctionality and store it in the database. @@ -233,6 +232,11 @@ private Map> fetchGoAnnotations( Collection genes ) { */ Set terms = new HashSet<>( annots.size() ); for ( Characteristic t : annots ) { + if ( t.getValueUri() == null ) { + GeneMultifunctionalityPopulationServiceImpl.log + .warn( "Free-text term annotated to " + gene + " : " + t ); + continue; + } OntologyTerm term = goService.getTerm( t.getValueUri() ); if ( term == null || term.isObsolete() ) { GeneMultifunctionalityPopulationServiceImpl.log diff --git a/gemma-core/src/main/java/ubic/gemma/core/analysis/util/ExperimentalDesignUtils.java b/gemma-core/src/main/java/ubic/gemma/core/analysis/util/ExperimentalDesignUtils.java index c533fc5e75..cd6e29990d 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/analysis/util/ExperimentalDesignUtils.java +++ b/gemma-core/src/main/java/ubic/gemma/core/analysis/util/ExperimentalDesignUtils.java @@ -181,7 +181,7 @@ public static boolean isBatch( ExperimentalFactor ef ) { } Characteristic category = ef.getCategory(); return ef.getName().equals( ExperimentalDesignUtils.BATCH_FACTOR_NAME ) && - ( category != null && category.getCategory().equals( ExperimentalDesignUtils.BATCH_FACTOR_CATEGORY_NAME ) ); + ( category != null && ExperimentalDesignUtils.BATCH_FACTOR_CATEGORY_NAME.equals( category.getCategory() ) ); } /** @@ -306,11 +306,16 @@ private static Object extractFactorValueForSample( Map ontology2CharacteristicValueObject( Collection ontologyTerms ) { Set characteristicsVO = new HashSet<>(); for ( OntologyTerm ontologyTerm : ontologyTerms ) { + if ( ontologyTerm.getLabel() == null ) { + log.warn( "Term with null label: " + ontologyTerm.getUri() + "; it cannot be converted to a CharacteristicValueObject" ); + continue; + } characteristicsVO.add( new CharacteristicValueObject( ontologyTerm.getLabel().toLowerCase(), ontologyTerm.getUri() ) ); } return characteristicsVO; diff --git a/gemma-core/src/main/java/ubic/gemma/core/association/phenotype/PhenotypeAssociationManagerServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/association/phenotype/PhenotypeAssociationManagerServiceImpl.java index 3bcec1822a..397380b885 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/association/phenotype/PhenotypeAssociationManagerServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/association/phenotype/PhenotypeAssociationManagerServiceImpl.java @@ -769,6 +769,7 @@ public Collection searchInDatabaseForPhenotype( Strin } return ontologyTermsFound.stream() + .filter( t -> t.getLabel() != null ) .map( t -> new CharacteristicValueObject( t.getLabel().toLowerCase(), t.getUri() ) ) .limit( maxResults > 0 ? maxResults : Long.MAX_VALUE ) .collect( Collectors.toCollection( TreeSet::new ) ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtil.java b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtil.java index 9a8c2002c2..006fd2415f 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtil.java +++ b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtil.java @@ -54,8 +54,19 @@ public class ExpressionDataDoubleMatrixUtil { private static final double LOGARITHM_BASE = 2.0; - private static final int COLUMNS_LIMIT = 4; - private static final double VALUES_LIMIT = 0.7; + + + /** + * This threshold is used to determine if a row has too many identical value; a value of N means that the number of distinct values in the + * expression vector of length M must be at least N * M. + */ + private static final double MINIMUM_UNIQUE_VALUES_FRACTION_PER_ELEMENT = 0.3; + + /** + * We don't apply the "unique values" filter to matrices with fewer columns than this. + */ + private static final int MINIMUM_COLUMNS_TO_APPLY_UNIQUE_VALUES_FILTER = 4; + private static final Log log = LogFactory.getLog( ExpressionDataDoubleMatrixUtil.class.getName() ); @@ -85,12 +96,12 @@ public static ExpressionDataDoubleMatrix filterAndLog2Transform( ExpressionDataD } r = dmatrix.rows(); - if ( dmatrix.columns() > ExpressionDataDoubleMatrixUtil.COLUMNS_LIMIT ) { + if ( dmatrix.columns() > ExpressionDataDoubleMatrixUtil.MINIMUM_COLUMNS_TO_APPLY_UNIQUE_VALUES_FILTER ) { /* This threshold had been 10^-5, but it's probably too stringent. Also remember * the data are log transformed the threshold should be transformed as well (it's not that simple), * but that's a minor effect. * To somewhat counter the effect of lowering this stringency, increasing the stringency on VALUES_LIMIT may help */ - dmatrix = ExpressionExperimentFilter.tooFewDistinctValues( dmatrix, ExpressionDataDoubleMatrixUtil.VALUES_LIMIT, 0.001 ); + dmatrix = ExpressionExperimentFilter.tooFewDistinctValues( dmatrix, ExpressionDataDoubleMatrixUtil.MINIMUM_UNIQUE_VALUES_FRACTION_PER_ELEMENT, 0.001 ); if ( dmatrix.rows() < r ) { ExpressionDataDoubleMatrixUtil.log.info( ( r - dmatrix.rows() ) + " rows removed due to too many identical values" ); } @@ -186,6 +197,14 @@ public static ExpressionDataDoubleMatrix ensureLog2Scale( ExpressionDataDoubleMa ExpressionDataDoubleMatrixUtil.log.info( " **** Converting from log10 to log2 **** " ); MatrixStats.convertToLog2( transformedMatrix, 10 ); break; + case LOG1P: + ExpressionDataDoubleMatrixUtil.log.info( " **** Converting from log1p to log2 **** " ); + for ( int i = 0; i < transformedMatrix.rows(); i++ ) { + for ( int j = 0; j < transformedMatrix.columns(); j++ ) { + transformedMatrix.set( i, j, Math.log( Math.expm1( transformedMatrix.get( i, j ) ) ) / Math.log( 2 ) ); + } + } + break; case LINEAR: ExpressionDataDoubleMatrixUtil.log.info( " **** LOG TRANSFORMING **** " ); MatrixStats.logTransform( transformedMatrix ); @@ -482,8 +501,6 @@ private static boolean isZScore( DoubleMatrix1D vector ) { return true; } // FIXME: use a faster algorithm for the median, there's a O(n) approach - // sort only if necessary, median expects a sorted input - v.sort(); return isCloseToZero( DescriptiveWithMissing.median( v ) ); } diff --git a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSort.java b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSort.java index a07bf72e81..c8e5cf4daa 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSort.java +++ b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSort.java @@ -20,14 +20,18 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.apache.commons.math3.analysis.function.Exp; import ubic.basecode.dataStructure.matrix.DoubleMatrix; import ubic.gemma.core.analysis.expression.diff.BaselineSelection; import ubic.gemma.core.analysis.util.ExperimentalDesignUtils; +import ubic.gemma.model.common.description.Characteristic; import ubic.gemma.model.expression.bioAssay.BioAssay; import ubic.gemma.model.expression.biomaterial.BioMaterial; import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.FactorValue; +import ubic.gemma.model.expression.experiment.Geeq; +import javax.annotation.Nullable; import java.util.*; import java.util.Map.Entry; @@ -89,13 +93,22 @@ public static Map getBaselineLevels( List getBaselineLevels( List DoubleMatrix orderByExperimentalDesign( DoubleMatrix mat ) { + return ExpressionDataMatrixColumnSort.orderByExperimentalDesign( mat, null ); + } + + public static DoubleMatrix orderByExperimentalDesign( DoubleMatrix mat, @Nullable ExperimentalFactor primaryFactor ) { List bioAssays = mat.getColNames(); @@ -191,7 +208,7 @@ public static DoubleMatrix orderByExperimentalDesign( DoubleMat start.add( bioAssay.getSampleUsed() ); bm2ba.put( bioAssay.getSampleUsed(), bioAssay ); } - List bm = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( start, null ); + List bm = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( start, null, primaryFactor ); List newBioAssayOrder = new ArrayList<>(); for ( BioMaterial bioMaterial : bm ) { assert bm2ba.containsKey( bioMaterial ); @@ -200,14 +217,19 @@ public static DoubleMatrix orderByExperimentalDesign( DoubleMat return mat.subsetColumns( newBioAssayOrder ); } + + public static List orderByExperimentalDesign( ExpressionDataMatrix mat ) { + return ExpressionDataMatrixColumnSort.orderByExperimentalDesign( mat, null ); + } + /** * @param mat matrix * @return bio materials */ - public static List orderByExperimentalDesign( ExpressionDataMatrix mat ) { + public static List orderByExperimentalDesign( ExpressionDataMatrix mat, @Nullable ExperimentalFactor primaryFactor ) { List start = ExpressionDataMatrixColumnSort.getBms( mat ); - List ordered = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( start, null ); + List ordered = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( start, null, primaryFactor ); assert ordered.size() == start.size() : "Expected " + start.size() + ", got " + ordered.size(); @@ -216,12 +238,23 @@ public static List orderByExperimentalDesign( ExpressionDataMatrix< } /** - * @param factors, can be null - * @param start start + * @param start BioMaterials to sort * @return bio materials */ public static List orderByExperimentalDesign( List start, Collection factors ) { + return ExpressionDataMatrixColumnSort.orderByExperimentalDesign( start, factors, null ); + } + + /** + * + * @param start BioMaterials to sort + * @param factors, can be null + * @param primaryFactor to start with, can be null + * @return bio materials + */ + public static List orderByExperimentalDesign( List start, + @Nullable Collection factors, @Nullable ExperimentalFactor primaryFactor ) { if ( start.size() == 1 ) { return start; @@ -232,7 +265,7 @@ public static List orderByExperimentalDesign( List sta } Collection unsortedFactors; - if ( factors != null ) { + if ( factors != null && !factors.isEmpty() ) { unsortedFactors = factors; } else { unsortedFactors = ExpressionDataMatrixColumnSort.getFactors( start ); @@ -245,7 +278,7 @@ public static List orderByExperimentalDesign( List sta // sort factors: which one do we want to sort by first List sortedFactors = ExpressionDataMatrixColumnSort - .orderFactorsByExperimentalDesign( start, unsortedFactors ); + .orderFactorsByExperimentalDesign( start, unsortedFactors, primaryFactor ); // sort biomaterials using sorted factors return ExpressionDataMatrixColumnSort.orderBiomaterialsBySortedFactors( start, sortedFactors ); } @@ -274,18 +307,34 @@ public int compare( BioMaterial o1, BioMaterial o2 ) { /** * @return list of factors, sorted from simplest (fewest number of values from the biomaterials passed in) to least - * simple. Continuous factors will always be first, and batch factors last. + * simple. */ private static List orderFactorsByExperimentalDesign( List start, - Collection factors ) { + Collection factors, ExperimentalFactor primaryFactor ) { - if ( factors == null || factors.isEmpty() ) { + if ( ( factors == null || factors.isEmpty() ) && primaryFactor == null ) { ExpressionDataMatrixColumnSort.log.warn( "No factors supplied for sorting" ); return new LinkedList<>(); } + // if we are provided a primary factor, we just work with it. LinkedList sortedFactors = new LinkedList<>(); + + if ( factors == null || factors.isEmpty() && primaryFactor != null ) { + sortedFactors.add( primaryFactor ); + return sortedFactors; + } + Collection factorsToTake = new HashSet<>( factors ); + + if ( primaryFactor != null ) { + if ( !factorsToTake.contains( primaryFactor ) ) { + throw new IllegalArgumentException( "Primary factor not in the list of factors" ); + } + sortedFactors.add( primaryFactor ); + factorsToTake.remove( primaryFactor ); + } + while ( !factorsToTake.isEmpty() ) { ExperimentalFactor simplest = ExpressionDataMatrixColumnSort.chooseSimplestFactor( start, factorsToTake ); if ( simplest == null ) { @@ -358,7 +407,7 @@ private static ExperimentalFactor chooseSimplestFactor( List bms, for ( ExperimentalFactor ef : factors ) { if ( ExperimentalDesignUtils.isContinuous( ef ) ) { - return ef; + // return ef; } /* @@ -484,6 +533,11 @@ private static Collection getFactors( Collection factorValues = bm.getFactorValues(); for ( FactorValue fv : factorValues ) { + + if ( fv.getCharacteristics().stream().map( Characteristic::getValue ).anyMatch( "DE_Exclude"::equalsIgnoreCase ) ) { + continue; + } + if ( !usedFactorValues.containsKey( fv.getExperimentalFactor() ) ) { usedFactorValues.put( fv.getExperimentalFactor(), new HashSet<>() ); } @@ -565,11 +619,8 @@ private static List orderByFactor( ExperimentalFactor ef, Map * Sort biomaterials according to a list of ordered factors. - *

- *

- * If any factor is continuous, we sort by it and don't do any further sorting. *

- * Otherwise, for categorical factors, we sort recursively (by levels of the first factor, then + * For categorical factors, we sort recursively (by levels of the first factor, then * within that by levels of the second factor etc.) *

* Any batch factor is used last (we sort by batch only within the most granular factor's levels) @@ -610,12 +661,6 @@ private static List orderBiomaterialsBySortedFactors( List ordered = ExpressionDataMatrixColumnSort.orderByFactor( simplest, fv2bms, start ); - // Abort ordering, so we are ordered only by the first continuous factor. - if ( ExperimentalDesignUtils.isContinuous( simplest ) ) { - assert ordered != null; - return ordered; - } - LinkedList factorsStillToDo = new LinkedList<>(); factorsStillToDo.addAll( factors ); factorsStillToDo.remove( simplest ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/MatrixWriter.java b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/MatrixWriter.java index e0ebe41c8f..d6f858f060 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/MatrixWriter.java +++ b/gemma-core/src/main/java/ubic/gemma/core/datastructure/matrix/MatrixWriter.java @@ -44,7 +44,7 @@ public class MatrixWriter extends AbstractFileService> { public void write( Writer writer, ExpressionDataMatrix matrix, - Map> geneAnnotations, boolean writeHeader, boolean orderByDesign ) + @Nullable Map> geneAnnotations, boolean writeHeader, boolean orderByDesign ) throws IOException { this.write( writer, matrix, geneAnnotations, writeHeader, true, true, orderByDesign ); } diff --git a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSearchServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSearchServiceImpl.java index 9850096eef..2d5eef3706 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSearchServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSearchServiceImpl.java @@ -27,7 +27,6 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.access.AccessDeniedException; import org.springframework.stereotype.Service; -import ubic.basecode.ontology.search.OntologySearchException; import ubic.gemma.core.genome.gene.*; import ubic.gemma.core.ontology.providers.GeneOntologyService; import ubic.gemma.core.search.*; @@ -245,8 +244,10 @@ public Collection searchGenesAndGeneGroups( String qu taxon = geneSetService.getTaxon( gs ); GeneSetValueObject gsVo = geneSetValueObjectHelper.convertToValueObject( gs ); srDo = new SearchResultDisplayObject( gsVo ); - srDo.setTaxonId( taxon.getId() ); - srDo.setTaxonName( taxon.getCommonName() ); + if ( taxon != null ) { + srDo.setTaxonId( taxon.getId() ); + srDo.setTaxonName( taxon.getCommonName() ); + } geneSets.add( srDo ); } taxon = null; @@ -404,9 +405,11 @@ private List> retainGeneSetsOfThisTaxon( Long taxonId, Lis for ( SearchResult sr : geneSetSearchResults ) { GeneSet gs = sr.getResultObject(); if ( gs != null ) { - GeneSetValueObject gsVo = geneSetValueObjectHelper.convertToValueObject( gs ); + Set geneSetTaxaIds = geneSetService.getTaxa( gs ).stream() + .map( Taxon::getId ) + .collect( Collectors.toSet() ); isSetOwnedByUser.put( gs.getId(), securityService.isOwnedByCurrentUser( gs ) ); - if ( Objects.equals( gsVo.getTaxonId(), taxonId ) ) { + if ( geneSetTaxaIds.contains( taxonId ) ) { taxonCheckedSets.add( sr ); } } diff --git a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetService.java b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetService.java index 762dee961b..dd6cb3c64f 100755 --- a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetService.java @@ -38,6 +38,7 @@ import javax.annotation.ParametersAreNonnullByDefault; import java.util.Collection; import java.util.List; +import java.util.Set; /** * Service for managing gene sets @@ -152,7 +153,7 @@ public interface GeneSetService extends BaseService, BaseVoEnabledServi * @see GeneSetDao GeneSetDao for security filtering */ @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "AFTER_ACL_COLLECTION_READ" }) - Collection loadAll( Taxon tax ); + Collection loadAll( @Nullable Taxon tax ); /** * Returns the {@link GeneSet}s for the currently logged in {@link User} - i.e, ones for which the current user has @@ -303,10 +304,16 @@ Collection updateDatabaseEntity( * all the genes * * @param geneSet gene set - * @return the taxon or null if the gene set param was null + * @return a taxon, or null if the gene set has no member */ + @Nullable Taxon getTaxon( GeneSet geneSet ); + /** + * Obtain all the taxa for the members of a given gene set. + */ + Set getTaxa( GeneSet geneSet ); + @Override @Secured({ "GROUP_USER", "ACL_SECURABLE_EDIT" }) void update( GeneSet entity ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetServiceImpl.java index c2566e8a79..fad346956c 100755 --- a/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/genome/gene/service/GeneSetServiceImpl.java @@ -121,7 +121,7 @@ public Collection findByName( String name, Taxon taxon ) { @Override @Transactional(readOnly = true) - public Collection loadAll( Taxon tax ) { + public Collection loadAll( @Nullable Taxon tax ) { return this.geneSetDao.loadAll( tax ); } @@ -487,12 +487,13 @@ public TaxonValueObject getTaxonVOforGeneSetVO( SessionBoundGeneSetValueObject g @Override @Transactional(readOnly = true) public Taxon getTaxon( GeneSet geneSet ) { - if ( geneSet == null ) - return null; - Taxon tmpTax; - tmpTax = geneSetDao.getTaxon( geneSet.getId() ); + return geneSetDao.getTaxon( geneSet ); + } - return tmpTax; + @Override + @Transactional(readOnly = true) + public Set getTaxa( GeneSet geneSet ) { + return new HashSet<>( geneSetDao.getTaxa( geneSet ) ); } private void checkGeneList( GeneSet gset, Collection updatedGenelist, Collection genes ) { diff --git a/gemma-core/src/main/java/ubic/gemma/core/job/executor/webapp/TaskRunningServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/job/executor/webapp/TaskRunningServiceImpl.java index c865b22f7f..7b630980d1 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/job/executor/webapp/TaskRunningServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/job/executor/webapp/TaskRunningServiceImpl.java @@ -20,6 +20,7 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.springframework.beans.factory.DisposableBean; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.concurrent.DelegatingSecurityContextCallable; import org.springframework.stereotype.Component; @@ -44,7 +45,7 @@ */ // Valid, inspection is not parsing the context file for some reason @Component -public class TaskRunningServiceImpl implements TaskRunningService { +public class TaskRunningServiceImpl implements TaskRunningService, DisposableBean { private static final Log log = LogFactory.getLog( TaskRunningServiceImpl.class ); private final ExecutorService executorService = Executors.newFixedThreadPool( 20 ); private final Map submittedTasks = new ConcurrentHashMap<>(); @@ -54,6 +55,19 @@ public class TaskRunningServiceImpl implements TaskRunningService { @Autowired private TaskPostProcessing taskPostProcessing; + @Override + public void destroy() throws Exception { + log.info( "Shutting down TaskRunningService executor..." ); + executorService.shutdown(); + if ( !executorService.isTerminated() ) { + log.warn( "There are still running tasks, will wait at most 5 minutes before shutting them down." ); + } + if ( !executorService.awaitTermination( 5, TimeUnit.MINUTES ) ) { + log.info( "TaskRunningService executor was still running after 5 minutes, interrupting pending tasks..." ); + executorService.shutdownNow(); + } + } + @Override public SubmittedTask getSubmittedTask( String taskId ) { return submittedTasks.get( taskId ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/loader/association/phenotype/PhenotypeProcessingUtil.java b/gemma-core/src/main/java/ubic/gemma/core/loader/association/phenotype/PhenotypeProcessingUtil.java index 21033fe5b1..e586c01f30 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/loader/association/phenotype/PhenotypeProcessingUtil.java +++ b/gemma-core/src/main/java/ubic/gemma/core/loader/association/phenotype/PhenotypeProcessingUtil.java @@ -562,7 +562,7 @@ private void parseManualMappingFile() throws IOException { if ( ontologyTerm != null ) { - if ( ontologyTerm.getLabel().equalsIgnoreCase( valueStaticFile ) ) { + if ( valueStaticFile.equalsIgnoreCase( ontologyTerm.getLabel() ) ) { if ( manualDescriptionToValuesUriMapping.get( termId ) != null ) { col = manualDescriptionToValuesUriMapping.get( termId ); @@ -917,8 +917,12 @@ private boolean findUsingManualMappingFile( String meshOrOmimId, String annotato meshOrOmimId + this.findExtraInfoMeshDescription( meshOrOmimId ) + " PARENT: (" ); for ( OntologyTerm o : onParents ) { - - String meshId = this.changeToId( o.getUri() ); + String termUri = o.getUri(); + if ( termUri == null ) { + log.warn( "Ignoring free-text term " + o ); + continue; + } + String meshId = this.changeToId( termUri ); Collection uri = this.findManualMappingTermValueUri( meshId ); if ( uri != null && !uri.isEmpty() ) { phenotypesUri.addAll( uri ); @@ -1185,8 +1189,13 @@ private Map> meshToDiseaseTerms( Collection> diseaseTerms = new HashMap<>(); for ( OntologyTerm m : meshTerms ) { + String termUri = m.getUri(); + if ( termUri == null ) { + log.warn( "Ignoring free-text term: " + m ); + continue; + } - String meshId = this.changeToId( m.getUri() ); + String meshId = this.changeToId( termUri ); Collection onDisease = this.findOntologyTermsUriWithDiseaseId( meshId ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/ExpressionExperimentPlatformSwitchService.java b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/ExpressionExperimentPlatformSwitchService.java index 66773ad296..76c7ae74af 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/ExpressionExperimentPlatformSwitchService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/ExpressionExperimentPlatformSwitchService.java @@ -278,6 +278,8 @@ private void cleanupUnused( ExpressionExperiment ee, Collection() ); + // numberOfSample is updated later when the BAs are populated if ( series.getSampleCorrespondence().size() == 0 ) { throw new IllegalArgumentException( "No sample correspondence!" ); @@ -2703,7 +2704,7 @@ private FactorValue findMatchingExperimentalFactorValue( Collection fetchAndLoad( String geoAccession, boolean loadPlatformOnly, boole void setGeoDomainObjectGenerator( GeoDomainObjectGenerator generator ); + /** + * Load from a SOFT file. This can be used for testing but maybe there are other situations it is useful. + * + * @param accession e.g GSE1234 + * @param softFile the full path to the SOFT file. The file name has to be [accession].soft.gz + * @return a single experiment. + */ + Collection loadFromSoftFile( String accession, String softFile, boolean loadPlatformOnly, boolean doSampleMatching, boolean splitByPlatform ); } \ No newline at end of file diff --git a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/geo/service/GeoServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/geo/service/GeoServiceImpl.java index 57f19d8912..b99a27d12a 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/geo/service/GeoServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/geo/service/GeoServiceImpl.java @@ -19,7 +19,6 @@ package ubic.gemma.core.loader.expression.geo.service; import org.apache.commons.lang3.StringUtils; -import org.hibernate.cfg.Settings; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Component; @@ -28,10 +27,7 @@ import ubic.gemma.core.analysis.report.ExpressionExperimentReportService; import ubic.gemma.core.annotation.reference.BibliographicReferenceService; import ubic.gemma.core.loader.entrez.pubmed.PubMedXMLFetcher; -import ubic.gemma.core.loader.expression.geo.DatasetCombiner; -import ubic.gemma.core.loader.expression.geo.GeoConverter; -import ubic.gemma.core.loader.expression.geo.GeoDomainObjectGenerator; -import ubic.gemma.core.loader.expression.geo.GeoSampleCorrespondence; +import ubic.gemma.core.loader.expression.geo.*; import ubic.gemma.core.loader.expression.geo.model.*; import ubic.gemma.core.loader.util.AlreadyExistsInSystemException; import ubic.gemma.model.common.auditAndSecurity.eventType.ExpressionExperimentUpdateFromGEOEvent; @@ -44,7 +40,6 @@ import ubic.gemma.model.expression.designElement.CompositeSequence; import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.model.genome.biosequence.BioSequence; -import ubic.gemma.persistence.persister.Persister; import ubic.gemma.persistence.service.ExpressionExperimentPrePersistService; import ubic.gemma.persistence.service.common.auditAndSecurity.AuditTrailService; import ubic.gemma.persistence.service.common.description.CharacteristicService; @@ -53,8 +48,8 @@ import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentService; import ubic.gemma.persistence.service.genome.taxon.TaxonService; import ubic.gemma.persistence.util.ArrayDesignsForExperimentCache; -import ubic.gemma.persistence.util.SettingsConfig; +import java.io.File; import java.util.*; /** @@ -67,7 +62,7 @@ public class GeoServiceImpl extends AbstractGeoService { private static final String GEO_DB_NAME = "GEO"; - @Value( "${geo.minimumSamplesToLoad}") + @Value("${geo.minimumSamplesToLoad}") private int MINIMUM_SAMPLE_COUNT_TO_LOAD; private final ArrayDesignReportService arrayDesignReportService; @@ -389,6 +384,15 @@ public void updateFromGEO( String geoAccession ) { } + @Override + @Transactional + public Collection loadFromSoftFile( String accession, String softFile, boolean loadPlatformOnly, boolean doSampleMatching, boolean splitByPlatform ) { + File f = new File( softFile ); + this.setGeoDomainObjectGenerator( + new GeoDomainObjectGeneratorLocal( f.getParent() ) ); + return fetchAndLoad( accession, loadPlatformOnly, doSampleMatching, splitByPlatform ); + } + private void check( Collection result ) { for ( ExpressionExperiment expressionExperiment : result ) { this.check( expressionExperiment ); diff --git a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/simple/ExperimentalDesignImporterImpl.java b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/simple/ExperimentalDesignImporterImpl.java index 04ede86afb..47634236f2 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/loader/expression/simple/ExperimentalDesignImporterImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/loader/expression/simple/ExperimentalDesignImporterImpl.java @@ -368,9 +368,7 @@ private void addFactorValuesToExperimentalFactor( ExperimentalFactor experimenta ExperimentalDesignImporterImpl.log.debug( "Factor is categorical" ); Statement newVc = Statement.Factory.newInstance(); if ( category != null ) { - String category2 = category.getCategory(); - assert category2 != null; - newVc.setCategory( category2 ); + newVc.setCategory( category.getCategory() ); newVc.setCategoryUri( category.getCategoryUri() ); } newVc.setValue( value ); // don't have a valueUri at this point @@ -580,12 +578,12 @@ private Map mapBioMaterialsToNamePossibilities( Collection< private Characteristic termForCategoryLookup( String category, Collection terms ) { OntologyTerm t = null; - String lookup = category.replaceAll( "_", " " ).toLowerCase(); + String lookup = category.replaceAll( "_", " " ); for ( OntologyTerm to : terms ) { - if ( to.getLabel().equals( category ) - || to.getLabel().toLowerCase().equals( lookup ) + if ( category.equalsIgnoreCase( to.getLabel() ) + || lookup.equalsIgnoreCase( to.getLabel() ) // if EFO is loaded, the "sex" term is actually named "biological sex" - || ( to.getLabel().equals( "biological sex" ) && lookup.equals( "sex" ) ) ) { + || ( "biological sex".equalsIgnoreCase( to.getLabel() ) && "sex".equalsIgnoreCase( lookup ) ) ) { t = to; break; } diff --git a/gemma-core/src/main/java/ubic/gemma/core/ontology/GoMetricImpl.java b/gemma-core/src/main/java/ubic/gemma/core/ontology/GoMetricImpl.java index ad18c75ab0..2ddbbfadff 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/ontology/GoMetricImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/ontology/GoMetricImpl.java @@ -19,6 +19,7 @@ package ubic.gemma.core.ontology; +import org.apache.commons.lang3.StringUtils; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.springframework.beans.factory.annotation.Autowired; @@ -113,7 +114,7 @@ public Double computeMaxSimilarity( Gene queryGene, Gene targetGene, Map termCountMap, String int termCount = termCountMap.get( term ); OntologyTerm ont = geneOntologyService.getTerm( term ); + if ( ont == null ) { + GoMetricImpl.log.warn( "No GO term found for: " + term + ", will fallback to zero for the number of children occurrences." ); + return 0; + } + Collection children = ont.getChildren( false, partOf ); if ( children.isEmpty() ) { @@ -397,7 +403,7 @@ private Double checkParents( OntologyTerm ontoM, OntologyTerm ontoC, Map getChildren( Collection terms, boolean di public Collection getCategoryTerms() { return categoryTerms.stream() .map( term -> { + String termUri = term.getUri(); + if ( termUri == null ) { + return term; // a free-text category + } if ( experimentalFactorOntologyService.isOntologyLoaded() ) { - OntologyTerm efoTerm = experimentalFactorOntologyService.getTerm( term.getUri() ); + OntologyTerm efoTerm = experimentalFactorOntologyService.getTerm( termUri ); if ( efoTerm != null ) { return efoTerm; } @@ -448,7 +452,7 @@ public String getDefinition( String uri ) { if ( ot != null ) { for ( AnnotationProperty ann : ot.getAnnotations() ) { // FIXME: not clear this will work with all ontologies. UBERON, HP, MP, MONDO does it this way. - if ( ann.getUri().equals( "http://purl.obolibrary.org/obo/IAO_0000115" ) ) { + if ( "http://purl.obolibrary.org/obo/IAO_0000115".equals( ann.getUri() ) ) { return ann.getContents(); } } @@ -681,6 +685,10 @@ private Collection findCharacteristicsFromOntology( S for ( OntologyTerm ontologyTerm : ontologyTerms ) { // if the ontology term wasnt already found in the database if ( characteristicFromDatabaseWithValueUri.get( ontologyTerm.getUri() ) == null ) { + if ( ontologyTerm.getLabel() == null ) { + log.warn( "Term with null label: " + ontologyTerm.getUri() + "; it cannot be converted to a CharacteristicValueObject" ); + continue; + } CharacteristicValueObject phenotype = new CharacteristicValueObject( ontologyTerm.getLabel().toLowerCase(), ontologyTerm.getUri() ); characteristicsFromOntology.add( phenotype ); } diff --git a/gemma-core/src/main/java/ubic/gemma/core/ontology/providers/GeneOntologyServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/ontology/providers/GeneOntologyServiceImpl.java index d36278a874..7c4270e35c 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/ontology/providers/GeneOntologyServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/ontology/providers/GeneOntologyServiceImpl.java @@ -76,6 +76,9 @@ public static String asRegularGoId( OntologyTerm term ) { if ( term == null ) return null; String uri = term.getUri(); + if ( uri == null ) { + return null; + } return GeneOntologyServiceImpl.asRegularGoId( uri ); } diff --git a/gemma-core/src/main/java/ubic/gemma/core/search/GeneSetSearchImpl.java b/gemma-core/src/main/java/ubic/gemma/core/search/GeneSetSearchImpl.java index a10a027c94..4a3e8ed4ea 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/search/GeneSetSearchImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/search/GeneSetSearchImpl.java @@ -32,6 +32,7 @@ import ubic.gemma.core.genome.gene.GeneSetValueObjectHelper; import ubic.gemma.core.genome.gene.service.GeneSetService; import ubic.gemma.core.ontology.providers.GeneOntologyService; +import ubic.gemma.model.common.description.CharacteristicValueObject; import ubic.gemma.model.genome.Gene; import ubic.gemma.model.genome.Taxon; import ubic.gemma.model.genome.TaxonValueObject; @@ -39,7 +40,6 @@ import ubic.gemma.model.genome.gene.GeneSetMember; import ubic.gemma.model.genome.gene.GeneSetValueObject; import ubic.gemma.model.genome.gene.GeneValueObject; -import ubic.gemma.model.common.description.CharacteristicValueObject; import ubic.gemma.persistence.service.association.Gene2GOAssociationService; import ubic.gemma.persistence.service.genome.taxon.TaxonService; import ubic.gemma.persistence.util.EntityUtils; diff --git a/gemma-core/src/main/java/ubic/gemma/core/util/BuildInfo.java b/gemma-core/src/main/java/ubic/gemma/core/util/BuildInfo.java index 79170613f3..3faf3023ae 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/util/BuildInfo.java +++ b/gemma-core/src/main/java/ubic/gemma/core/util/BuildInfo.java @@ -1,32 +1,41 @@ package ubic.gemma.core.util; +import lombok.extern.apachecommons.CommonsLog; import org.springframework.beans.factory.InitializingBean; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; +import org.springframework.core.io.ClassPathResource; import org.springframework.format.datetime.DateFormatter; -import ubic.gemma.persistence.util.Settings; import javax.annotation.Nullable; +import java.io.FileNotFoundException; +import java.io.IOException; +import java.io.InputStream; import java.text.DateFormat; +import java.text.ParseException; import java.util.Date; import java.util.Locale; +import java.util.Properties; +@CommonsLog @Configuration public class BuildInfo implements InitializingBean { private static final String MAVEN_DATETIME_PATTERN = "yyyy-MM-dd'T'HH:mm:ss'Z'"; /** - * Retrieves the build info using {@link Settings} - * @deprecated simply autowire this configuration to access build information at runtime + * Retrieve build information directly from the classpath. */ - @Deprecated - public static BuildInfo fromSettings() { - try { - return new BuildInfo( Settings.getString( "gemma.version" ), - Settings.getString( "gemma.build.timestamp" ), - Settings.getString( "gemma.build.gitHash" ) ); - } catch ( Exception e ) { + public static BuildInfo fromClasspath() { + Properties props = new Properties(); + try ( InputStream reader = new ClassPathResource( "/ubic/gemma/version.properties" ).getInputStream() ) { + props.load( reader ); + return new BuildInfo( props.getProperty( "gemma.version" ), + props.getProperty( "gemma.build.timestamp" ), + props.getProperty( "gemma.build.gitHash" ) ); + } catch ( FileNotFoundException e ) { + return new BuildInfo(); + } catch ( IOException e ) { throw new RuntimeException( e ); } } @@ -44,7 +53,7 @@ public BuildInfo() { } - private BuildInfo( String version, String timestampAsString, String gitHash ) throws Exception { + private BuildInfo( String version, String timestampAsString, String gitHash ) { this.version = version; this.timestampAsString = timestampAsString; this.gitHash = gitHash; @@ -52,10 +61,15 @@ private BuildInfo( String version, String timestampAsString, String gitHash ) th } @Override - public void afterPropertiesSet() throws Exception { + public void afterPropertiesSet() { if ( timestampAsString != null ) { - timestamp = new DateFormatter( MAVEN_DATETIME_PATTERN ) - .parse( timestampAsString, Locale.getDefault() ); + try { + timestamp = new DateFormatter( MAVEN_DATETIME_PATTERN ) + .parse( timestampAsString, Locale.getDefault() ); + + } catch ( ParseException e ) { + log.error( "Failed to parse build timestamp.", e ); + } } } diff --git a/gemma-core/src/main/java/ubic/gemma/core/util/DummyMailSender.java b/gemma-core/src/main/java/ubic/gemma/core/util/DummyMailSender.java index a36a358c60..10411dc818 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/util/DummyMailSender.java +++ b/gemma-core/src/main/java/ubic/gemma/core/util/DummyMailSender.java @@ -22,7 +22,7 @@ import org.springframework.mail.MailException; import org.springframework.mail.MailSender; import org.springframework.mail.SimpleMailMessage; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; /** * Mock mail sender for testing. @@ -38,7 +38,7 @@ public class DummyMailSender implements MailSender, InitializingBean { @Override public void afterPropertiesSet() throws Exception { - if ( environment.acceptsProfiles( SpringProfiles.DEV ) ) { + if ( environment.acceptsProfiles( EnvironmentProfiles.DEV ) ) { log.warn( "Emails will be sent to a dummy mail sender. If this is not intended, activate the 'production' profile by setting -Dspring.profiles.active=production." ); } } diff --git a/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationService.java b/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationService.java index ed5adaf8de..50a2f8ef0c 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationService.java +++ b/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationService.java @@ -18,6 +18,7 @@ import ubic.gemma.model.expression.bioAssayData.DoubleVectorValueObject; import ubic.gemma.model.expression.experiment.ExperimentalFactor; +import javax.annotation.Nullable; import java.util.Collection; import java.util.LinkedHashMap; import java.util.Map; @@ -27,6 +28,18 @@ */ public interface ExperimentalDesignVisualizationService { + /** + * Put data vectors in the order you'd want to display the experimental design. This causes the "isReorganized" flag + * of the dedVs to be set to true. + * + * @param dedVs dedVs, already sliced for the subset of samples needed for display (if necessary); will be modified + * @param primaryFactor if non-null this factor will be used to order the data, otherwise the first factor will be chosen using built-in heuristics. Set this to ensure that + * the data is ordered by the factor you want as in the case of showing DE genes + * @return Map of EE ids to "layouts", which are Maps of BioAssays to map of experimental factors to doubles. + */ + Map>> sortVectorDataByDesign( + Collection dedVs, @Nullable ExperimentalFactor primaryFactor ); + /** * Put data vectors in the order you'd want to display the experimental design. This causes the "isReorganized" flag * of the dedVs to be set to true. diff --git a/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationServiceImpl.java index 9c111d9b9d..4bb11e5cca 100644 --- a/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/core/visualization/ExperimentalDesignVisualizationServiceImpl.java @@ -24,6 +24,8 @@ import org.apache.commons.lang3.time.StopWatch; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; +import org.apache.commons.math3.analysis.function.Exp; +import org.apache.log4j.Layout; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import ubic.basecode.dataStructure.matrix.DoubleMatrix; @@ -44,6 +46,7 @@ import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentService; import ubic.gemma.persistence.util.EntityUtils; +import javax.annotation.Nullable; import java.awt.*; import java.io.File; import java.io.IOException; @@ -60,10 +63,50 @@ @Component public class ExperimentalDesignVisualizationServiceImpl implements ExperimentalDesignVisualizationService { + class LayoutSelection { + private Long experimentId; + private Long factorId; // nullable. + + public LayoutSelection( Long experimentId, @Nullable ExperimentalFactor primaryFactor ) { + this.experimentId = experimentId; + + if ( primaryFactor != null ) + this.factorId = primaryFactor.getId(); + } + + public LayoutSelection( Long experimentId, Long primaryFactorId ) { + this.experimentId = experimentId; + this.factorId = primaryFactorId; + } + + public LayoutSelection( Long experimentId ) { + this.experimentId = experimentId; + this.factorId = null; + } + + public int hashCode() { + return Objects.hash( experimentId, factorId ); + } + + public boolean equals( Object obj ) { + if ( this == obj ) { + return true; + } + if ( obj == null ) { + return false; + } + if ( getClass() != obj.getClass() ) { + return false; + } + LayoutSelection other = ( LayoutSelection ) obj; + return Objects.equals( experimentId, other.experimentId ) && Objects.equals( factorId, other.factorId ); + } + } + /** * Cache of layouts for experiments, keyed by experiment ID. */ - private final Map>> cachedLayouts = new ConcurrentHashMap<>(); + private final Map>> cachedLayouts = new ConcurrentHashMap<>(); private final Log log = LogFactory.getLog( this.getClass().getName() ); private final ExpressionExperimentService expressionExperimentService; @@ -75,6 +118,12 @@ public ExperimentalDesignVisualizationServiceImpl( ExpressionExperimentService e @Override public Map>> sortVectorDataByDesign( Collection dedVs ) { + return this.sortVectorDataByDesign( dedVs, null ); + } + + @Override + public Map>> sortVectorDataByDesign( + Collection dedVs, ExperimentalFactor primaryFactor ) { //cachedLayouts.clear(); // uncomment FOR DEBUGGING. @@ -90,9 +139,9 @@ public Map> newOrderingsForBioAssayDimensions = new HashMap<>(); for ( DoubleVectorValueObject vec : dedVs ) { @@ -105,17 +154,22 @@ public Map> layout = null; - if ( cachedLayouts.containsKey( vec.getExpressionExperiment().getId() ) ) { - layout = cachedLayouts.get( vec.getExpressionExperiment().getId() ); - } else if ( vec.getExpressionExperiment().getClass() + + LayoutSelection cacheKey = null; + + if ( vec.getExpressionExperiment().getClass() .isInstance( ExpressionExperimentSubsetValueObject.class ) ) { - // subset. - layout = cachedLayouts.get( ( ( ExpressionExperimentSubsetValueObject ) vec.getExpressionExperiment() ) - .getSourceExperiment() ); + cacheKey = new LayoutSelection( ( ( ExpressionExperimentSubsetValueObject ) vec.getExpressionExperiment() ).getSourceExperiment(), primaryFactor ); + } else { + cacheKey = new LayoutSelection( vec.getExpressionExperiment().getId(), primaryFactor ); } + + layout = cachedLayouts.get( cacheKey ); + + if ( layout == null || layout.isEmpty() ) { - log.warn( "Did not find cached layout for " + vec.getId() ); + log.debug( "Did not find cached layout for " + vec.getId() + ( primaryFactor != null ? " PrimaryFactor=" + primaryFactor.getName() : "" ) ); continue; } @@ -216,12 +270,11 @@ public Map> extension = this - .getExperimentalDesignLayout( actualEe, expressionExperimentService.getBioAssayDimensions( actualEe ) ); + .getExperimentalDesignLayout( actualEe, expressionExperimentService.getBioAssayDimensions( actualEe ), null ); for ( BioAssayValueObject vbaVo : bioAssayDimension.getBioAssays() ) { assert extension.containsKey( vbaVo ); @@ -313,9 +366,9 @@ private LinkedHashMap> getExperimentalDesignLayout( ExpressionExperiment e ) { - if ( cachedLayouts.containsKey( e.getId() ) ) { - return cachedLayouts.get( e.getId() ); + if ( cachedLayouts.containsKey( new LayoutSelection( e.getId() ) ) ) { + return cachedLayouts.get( new LayoutSelection( e.getId() ) ); } Collection bds = expressionExperimentService.getBioAssayDimensions( e ); e = this.expressionExperimentService.thawLite( e ); LinkedHashMap> result = this - .getExperimentalDesignLayout( e, bds ); + .getExperimentalDesignLayout( e, bds, null ); - cachedLayouts.put( e.getId(), result ); + cachedLayouts.put( new LayoutSelection( e.getId() ), result ); return result; } @@ -357,11 +410,12 @@ private LinkedHashMap> getExperimentalDesignLayout( - BioAssaySet experiment, Collection bds ) { + BioAssaySet experiment, Collection bds, ExperimentalFactor primaryFactor ) { LinkedHashMap> result = new LinkedHashMap<>(); @@ -375,7 +429,7 @@ private LinkedHashMap bms = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( mat ); + List bms = ExpressionDataMatrixColumnSort.orderByExperimentalDesign( mat, primaryFactor ); Map fvV = new HashMap<>(); @@ -433,22 +487,22 @@ private LinkedHashMap alreadyFilled = new HashSet<>(); - if ( expressionExperiment.getRawExpressionDataVectors().isEmpty() ) { AbstractPersister.log.debug( "Filling in bioassays" ); for ( BioAssay bioAssay : expressionExperiment.getBioAssays() ) { this.fillInBioAssayAssociations( bioAssay, caches ); - alreadyFilled.add( bioAssay ); } } else { AbstractPersister.log.debug( "Filling in bioassays via data vectors" ); // usual case. + Set alreadyFilled; alreadyFilled = this.fillInExpressionExperimentDataVectorAssociations( expressionExperiment, caches ); expressionExperiment.setBioAssays( alreadyFilled ); + expressionExperiment.setNumberOfSamples( alreadyFilled.size() ); } } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/AbstractQueryFilteringVoEnabledDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/AbstractQueryFilteringVoEnabledDao.java index 2276f3be65..0e2784ffe4 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/AbstractQueryFilteringVoEnabledDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/AbstractQueryFilteringVoEnabledDao.java @@ -15,6 +15,8 @@ import java.util.concurrent.TimeUnit; import java.util.stream.Collectors; +import static java.util.Objects.requireNonNull; + /** * Partial implementation of {@link FilteringVoEnabledDao} based on the Hibernate {@link Query} API. * @@ -343,7 +345,8 @@ private Slice doLoadValueObjectsWithCache( @Nullable Filters filters, @Nulla private long doCountWithCache( @Nullable Filters filters, boolean cacheable ) { StopWatch timer = StopWatch.createStarted(); try { - return ( Long ) this.getFilteringCountQuery( filters ).setCacheable( cacheable ).uniqueResult(); + return ( Long ) requireNonNull( this.getFilteringCountQuery( filters ).setCacheable( cacheable ).uniqueResult(), + String.format( "Counting query for %s returned null.", elementClass.getName() ) ); } finally { timer.stop(); if ( timer.getTime( TimeUnit.MILLISECONDS ) > REPORT_SLOW_QUERY_AFTER_MS ) { diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtil.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtil.java index dfbbaaf2cb..e940364a1d 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtil.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtil.java @@ -20,8 +20,6 @@ import org.springframework.security.access.annotation.Secured; -import java.nio.file.Path; - /** * @author paul */ @@ -67,6 +65,15 @@ public interface TableMaintenanceUtil { @Secured({ "GROUP_AGENT" }) int updateExpressionExperiment2CharacteristicEntries(); + /** + * Update a specific level of the {@code EXPRESSION_EXPERIMENT2CHARACTERISTIC} table. + * @param level the level to update which is either {@link ubic.gemma.model.expression.experiment.ExpressionExperiment}, + * {@link ubic.gemma.model.expression.biomaterial.BioMaterial} or {@link ubic.gemma.model.expression.experiment.ExperimentalDesign} + * @return the number of records that were created or updated + */ + @Secured({ "GROUP_AGENT" }) + int updateExpressionExperiment2CharacteristicEntries( Class level ); + /** * Update the {@code EXPRESSION_EXPERIMENT2_ARRAY_DESIGN} table. * @return the number of records that were created or updated @@ -74,9 +81,6 @@ public interface TableMaintenanceUtil { @Secured({ "GROUP_AGENT" }) int updateExpressionExperiment2ArrayDesignEntries(); - @Secured({ "GROUP_ADMIN" }) - void setGene2CsInfoPath( Path gene2CsInfoPath ); - // for tests only, to keep from getting emails. @Secured({ "GROUP_ADMIN" }) void disableEmail(); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtilImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtilImpl.java index 28328505a5..b8f0fe281a 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtilImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/TableMaintenanceUtilImpl.java @@ -26,6 +26,7 @@ import org.apache.commons.logging.LogFactory; import org.hibernate.SessionFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; import org.springframework.mail.SimpleMailMessage; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -43,7 +44,6 @@ import ubic.gemma.persistence.service.common.description.ExternalDatabaseService; import ubic.gemma.persistence.service.genome.GeneDao; import ubic.gemma.persistence.util.MailEngine; -import ubic.gemma.persistence.util.Settings; import javax.annotation.Nullable; import java.io.IOException; @@ -52,7 +52,6 @@ import java.nio.file.Files; import java.nio.file.NoSuchFileException; import java.nio.file.Path; -import java.nio.file.Paths; import java.util.Calendar; import java.util.Collection; import java.util.Date; @@ -90,24 +89,25 @@ public class TableMaintenanceUtilImpl implements TableMaintenanceUtil { + "and AOI.OBJECT_ID = I.ID " + "and ACE.SID_FK = (select ACLSID.ID from ACLSID where ACLSID.GRANTED_AUTHORITY = 'IS_AUTHENTICATED_ANONYMOUSLY') " + "group by AOI.ID), 0)"; - /** - * Query used to repopulate the EXPRESSION_EXPERIMENT2CHARACTERISTIC table. - */ - private static final String E2C_QUERY = - "insert into EXPRESSION_EXPERIMENT2CHARACTERISTIC (ID, NAME, DESCRIPTION, CATEGORY, CATEGORY_URI, `VALUE`, VALUE_URI, ORIGINAL_VALUE, EVIDENCE_CODE, EXPRESSION_EXPERIMENT_FK, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK, LEVEL) " - + "select C.ID, C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(:eeClass as char(256)) " + + private static final String EE2C_EE_QUERY = + "select MIN(C.ID), C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(? as char(256)) " + "from INVESTIGATION I " + "join CHARACTERISTIC C on I.ID = C.INVESTIGATION_FK " + "where I.class = 'ExpressionExperiment' " - + "union " - + "select C.ID, C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(:bmClass as char(255)) " + + "group by I.ID, COALESCE(C.CATEGORY_URI, C.CATEGORY), COALESCE(C.VALUE_URI, C.`VALUE`)"; + + private static final String EE2C_BM_QUERY = + "select MIN(C.ID), C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(? as char(255)) " + "from INVESTIGATION I " + "join BIO_ASSAY BA on I.ID = BA.EXPRESSION_EXPERIMENT_FK " + "join BIO_MATERIAL BM on BA.SAMPLE_USED_FK = BM.ID " + "join CHARACTERISTIC C on BM.ID = C.BIO_MATERIAL_FK " + "where I.class = 'ExpressionExperiment' " - + "union " - + "select C.ID, C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(:edClass as char(255)) " + + "group by I.ID, COALESCE(C.CATEGORY_URI, C.CATEGORY), COALESCE(C.VALUE_URI, C.`VALUE`)"; + + private static final String EE2C_ED_QUERY = + "select MIN(C.ID), C.NAME, C.DESCRIPTION, C.CATEGORY, C.CATEGORY_URI, C.`VALUE`, C.VALUE_URI, C.ORIGINAL_VALUE, C.EVIDENCE_CODE, I.ID, (" + SELECT_ANONYMOUS_MASK + "), cast(? as char(255)) " + "from INVESTIGATION I " + "join EXPERIMENTAL_DESIGN on I.EXPERIMENTAL_DESIGN_FK = EXPERIMENTAL_DESIGN.ID " + "join EXPERIMENTAL_FACTOR EF on EXPERIMENTAL_DESIGN.ID = EF.EXPERIMENTAL_DESIGN_FK " @@ -115,21 +115,24 @@ public class TableMaintenanceUtilImpl implements TableMaintenanceUtil { + "join CHARACTERISTIC C on FV.ID = C.FACTOR_VALUE_FK " // remove C.class = 'Statement' once the old-style characteristics are removed (see https://github.com/PavlidisLab/Gemma/issues/929 for details) + "where I.class = 'ExpressionExperiment' and C.class = 'Statement' " - + "on duplicate key update NAME = VALUES(NAME), DESCRIPTION = VALUES(DESCRIPTION), CATEGORY = VALUES(CATEGORY), CATEGORY_URI = VALUES(CATEGORY_URI), `VALUE` = VALUES(`VALUE`), VALUE_URI = VALUES(VALUE_URI), ORIGINAL_VALUE = VALUES(ORIGINAL_VALUE), EVIDENCE_CODE = VALUES(EVIDENCE_CODE), ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK = VALUES(ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK)"; + + "group by I.ID, COALESCE(C.CATEGORY_URI, C.CATEGORY), COALESCE(C.VALUE_URI, C.`VALUE`)"; private static final String EE2AD_QUERY = "insert into EXPRESSION_EXPERIMENT2ARRAY_DESIGN (EXPRESSION_EXPERIMENT_FK, ARRAY_DESIGN_FK, IS_ORIGINAL_PLATFORM, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK) " + "select I.ID, AD.ID, FALSE, (" + SELECT_ANONYMOUS_MASK + ") from INVESTIGATION I " + "join BIO_ASSAY BA on I.ID = BA.EXPRESSION_EXPERIMENT_FK " + "join ARRAY_DESIGN AD on BA.ARRAY_DESIGN_USED_FK = AD.ID " + + "where I.class = 'ExpressionExperiment' " + "group by I.ID, AD.ID " + "union " + "select I.ID, AD.ID, TRUE, (" + SELECT_ANONYMOUS_MASK + ") from INVESTIGATION I " + "join BIO_ASSAY BA on I.ID = BA.EXPRESSION_EXPERIMENT_FK " + "join ARRAY_DESIGN AD on BA.ORIGINAL_PLATFORM_FK = AD.ID " + + "where I.class = 'ExpressionExperiment' " + "group by I.ID, AD.ID " + "on duplicate key update ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK = VALUES(ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK)"; - private static final Path DEFAULT_GENE2CS_INFO_PATH = Paths.get( Settings.getString( "gemma.appdata.home" ), "DbReports", "gene2cs.info" ); + private static final Log log = LogFactory.getLog( TableMaintenanceUtil.class.getName() ); + @Autowired private AuditEventService auditEventService; @@ -142,7 +145,12 @@ public class TableMaintenanceUtilImpl implements TableMaintenanceUtil { @Autowired private SessionFactory sessionFactory; - private Path gene2CsInfoPath = DEFAULT_GENE2CS_INFO_PATH; + @Value("${gemma.gene2cs.path}") + private Path gene2CsInfoPath; + + @Value("${gemma.admin.email}") + private String adminEmailAddress; + private boolean sendEmail = true; @Override @@ -217,16 +225,52 @@ public void updateGene2CsEntries() { @Timed public int updateExpressionExperiment2CharacteristicEntries() { log.info( "Updating the EXPRESSION_EXPERIMENT2CHARACTERISTIC table..." ); - int updated = sessionFactory.getCurrentSession().createSQLQuery( E2C_QUERY ) + int updated = sessionFactory.getCurrentSession() + .createSQLQuery( + "insert into EXPRESSION_EXPERIMENT2CHARACTERISTIC (ID, NAME, DESCRIPTION, CATEGORY, CATEGORY_URI, `VALUE`, VALUE_URI, ORIGINAL_VALUE, EVIDENCE_CODE, EXPRESSION_EXPERIMENT_FK, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK, LEVEL) " + + EE2C_EE_QUERY + + " union " + + EE2C_BM_QUERY + + " union " + + EE2C_ED_QUERY + " " + + "on duplicate key update NAME = VALUES(NAME), DESCRIPTION = VALUES(DESCRIPTION), CATEGORY = VALUES(CATEGORY), CATEGORY_URI = VALUES(CATEGORY_URI), `VALUE` = VALUES(`VALUE`), VALUE_URI = VALUES(VALUE_URI), ORIGINAL_VALUE = VALUES(ORIGINAL_VALUE), EVIDENCE_CODE = VALUES(EVIDENCE_CODE), ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK = VALUES(ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK), LEVEL = VALUES(LEVEL)" ) .addSynchronizedQuerySpace( EE2C_QUERY_SPACE ) - .setParameter( "eeClass", ExpressionExperiment.class ) - .setParameter( "bmClass", BioMaterial.class ) - .setParameter( "edClass", ExperimentalDesign.class ) + .setParameter( 0, ExpressionExperiment.class ) + .setParameter( 1, BioMaterial.class ) + .setParameter( 2, ExperimentalDesign.class ) .executeUpdate(); log.info( String.format( "Done updating the EXPRESSION_EXPERIMENT2CHARACTERISTIC table; %d entries were updated.", updated ) ); return updated; } + @Override + @Timed + @Transactional + public int updateExpressionExperiment2CharacteristicEntries( Class level ) { + String query; + if ( level.equals( ExpressionExperiment.class ) ) { + query = EE2C_EE_QUERY; + } else if ( level.equals( BioMaterial.class ) ) { + query = EE2C_BM_QUERY; + } else if ( level.equals( ExperimentalDesign.class ) ) { + query = EE2C_ED_QUERY; + } else { + throw new IllegalArgumentException( "Level must be one of ExpressionExperiment.class, BioMaterial.class or ExperimentalDesign.class." ); + } + log.info( "Updating the EXPRESSION_EXPERIMENT2CHARACTERISTIC table at level " + level + "..." ); + int updated = sessionFactory.getCurrentSession() + .createSQLQuery( + "insert into EXPRESSION_EXPERIMENT2CHARACTERISTIC (ID, NAME, DESCRIPTION, CATEGORY, CATEGORY_URI, `VALUE`, VALUE_URI, ORIGINAL_VALUE, EVIDENCE_CODE, EXPRESSION_EXPERIMENT_FK, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK, LEVEL) " + + query + " " + + "on duplicate key update NAME = VALUES(NAME), DESCRIPTION = VALUES(DESCRIPTION), CATEGORY = VALUES(CATEGORY), CATEGORY_URI = VALUES(CATEGORY_URI), `VALUE` = VALUES(`VALUE`), VALUE_URI = VALUES(VALUE_URI), ORIGINAL_VALUE = VALUES(ORIGINAL_VALUE), EVIDENCE_CODE = VALUES(EVIDENCE_CODE), ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK = VALUES(ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK), LEVEL = VALUES(LEVEL)" ) + .addSynchronizedQuerySpace( EE2C_QUERY_SPACE ) + .setParameter( 0, level ) + .executeUpdate(); + log.info( String.format( "Done updating the EXPRESSION_EXPERIMENT2CHARACTERISTIC table at %s level; %d entries were updated.", + level.getSimpleName(), updated ) ); + return updated; + } + @Override @Transactional public int updateExpressionExperiment2ArrayDesignEntries() { @@ -238,14 +282,6 @@ public int updateExpressionExperiment2ArrayDesignEntries() { return updated; } - /** - * For use in tests. - */ - @Override - public void setGene2CsInfoPath( Path gene2CsInfoPath ) { - this.gene2CsInfoPath = gene2CsInfoPath; - } - /** * For use in tests. */ @@ -289,7 +325,6 @@ private void sendEmail( Gene2CsStatus results ) { if ( !sendEmail ) return; SimpleMailMessage msg = new SimpleMailMessage(); - String adminEmailAddress = Settings.getAdminEmailAddress(); if ( StringUtils.isBlank( adminEmailAddress ) ) { TableMaintenanceUtilImpl.log .warn( "No administrator email address could be found, so gene2cs status email will not be sent." ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDao.java index 403ab86181..97935314af 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDao.java @@ -56,10 +56,15 @@ Collection find( Gene gene, ExpressionAnalysisRe double threshold ); /** - * @return analyses associated with the factor, either through the subsetfactor or as factors for resultsets. + * Retrieve analyses associated with the factor, either through the subset factor or as factors for result sets. */ Collection findByFactor( ExperimentalFactor ef ); + /** + * @see #findByFactor(ExperimentalFactor) + */ + Collection findByFactors( Collection experimentalFactors ); + Map> findByExperimentIds( Collection investigationIds ); Collection findExperimentsWithAnalyses( Gene gene ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoImpl.java index a4ee6d20c2..aa49bfdc75 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoImpl.java @@ -291,24 +291,57 @@ public Collection find( Gene gene, ExpressionAna @Override public Collection findByFactor( ExperimentalFactor ef ) { + Set results = new HashSet<>(); // subset factorValues factors. - @SuppressWarnings("unchecked") - Collection result = this.getSessionFactory().getCurrentSession() - .createQuery( "select distinct a from DifferentialExpressionAnalysis a join a.subsetFactorValue ssf" - + " join ssf.experimentalFactor efa where efa = :ef " ) + //noinspection unchecked + results.addAll( this.getSessionFactory().getCurrentSession() + .createQuery( "select distinct a from DifferentialExpressionAnalysis a " + + "join a.subsetFactorValue ssf " + + "where ssf.experimentalFactor = :ef" ) .setParameter( "ef", ef ) - .list(); + .list() ); // factors used in the analysis. //noinspection unchecked - result.addAll( this.getSessionFactory().getCurrentSession() - .createQuery( "select distinct a from DifferentialExpressionAnalysis a join a.resultSets rs" - + " left join rs.baselineGroup bg join rs.experimentalFactors efa where efa = :ef " ) + results.addAll( this.getSessionFactory().getCurrentSession() + .createQuery( "select distinct a from DifferentialExpressionAnalysis a " + + "join a.resultSets rs " + + "join rs.experimentalFactors efa " + + "where efa = :ef" ) .setParameter( "ef", ef ) .list() ); - return result; + return results; + } + + @Override + public Collection findByFactors( Collection experimentalFactors ) { + if ( experimentalFactors.isEmpty() ) { + return Collections.emptySet(); + } + + Set results = new HashSet<>(); + // subset factorValues factors. + //noinspection unchecked + results.addAll( this.getSessionFactory().getCurrentSession() + .createQuery( "select distinct a from DifferentialExpressionAnalysis a " + + "join a.subsetFactorValue ssf " + + "where ssf.experimentalFactor in :efs" ) + .setParameterList( "efs", experimentalFactors ) + .list() ); + + // factors used in the analysis + //noinspection unchecked + results.addAll( this.getSessionFactory().getCurrentSession() + .createQuery( "select distinct a from DifferentialExpressionAnalysis a " + + "join a.resultSets rs " + + "join rs.experimentalFactors efa " + + "where efa in :efs" ) + .setParameterList( "efs", experimentalFactors ) + .list() ); + + return results; } @Override diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisService.java index 63066df668..70f01865e5 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisService.java @@ -133,4 +133,11 @@ Map> getAnalysesByExperiment( Collection ids, int offset, int limit ); + /** + * Remove analyses using the given factor. + * @return the number of analysis removed + */ + int removeForExperimentalFactor( ExperimentalFactor experimentalFactor ); + + int removeForExperimentalFactors( Collection experimentalFactors ); } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisServiceImpl.java index f3b6ab521e..a964eb42e2 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisServiceImpl.java @@ -253,6 +253,22 @@ public void removeForExperiment( BioAssaySet ee ) { this.remove( diffAnalyses ); } + @Override + @Transactional + public int removeForExperimentalFactor( ExperimentalFactor experimentalFactor ) { + Collection found = differentialExpressionAnalysisDao.findByFactor( experimentalFactor ); + this.remove( found ); + return found.size(); + } + + @Override + @Transactional + public int removeForExperimentalFactors( Collection experimentalFactors ) { + Collection found = differentialExpressionAnalysisDao.findByFactors( experimentalFactors ); + this.remove( found ); + return found.size(); + } + @Override @Transactional(readOnly = true) public Collection findByExperiment( BioAssaySet experiment ) { diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDao.java index 409d58ab26..e89cac8dfa 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDao.java @@ -19,10 +19,8 @@ package ubic.gemma.persistence.service.analysis.expression.diff; import ubic.basecode.math.distribution.Histogram; -import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; import ubic.gemma.model.analysis.expression.diff.*; import ubic.gemma.model.expression.experiment.BioAssaySet; -import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.ExpressionExperimentValueObject; import ubic.gemma.model.genome.Gene; import ubic.gemma.persistence.service.BaseDao; @@ -39,93 +37,52 @@ public interface DifferentialExpressionResultDao extends BaseDao> find( Gene gene, + Map> findByGeneAndExperimentAnalyzed( Gene gene, Collection experimentsAnalyzed, double threshold, int limit ); /** * Given a list of experiments and a threshold value finds all the probes that met the cut off in the given * experiments - * - * @param experimentsAnalyzed ees - * @param threshold threshold - * @param limit limit - * @return map to diff exp VOs */ - Map> find( + Map> findByExperimentAnalyzed( Collection experimentsAnalyzed, double threshold, int limit ); /** - * @param gene gene - * @return a map of a collection of {@link DifferentialExpressionAnalysisResult}s keyed by {@link BioAssaySet}. + * Find differential expression results for a given gene, grouped by experiment. + * @return a map of a collection of {@link DifferentialExpressionAnalysisResult}s keyed by {@link BioAssaySet}. */ - Map> find( Gene gene ); + Map> findByGene( Gene gene ); /** - * @param gene gene - * @param experimentsAnalyzed ees - * @return a map of a collection of {@link DifferentialExpressionAnalysisResult}s keyed by + * Find differential expression results for a given gene and set of experiments, grouped by experiment. + * @return a map of a collection of {@link DifferentialExpressionAnalysisResult}s keyed by * {@link BioAssaySet}. */ - Map> find( Gene gene, + Map> findByGeneAndExperimentAnalyzed( Gene gene, Collection experimentsAnalyzed ); /** - * @param geneIds gene ids - * @param resultSets result sets - * @return map of resultSetId to map of gene to DiffExprGeneSearchResult + * @return map of resultSetId to map of gene to DiffExprGeneSearchResult */ Map> findDiffExAnalysisResultIdsInResultSets( Collection resultSets, Collection geneIds ); - List findGeneInResultSets( Gene gene, ExpressionAnalysisResultSet resultSet, - Collection arrayDesignIds, int limit ); - List findInResultSet( ExpressionAnalysisResultSet resultSet, Double threshold, int maxResultsToReturn, int minNumberOfResults ); - /** - * Given a list of result sets finds the diff expression results that met the given threshold - * - * @param resultsAnalyzed resultsAnalyzed - * @param threshold threshold - * @param limit limit - * @return map to diff exp VOs - */ - Map> findInResultSets( - Collection resultsAnalyzed, double threshold, int limit ); - - DifferentialExpressionAnalysis getAnalysis( ExpressionAnalysisResultSet rs ); - - Collection getExperimentalFactors( - DifferentialExpressionAnalysisResult differentialExpressionAnalysisResult ); - - Map> getExperimentalFactors( - Collection differentialExpressionAnalysisResults ); - Map loadContrastDetailsForResults( Collection ids ); - void thaw( Collection results ); - - void thaw( final DifferentialExpressionAnalysisResult result ); - /** * Find differential expression for a gene, exceeding a given significance level (using the corrected pvalue field) * * @param gene gene * @param threshold threshold * @param limit limit - * @return map to diff exp VOs + * @return map to diff exp VOs */ Map> find( Gene gene, double threshold, int limit ); Histogram loadPvalueDistribution( Long resultSetId ); - } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoImpl.java index 607e529f43..209562d31f 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoImpl.java @@ -21,21 +21,22 @@ import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.time.StopWatch; import org.hibernate.*; -import org.hibernate.type.StandardBasicTypes; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Repository; +import org.springframework.util.Assert; import ubic.basecode.io.ByteArrayConverter; import ubic.basecode.math.distribution.Histogram; import ubic.basecode.util.BatchIterator; import ubic.basecode.util.SQLUtils; import ubic.gemma.model.analysis.expression.diff.*; -import ubic.gemma.model.expression.designElement.CompositeSequence; -import ubic.gemma.model.expression.experiment.*; +import ubic.gemma.model.expression.experiment.BioAssaySet; +import ubic.gemma.model.expression.experiment.ExperimentalFactor; +import ubic.gemma.model.expression.experiment.ExperimentalFactorValueObject; +import ubic.gemma.model.expression.experiment.ExpressionExperimentValueObject; import ubic.gemma.model.genome.Gene; import ubic.gemma.model.genome.gene.GeneValueObject; import ubic.gemma.persistence.service.AbstractDao; import ubic.gemma.persistence.util.CommonQueries; -import ubic.gemma.persistence.util.EntityUtils; import ubic.gemma.persistence.util.TaskCancelledException; import java.math.BigInteger; @@ -53,61 +54,15 @@ public class DifferentialExpressionResultDaoImpl extends AbstractDao> find( Gene gene, + public Map> findByGeneAndExperimentAnalyzed( Gene gene, Collection experimentsAnalyzed, double threshold, int limit ) { - - StopWatch timer = new StopWatch(); - timer.start(); - String qs = DifferentialExpressionResultDaoImpl.fetchResultsByGeneAndExperimentsQuery - + " and r.correctedPvalue < :threshold"; - - if ( limit > 0 ) { - qs += " order by r.correctedPvalue"; - } - - Map> results = new HashMap<>(); - - if ( experimentsAnalyzed.size() == 0 ) { - return results; + if ( experimentsAnalyzed.isEmpty() ) { + return Collections.emptyMap(); } + StopWatch timer = StopWatch.createStarted(); List qResult = getSessionFactory().getCurrentSession() - .createQuery( qs ) + .createQuery( DIFF_EX_RESULTS_BY_GENE_QUERY + " and e.id in (:experimentAnalyzed)" + + ( limit > 0 ? " order by r.correctedPvalue" : "" ) ) .setParameter( "gene", gene ) .setParameterList( "experimentsAnalyzed", experimentsAnalyzed ) .setParameter( "threshold", threshold ) @@ -158,142 +102,98 @@ public Map() ); - } - - results.get( ee ).add( new DifferentialExpressionValueObject( probeResult ) ); - } - - AbstractDao.log - .warn( "Num experiments with probe analysis results (with limit = " + limit + ") : " + results.size() - + ". Number of probes returned in total: " + qResult.size() ); + Map> results = groupDiffExResultVos( qResult ); + AbstractDao.log.info( String.format( "Num experiments with probe analysis results (with limit = %d) : %d. Number of probes returned in total: %d", + limit, results.size(), qResult.size() ) ); timer.stop(); if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); + AbstractDao.log.warn( "Diff ex results: " + timer.getTime() + " ms" ); } return results; } @Override - public Map> find( + public Map> findByExperimentAnalyzed( Collection experiments, double qvalueThreshold, int limit ) { - - Map> results = new HashMap<>(); - - if ( experiments.size() == 0 ) { - return results; + if ( experiments.isEmpty() ) { + return Collections.emptyMap(); } - - StopWatch timer = new StopWatch(); - timer.start(); - + StopWatch timer = StopWatch.createStarted(); List qResult = getSessionFactory().getCurrentSession() - .createQuery( DifferentialExpressionResultDaoImpl.fetchResultsByExperimentsQuery ) + .createQuery( "select e, r from DifferentialExpressionAnalysis a " + + "join a.experimentAnalyzed e " + + "join a.resultSets rs join rs.results r " + + "where e.id in (:experimentsAnalyzed) and r.correctedPvalue < :threshold" + + ( limit > 0 ? " order by r.correctedPvalue" : "" ) ) .setParameterList( "experimentsAnalyzed", experiments ) .setParameter( "threshold", qvalueThreshold ) .setMaxResults( limit ) .setCacheable( true ) .setCacheRegion( "diffExResult" ) .list(); - - for ( Object o : qResult ) { - - Object[] oa = ( Object[] ) o; - DifferentialExpressionAnalysisResult probeResult = ( DifferentialExpressionAnalysisResult ) oa[1]; - ExpressionExperimentValueObject eevo = ( ( BioAssaySet ) oa[0] ).createValueObject(); - if ( !results.containsKey( eevo ) ) { - results.put( eevo, new ArrayList() ); + try { + return groupDiffExResultVos( qResult ); + } finally { + timer.stop(); + if ( timer.getTime() > 1000 ) { + AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); } - - results.get( eevo ).add( new DifferentialExpressionValueObject( probeResult ) ); - } - - timer.stop(); - if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); } - - return results; } @Override - public Map> find( Gene gene ) { - StopWatch timer = new StopWatch(); - timer.start(); - Map> results = new HashMap<>(); - if ( gene == null ) - return results; - - List qResult = getSessionFactory().getCurrentSession().createQuery( DifferentialExpressionResultDaoImpl.fetchResultsByGene ) + public Map> findByGene( Gene gene ) { + Assert.notNull( gene ); + StopWatch timer = StopWatch.createStarted(); + List qResult = getSessionFactory().getCurrentSession() + .createQuery( DIFF_EX_RESULTS_BY_GENE_QUERY ) .setParameter( "gene", gene ) .setCacheable( true ) .list(); - - for ( Object o : qResult ) { - - Object[] oa = ( Object[] ) o; - ExpressionExperimentValueObject ee = ( ( BioAssaySet ) oa[0] ).createValueObject(); - DifferentialExpressionValueObject probeResult = new DifferentialExpressionValueObject( - ( DifferentialExpressionAnalysisResult ) oa[1] ); - - if ( !results.containsKey( ee ) ) { - results.put( ee, new ArrayList() ); + try { + return groupDiffExResultVos( qResult ); + } finally { + timer.stop(); + if ( timer.getTime() > 1000 ) { + AbstractDao.log.warn( "Diff ex results: " + timer.getTime() + " ms" ); } - - results.get( ee ).add( probeResult ); - } - timer.stop(); - if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); } - return results; } @Override - public Map> find( Gene gene, + public Map> findByGeneAndExperimentAnalyzed( Gene gene, Collection experimentsAnalyzed ) { - - Map> results = new HashMap<>(); - - if ( experimentsAnalyzed.size() == 0 ) { - return results; + Assert.notNull( gene ); + if ( experimentsAnalyzed.isEmpty() ) { + return Collections.emptyMap(); } - - StopWatch timer = new StopWatch(); - timer.start(); - + StopWatch timer = StopWatch.createStarted(); List qResult = this.getSessionFactory().getCurrentSession() - .createQuery( DifferentialExpressionResultDaoImpl.fetchResultsByGeneAndExperimentsQuery ) + .createQuery( DIFF_EX_RESULTS_BY_GENE_QUERY + " and e.id in (:experimentsAnalyzed)" ) .setParameter( "gene", gene ) .setParameterList( "experimentsAnalyzed", experimentsAnalyzed ) .list(); + try { + return groupDiffExResultVos( qResult ); + } finally { + timer.stop(); + if ( timer.getTime() > 1000 ) { + AbstractDao.log.warn( "Diff ex results: " + timer.getTime() + " ms" ); + } + } + } + private Map> groupDiffExResultVos( List qResult ) { + Map> results = new HashMap<>(); for ( Object o : qResult ) { - Object[] oa = ( Object[] ) o; - ExpressionExperimentValueObject ee = new ExpressionExperimentValueObject( ( ExpressionExperiment ) oa[0] ); - DifferentialExpressionValueObject probeResult = new DifferentialExpressionValueObject( - ( DifferentialExpressionAnalysisResult ) oa[1] ); - probeResult.setExpressionExperiment( ee ); - - if ( !results.containsKey( ee ) ) { - results.put( ee, new ArrayList() ); - } - - results.get( ee ).add( probeResult ); - } - timer.stop(); - if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); + ExpressionExperimentValueObject ee = ( ( BioAssaySet ) oa[0] ).createValueObject(); + DifferentialExpressionAnalysisResult dear = ( DifferentialExpressionAnalysisResult ) oa[1]; + Hibernate.initialize( dear.getProbe() ); + DifferentialExpressionValueObject probeResult = new DifferentialExpressionValueObject( dear ); + results.computeIfAbsent( ee, k -> new ArrayList<>() ).add( probeResult ); } return results; } @@ -331,8 +231,11 @@ public Map> findDiffExAnalysisResultId assert !resultSetsNeeded.isEmpty(); - org.hibernate.SQLQuery queryObject = session.createSQLQuery( - DifferentialExpressionResultDaoImpl.fetchBatchDifferentialExpressionAnalysisResultsByResultSetsAndGeneQuery ); + SQLQuery queryObject = session.createSQLQuery( + "SELECT dear.PROBE_FK, dear.ID," + + " dear.RESULT_SET_FK, dear.CORRECTED_PVALUE, dear.PVALUE " + + " FROM DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT dear FORCE INDEX (probeResultSets) WHERE dear.RESULT_SET_FK IN (:rs_ids) AND " + + " dear.PROBE_FK IN (:probe_ids) " ); /* * These values have been tweaked to probe for performance issues. @@ -352,7 +255,7 @@ public Map> findDiffExAnalysisResultId + " resultSets; batch size=" + geneBatchSize ); } - final int numResultSetBatches = ( int ) Math.ceil( resultSetsNeeded.size() / resultSetBatchSize ); + final int numResultSetBatches = ( int ) Math.ceil( ( double ) resultSetsNeeded.size() / ( double ) resultSetBatchSize ); queryObject.setFlushMode( FlushMode.MANUAL ); @@ -382,7 +285,7 @@ public Map> findDiffExAnalysisResultId queryObject.setParameterList( "rs_ids", resultSetIdBatch ); int numGeneBatchesDone = 0; - final int numGeneBatches = ( int ) Math.ceil( cs2GeneIdMap.size() / geneBatchSize ); + final int numGeneBatches = ( int ) Math.ceil( ( double ) cs2GeneIdMap.size() / ( double ) geneBatchSize ); StopWatch innerQt = new StopWatch(); @@ -478,65 +381,25 @@ public Map> findDiffExAnalysisResultId return results; } - @Override - public List findGeneInResultSets( Gene gene, ExpressionAnalysisResultSet resultSet, - Collection arrayDesignIds, int limit ) { - - StopWatch timer = new StopWatch(); - timer.start(); - - List results; - - Session session = this.getSessionFactory().getCurrentSession(); - org.hibernate.SQLQuery queryObject = session - .createSQLQuery( DifferentialExpressionResultDaoImpl.fetchResultsByResultSetAndGeneQuery ); - - queryObject.setLong( "gene_id", gene.getId() ); - queryObject.setLong( "rs_id", resultSet.getId() ); - - queryObject.setMaxResults( limit ); - - queryObject.addScalar( "CORRECTED_PVALUE", StandardBasicTypes.DOUBLE ); - //noinspection unchecked - results = queryObject.list(); - - timer.stop(); - if ( AbstractDao.log.isDebugEnabled() ) - AbstractDao.log - .debug( "Fetching probeResults from resultSet " + resultSet.getId() + " for gene " + gene.getId() - + "and " + arrayDesignIds.size() + "arrays took : " + timer.getTime() + " ms" ); - - return results; - } - @Override public List findInResultSet( ExpressionAnalysisResultSet resultSet, Double threshold, int limit, int minNumberOfResults ) { + Assert.notNull( resultSet, "The result set must not be null." ); + Assert.isTrue( minNumberOfResults > 0, "Minimum number of results must be greater than zero." ); - if ( minNumberOfResults < 1 ) { - throw new IllegalArgumentException( "Minimum number of results must be greater than one" ); - } - - List results = new ArrayList<>(); - - if ( resultSet == null ) { - return results; - } - - results = differentialExpressionResultCache.getTopHits( resultSet ); - if ( results != null && results.size() >= minNumberOfResults ) { + // check for top hits in cache + List cachedResults = differentialExpressionResultCache.getTopHits( resultSet ); + if ( cachedResults != null && cachedResults.size() >= minNumberOfResults ) { AbstractDao.log.info( "Top hits already in cache" ); - return results; + return cachedResults; } - results = new ArrayList<>(); - - // get it. - + // retrieve top hits from database StopWatch timer = new StopWatch(); timer.start(); - String qs = DifferentialExpressionResultDaoImpl.fetchResultsBySingleResultSetQuery - + " and r.correctedPvalue <= :threshold order by r.correctedPvalue"; + String qs = "select r from DifferentialExpressionAnalysisResult r " + + "where r.resultSet = :resultSet and r.correctedPvalue <= :threshold " + + "order by r.correctedPvalue"; List qResult = getSessionFactory().getCurrentSession().createQuery( qs ) .setParameter( "resultSet", resultSet ) @@ -548,140 +411,31 @@ public List findInResultSet( ExpressionAnalys if ( qResult.size() < minNumberOfResults ) { // FIXME this is kind of dumb. If we always return the top minimum, why not just always get that? AbstractDao.log.info( "Too few results met threshold, repeating to just get the top hits" ); - qs = DifferentialExpressionResultDaoImpl.fetchResultsBySingleResultSetQuery + " order by r.correctedPvalue"; + qs = "select r from DifferentialExpressionAnalysisResult r " + + "where r.resultSet = :resultSet " + + "order by r.correctedPvalue"; qResult = getSessionFactory().getCurrentSession().createQuery( qs ) .setParameter( "resultSet", resultSet ) .setMaxResults( minNumberOfResults ) .list(); } + List results = new ArrayList<>(); for ( Object o : qResult ) { - DifferentialExpressionValueObject probeResult = new DifferentialExpressionValueObject( - ( DifferentialExpressionAnalysisResult ) o ); + DifferentialExpressionAnalysisResult dear = ( DifferentialExpressionAnalysisResult ) o; + Hibernate.initialize( dear.getProbe() ); + DifferentialExpressionValueObject probeResult = new DifferentialExpressionValueObject( dear ); results.add( probeResult ); } - timer.stop(); - if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); - } - differentialExpressionResultCache.addToTopHitsCache( resultSet, results ); - return results; - } - - /** - * Given a list of result sets finds the results that met the given threshold - * - * @param limit - max number of results to return. - */ - @Override - public Map> findInResultSets( - Collection resultsAnalyzed, double threshold, int limit ) { - - Map> results = new HashMap<>(); - - if ( resultsAnalyzed.size() == 0 ) { - return results; - } - - // Integer bin = Math.log10(threshold); - - StopWatch timer = new StopWatch(); - timer.start(); - String qs = DifferentialExpressionResultDaoImpl.fetchResultsByResultSetQuery - + " and r.correctedPvalue < :threshold order by r.correctedPvalue"; - - List qResult = getSessionFactory().getCurrentSession().createQuery( qs ) - .setParameterList( "resultsAnalyzed", resultsAnalyzed ) - .setParameter( "threshold", threshold ) - .setMaxResults( limit ) - .list(); - - for ( Object o : qResult ) { - - Object[] oa = ( Object[] ) o; - ExpressionAnalysisResultSet ee = ( ExpressionAnalysisResultSet ) oa[0]; - DifferentialExpressionAnalysisResult probeResult = ( DifferentialExpressionAnalysisResult ) oa[1]; - - if ( !results.containsKey( ee ) ) { - results.put( ee, new ArrayList() ); - } - - results.get( ee ).add( probeResult ); - } - timer.stop(); if ( timer.getTime() > 1000 ) { AbstractDao.log.info( "Diff ex results: " + timer.getTime() + " ms" ); } - return results; - } - - @Override - public DifferentialExpressionAnalysis getAnalysis( ExpressionAnalysisResultSet rs ) { - return ( DifferentialExpressionAnalysis ) this.getSessionFactory().getCurrentSession() - .createQuery( "select distinct a from DifferentialExpressionAnalysis a join a.resultSets r where r=:r" ) - .setParameter( "r", rs ) - .uniqueResult(); - } - - @Override - public Collection getExperimentalFactors( - DifferentialExpressionAnalysisResult differentialExpressionAnalysisResult ) { - - //noinspection unchecked - return this.getSessionFactory().getCurrentSession().createQuery( "select ef from ExpressionAnalysisResultSet rs" - + " inner join rs.results r inner join rs.experimentalFactors ef where r=:differentialExpressionAnalysisResult" ) - .setParameter( "differentialExpressionAnalysisResult", differentialExpressionAnalysisResult ).list(); - - } - - @Override - public Map> getExperimentalFactors( - Collection differentialExpressionAnalysisResults ) { - StopWatch timer = new StopWatch(); - timer.start(); - Map> factorsByResult = new HashMap<>(); - if ( differentialExpressionAnalysisResults.isEmpty() ) { - return factorsByResult; - } - - //language=HQL - final String queryString = "select rs.experimentalFactors, r from ExpressionAnalysisResultSet rs" - + " inner join rs.results r where r in (:differentialExpressionAnalysisResults)"; - - List qr = this.getSessionFactory().getCurrentSession() - .createQuery( queryString ) - .setParameterList( "differentialExpressionAnalysisResults", differentialExpressionAnalysisResults ) - .list(); - - if ( qr == null || qr.isEmpty() ) - return factorsByResult; - - for ( Object o : qr ) { - Object[] ar = ( Object[] ) o; - ExperimentalFactor f = ( ExperimentalFactor ) ar[0]; - DifferentialExpressionAnalysisResult res = ( DifferentialExpressionAnalysisResult ) ar[1]; - - assert differentialExpressionAnalysisResults.contains( res ); - - if ( !factorsByResult.containsKey( res ) ) { - factorsByResult.put( res, new HashSet() ); - } - - factorsByResult.get( res ).add( f ); - - if ( AbstractDao.log.isDebugEnabled() ) - AbstractDao.log.debug( res ); - } - timer.stop(); - if ( timer.getTime() > 1000 ) { - AbstractDao.log.info( "factors by results: " + timer.getTime() + " ms" ); - } - return factorsByResult; + return results; } /** @@ -690,9 +444,6 @@ public Map> @Override public Map loadContrastDetailsForResults( Collection ids ) { //language=SQL - final String queryString = "SELECT DISTINCT c.ID, c.LOG_FOLD_CHANGE, c.FACTOR_VALUE_FK," - + " c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK, c.PVALUE FROM CONTRAST_RESULT c" - + " WHERE c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK IN (:ids) "; Map probeResults = new HashMap<>(); @@ -700,7 +451,10 @@ public Map loadContrastDetailsForResults( Collection return probeResults; } - SQLQuery query = this.getSessionFactory().getCurrentSession().createSQLQuery( queryString ); + SQLQuery query = this.getSessionFactory().getCurrentSession() + .createSQLQuery( "SELECT DISTINCT c.ID, c.LOG_FOLD_CHANGE, c.FACTOR_VALUE_FK," + + " c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK, c.PVALUE FROM CONTRAST_RESULT c" + + " WHERE c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK IN (:ids) " ); int BATCH_SIZE = 2000; // previously: 500, then 1000. New optimized query is plenty fast. StopWatch timer = new StopWatch(); @@ -737,36 +491,15 @@ public Map loadContrastDetailsForResults( Collection if ( timer.getTime() > 2000 ) { AbstractDao.log.info( "Fetch " + batch.size() + " results with contrasts: " + timer.getTime() - + "ms; query was\n " + queryString.replace( ":ids", StringUtils.join( batch, "," ) ) ); + + "ms; query was\n " + ( "SELECT DISTINCT c.ID, c.LOG_FOLD_CHANGE, c.FACTOR_VALUE_FK," + + " c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK, c.PVALUE FROM CONTRAST_RESULT c" + + " WHERE c.DIFFERENTIAL_EXPRESSION_ANALYSIS_RESULT_FK IN (:ids) " ).replace( ":ids", StringUtils.join( batch, "," ) ) ); } } return probeResults; } - @Override - public void thaw( final Collection results ) { - for ( DifferentialExpressionAnalysisResult result : results ) { - Hibernate.initialize( result ); - CompositeSequence cs = result.getProbe(); - Hibernate.initialize( cs ); - Hibernate.initialize( result.getContrasts() ); - } - } - - @Override - public void thaw( final DifferentialExpressionAnalysisResult result ) { - Hibernate.initialize( result ); - - CompositeSequence cs = result.getProbe(); - Hibernate.initialize( cs ); - - Collection contrasts = result.getContrasts(); - for ( ContrastResult contrast : contrasts ) { - Hibernate.initialize( contrast.getFactorValue() ); - } - } - @Override public Map> find( Gene gene, double threshold, int limit ) { @@ -775,14 +508,16 @@ public Map 0.0 ) { sql = sql + " and d.CORRECTED_PVALUE < :threshold "; } if ( limit > 0 ) { - sql = sql + " order by d.PVALUE ASC "; + sql = sql + " order by d.PVALUE"; } SQLQuery query = session.createSQLQuery( sql ); @@ -849,9 +584,10 @@ public Map ees = session.createQuery( - "select ee, rs from ExpressionAnalysisResultSet rs join fetch rs.experimentalFactors join rs.analysis a join a.experimentAnalyzed ee" - + " where rs.id in (:rsids)" ) + List ees = session + .createQuery( "select ee, rs from ExpressionAnalysisResultSet rs " + + "join fetch rs.experimentalFactors join rs.analysis a join a.experimentAnalyzed ee " + + "where rs.id in (:rsids)" ) .setParameterList( "rsids", resultSets ).list(); /* @@ -862,7 +598,7 @@ public Map() ); + results.put( evo, new ArrayList<>() ); } for ( Iterator it = resultsInter.values().iterator(); it.hasNext(); ) { @@ -948,7 +684,7 @@ private int processResultTuple( Object resultRow, Map() ); + resultsFromDb.put( resultSetId, new HashMap<>() ); } assert cs2GeneIdMap.containsKey( probeId ); @@ -1030,11 +766,11 @@ private Map> fillFromCache( Map() ); + foundInCache.put( r, new HashSet<>() ); for ( DiffExprGeneSearchResult result : cached ) { if ( !results.containsKey( r ) ) { - results.put( r, new HashMap() ); + results.put( r, new HashMap<>() ); } results.get( r ).put( result.getGeneId(), result ); @@ -1116,9 +852,7 @@ private Map> getProbesForGenesInResultSetBatch( Session s * resultSet */ private void processDiffExResultHit( Map results, Long resultSetId, Long geneId, - Long resultId, Double correctedPvalue, Double uncorrectedPvalue ) { - - assert correctedPvalue != null; + Long resultId, double correctedPvalue, double uncorrectedPvalue ) { DiffExprGeneSearchResult r = results.get( geneId ); if ( r == null ) { // first encounter diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultService.java index f37d8c58a3..a7122e09cf 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultService.java @@ -115,38 +115,9 @@ Map> fi Map> findDiffExAnalysisResultIdsInResultSets( Collection resultSets, Collection geneIds ); - List findGeneInResultSet( Gene gene, ExpressionAnalysisResultSet resultSet, Collection arrayDesignIds, - int limit ); - List findInResultSet( ExpressionAnalysisResultSet ar, Double threshold, int maxResultsToReturn, int minNumberOfResults ); - /** - * Given a list of result sets finds the diff expression results that met the given threshold - * - * @param threshold threshold - * @param limit limit - * @return map to diff ex VOs - */ - @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "AFTER_ACL_MAP_READ" }) - Map> findInResultSets( - Collection resultsAnalyzed, double threshold, int limit ); - - /** - * Fetch the analysis associated with a result set. - * - * @param rs result set - * @return diff ex. - */ - DifferentialExpressionAnalysis getAnalysis( ExpressionAnalysisResultSet rs ); - - Map> getExperimentalFactors( - Collection differentialExpressionAnalysisResults ); - - @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "AFTER_ACL_COLLECTION_READ" }) - Collection getExperimentalFactors( - DifferentialExpressionAnalysisResult differentialExpressionAnalysisResult ); - /** * @param ids ids * @return map of result to contrasts value object. diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultServiceImpl.java index 06d18d1a2c..bbaa875380 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultServiceImpl.java @@ -24,7 +24,6 @@ import ubic.basecode.math.distribution.Histogram; import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; import ubic.gemma.model.analysis.expression.diff.*; -import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.ExpressionExperimentValueObject; import ubic.gemma.model.genome.Gene; import ubic.gemma.persistence.service.AbstractService; @@ -53,27 +52,27 @@ public DifferentialExpressionResultServiceImpl( DifferentialExpressionResultDao @Transactional(readOnly = true) public Map> find( Collection experimentsAnalyzed, double threshold, int limit ) { - return this.DERDao.find( experimentsAnalyzed, threshold, limit ); + return this.DERDao.findByExperimentAnalyzed( experimentsAnalyzed, threshold, limit ); } @Override @Transactional(readOnly = true) public Map> find( Gene gene ) { - return this.DERDao.find( gene ); + return this.DERDao.findByGene( gene ); } @Override @Transactional(readOnly = true) public Map> find( Gene gene, Collection experimentsAnalyzed ) { - return this.DERDao.find( gene, experimentsAnalyzed ); + return this.DERDao.findByGeneAndExperimentAnalyzed( gene, experimentsAnalyzed ); } @Override @Transactional(readOnly = true) public Map> find( Gene gene, Collection experimentsAnalyzed, double threshold, int limit ) { - return this.DERDao.find( gene, experimentsAnalyzed, threshold, limit ); + return this.DERDao.findByGeneAndExperimentAnalyzed( gene, experimentsAnalyzed, threshold, limit ); } @Override @@ -90,13 +89,6 @@ public Map> findDiffExAnalysisResultId return this.DERDao.findDiffExAnalysisResultIdsInResultSets( resultSets, geneIds ); } - @Override - @Transactional(readOnly = true) - public List findGeneInResultSet( Gene gene, ExpressionAnalysisResultSet resultSet, - Collection arrayDesignIds, int limit ) { - return this.DERDao.findGeneInResultSets( gene, resultSet, arrayDesignIds, limit ); - } - @Override @Transactional(readOnly = true) public List findInResultSet( ExpressionAnalysisResultSet resultSet, @@ -104,33 +96,6 @@ public List findInResultSet( ExpressionAnalys return this.DERDao.findInResultSet( resultSet, threshold, maxResultsToReturn, minNumberOfResults ); } - @Override - @Transactional(readOnly = true) - public Map> findInResultSets( - Collection resultsAnalyzed, double threshold, int limit ) { - return this.DERDao.findInResultSets( resultsAnalyzed, threshold, limit ); - } - - @Override - @Transactional(readOnly = true) - public DifferentialExpressionAnalysis getAnalysis( ExpressionAnalysisResultSet rs ) { - return this.DERDao.getAnalysis( rs ); - } - - @Override - @Transactional(readOnly = true) - public Map> getExperimentalFactors( - Collection differentialExpressionAnalysisResults ) { - return this.DERDao.getExperimentalFactors( differentialExpressionAnalysisResults ); - } - - @Override - @Transactional(readOnly = true) - public Collection getExperimentalFactors( - DifferentialExpressionAnalysisResult differentialExpressionAnalysisResult ) { - return this.DERDao.getExperimentalFactors( differentialExpressionAnalysisResult ); - } - @Override @Transactional(readOnly = true) public Map loadContrastDetailsForResults( Collection ids ) { @@ -142,5 +107,4 @@ public Map loadContrastDetailsForResults( Collection public Histogram loadPvalueDistribution( Long resultSetId ) { return this.DERDao.loadPvalueDistribution( resultSetId ); } - } \ No newline at end of file diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDao.java index 75db8cd857..4bd6c795ff 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDao.java @@ -20,8 +20,8 @@ import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysis; import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysisResult; -import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysisResultSetValueObject; +import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; import ubic.gemma.model.common.Identifiable; import ubic.gemma.model.common.description.DatabaseEntry; import ubic.gemma.model.expression.experiment.BioAssaySet; @@ -56,10 +56,10 @@ public interface ExpressionAnalysisResultSetDao extends AnalysisResultSetDao * This is much faster than navigating through the probe's alignments, transcripts and then genes as it uses the * internal GENE2CS table described in {@link TableMaintenanceUtil#updateGene2CsEntries()}. - * + *

* Note: Not all probes have associated genes, so you should use {@link Map#getOrDefault(Object, Object)} with an * empty collection to handle this case. */ @@ -76,5 +76,8 @@ public interface ExpressionAnalysisResultSetDao extends AnalysisResultSetDao findByBioAssaySetInAndDatabaseEntryInLimit( @Nullable Collection bioAssaySets, @Nullable Collection databaseEntries, @Nullable Filters filters, int offset, int limit, @Nullable Sort sort ); + /** + * Initialize the analysis and subset factor vale. + */ void thaw( ExpressionAnalysisResultSet ears ); } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDaoImpl.java index 82fd05d0db..aea15139e5 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/diff/ExpressionAnalysisResultSetDaoImpl.java @@ -27,10 +27,7 @@ import org.hibernate.type.StandardBasicTypes; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Repository; -import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysis; -import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysisResultSetValueObject; -import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; -import ubic.gemma.model.analysis.expression.diff.PvalueDistribution; +import ubic.gemma.model.analysis.expression.diff.*; import ubic.gemma.model.common.description.Characteristic; import ubic.gemma.model.common.description.DatabaseEntry; import ubic.gemma.model.common.protocol.Protocol; @@ -79,13 +76,17 @@ public ExpressionAnalysisResultSet loadWithResultsAndContrasts( Long id ) { ExpressionAnalysisResultSet ears = ( ExpressionAnalysisResultSet ) getSessionFactory().getCurrentSession() .createQuery( "select ears from ExpressionAnalysisResultSet ears " + "left join fetch ears.results res " - + "left join fetch res.probe probe " - + "left join fetch probe.biologicalCharacteristic bc " - + "left join fetch bc.sequenceDatabaseEntry " + "left join fetch res.contrasts " + "where ears.id = :rsId" ) .setParameter( "rsId", id ) .uniqueResult(); + if ( ears != null ) { + for ( DifferentialExpressionAnalysisResult r : ears.getResults() ) { + // will also initialize the biological characteristics and sequence database entries + // this is efficient because of batch loading and second-level caching + Hibernate.initialize( r.getProbe() ); + } + } if ( timer.getTime() > 1000 ) { log.info( String.format( "Loaded [%s id=%d] with results, probes and contrasts in %d ms.", elementClass.getName(), id, timer.getTime() ) ); @@ -139,12 +140,20 @@ public void thaw( ExpressionAnalysisResultSet ears ) { // this drastically reduces the number of columns fetched which would anyway be repeated Hibernate.initialize( ears.getAnalysis() ); Hibernate.initialize( ears.getAnalysis().getExperimentAnalyzed() ); + // it is faster to query those separately because there's a large number of rows fetched via the results & // contrasts and only a handful of factors Hibernate.initialize( ears.getExperimentalFactors() ); + // factor values are always eagerly fetched (see ExperimentalFactor.hbm.xml), so we don't need to initialize. // I still think it's neat to use stream API for that though in case we ever make them lazy: // resultSet.getExperimentalFactors().stream().forEach( Hibernate::initialize ); + + // this needs to be initialized because it does not appear in the experimental factors + if ( ears.getAnalysis().getSubsetFactorValue() != null ) { + Hibernate.initialize( ears.getAnalysis().getSubsetFactorValue() ); + Hibernate.initialize( ears.getAnalysis().getSubsetFactorValue().getExperimentalFactor() ); + } } @Override diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/PreparedCoexMatrices.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/PreparedCoexMatrices.java new file mode 100644 index 0000000000..2a9ab06bb9 --- /dev/null +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/PreparedCoexMatrices.java @@ -0,0 +1,35 @@ +/* + * The Gemma project + * + * Copyright (c) 2011 University of British Columbia + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on + * an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the + * specific language governing permissions and limitations under the License. + */ +package ubic.gemma.persistence.service.analysis.expression.sampleCoexpression; + +import ubic.gemma.model.analysis.expression.coexpression.SampleCoexpressionMatrix; + +import javax.annotation.Nullable; + +/** + * Helper class for sample coexpression analysis. + */ +public class PreparedCoexMatrices { + + public PreparedCoexMatrices( @Nullable SampleCoexpressionMatrix matrix, @Nullable SampleCoexpressionMatrix regressedMatrix ) { + this.matrix = matrix; + this.regressedMatrix = regressedMatrix; + } + + @Nullable + SampleCoexpressionMatrix matrix; + @Nullable + SampleCoexpressionMatrix regressedMatrix; +} diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisService.java index 08fa9cd586..35bb569ff6 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisService.java @@ -14,8 +14,11 @@ */ package ubic.gemma.persistence.service.analysis.expression.sampleCoexpression; +import org.springframework.transaction.annotation.Isolation; +import org.springframework.transaction.annotation.Transactional; import ubic.basecode.dataStructure.matrix.DoubleMatrix; import ubic.gemma.model.analysis.expression.coexpression.SampleCoexpressionAnalysis; +import ubic.gemma.model.analysis.expression.coexpression.SampleCoexpressionMatrix; import ubic.gemma.model.expression.bioAssay.BioAssay; import ubic.gemma.model.expression.experiment.ExpressionExperiment; @@ -57,6 +60,14 @@ public interface SampleCoexpressionAnalysisService { @Nullable DoubleMatrix loadBestMatrix( ExpressionExperiment ee ); + + @Transactional(readOnly = true) + @Nullable + public DoubleMatrix retrieveExisting( ExpressionExperiment ee ); + + @Transactional(readOnly = true) + PreparedCoexMatrices prepare( ExpressionExperiment ee ); + /** * Computes sample correlation matrices for the given experiment. If the experiment already has any, they are * removed. See {@link SampleCoexpressionAnalysis} for the description of the matrices that are computed. @@ -64,22 +75,8 @@ public interface SampleCoexpressionAnalysisService { * @param ee the experiment to create a sample correlation matrix for. * @return the regressed coexpression matrix if available, otherwise the full */ - DoubleMatrix compute( ExpressionExperiment ee ); - - /** - * Computes sample correlation matrices for the given experiment if necessary. - *

- * The computation happens if at least one of the following condition is met: - *

    - *
  • there is no {@link SampleCoexpressionAnalysis} for the given experiment
  • - *
  • the full coexpression matrix is null
  • - *
  • the regressed coexpression matrix is null and there is an important factor
  • - *
- * - * @see #compute(ExpressionExperiment) - * @return the regressed coexpression matrix if available, otherwise the full - */ - DoubleMatrix computeIfNecessary( ExpressionExperiment ee ); + @Transactional(isolation = Isolation.SERIALIZABLE) + DoubleMatrix compute( ExpressionExperiment ee, PreparedCoexMatrices matrices ); boolean hasAnalysis( ExpressionExperiment ee ); @@ -89,4 +86,5 @@ public interface SampleCoexpressionAnalysisService { * @param ee the experiment to remove the analysis for. */ void removeForExperiment( ExpressionExperiment ee ); -} \ No newline at end of file +} + diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisServiceImpl.java index 776e174c40..8cfe992744 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/analysis/expression/sampleCoexpression/SampleCoexpressionAnalysisServiceImpl.java @@ -116,44 +116,56 @@ public DoubleMatrix loadBestMatrix( ExpressionExperiment ee } @Override - @Transactional(isolation = Isolation.SERIALIZABLE) - public DoubleMatrix computeIfNecessary( ExpressionExperiment ee ) { + @Transactional(readOnly = true) + public DoubleMatrix retrieveExisting( ExpressionExperiment ee ) { ExpressionExperiment thawedee = this.expressionExperimentService.thawLite( ee ); SampleCoexpressionAnalysis analysis = sampleCoexpressionAnalysisDao.load( thawedee ); if ( analysis == null || analysis.getFullCoexpressionMatrix() == null || this.shouldComputeRegressed( thawedee, analysis ) ) { SampleCoexpressionAnalysisServiceImpl.log .info( String.format( SampleCoexpressionAnalysisServiceImpl.MSG_INFO_RUNNING_SCM, thawedee.getId() ) ); - return this.compute( thawedee ); + return null; } else { this.logCormatStatus( analysis, false ); return toDoubleMatrix( analysis.getBestCoexpressionMatrix() ); } } + + @Override + @Transactional(readOnly = true) + public PreparedCoexMatrices prepare( ExpressionExperiment ee ) { + // Create new analysis + Collection vectors = processedExpressionDataVectorService + .getProcessedDataVectors( ee ); + SampleCoexpressionMatrix matrix = this.getMatrix( ee, false, vectors ); + SampleCoexpressionMatrix regressedMatrix = this.getMatrix( ee, true, vectors ); + return new PreparedCoexMatrices( matrix, regressedMatrix ); + } + + /** * Unfortunately, this method breaks under high contention (see #400, * so we need to fully lock the database while undergoing using {@link Isolation#SERIALIZABLE} transaction isolation * level. This annotation also has to be appled to other methods of this class that call compute() directly or * indirectly. + * + * PP changed this to do more of the processing in a read-only transaction */ @Override @Transactional(isolation = Isolation.SERIALIZABLE) - public DoubleMatrix compute( ExpressionExperiment ee ) { + public DoubleMatrix compute( ExpressionExperiment ee, PreparedCoexMatrices matrices ) { + SampleCoexpressionMatrix matrix = matrices.matrix; + + if ( matrix == null ) { + throw new RuntimeException( "Full coexpression matrix could not be computed." ); + } ExpressionExperiment thawedee = this.expressionExperimentService.thawLite( ee ); // Remove any old data this.removeForExperiment( thawedee ); - // Create new analysis - Collection vectors = processedExpressionDataVectorService - .getProcessedDataVectors( thawedee ); - SampleCoexpressionMatrix matrix = this.getMatrix( thawedee, false, vectors ); - SampleCoexpressionMatrix regressedMatrix = this.getMatrix( thawedee, true, vectors ); - - if ( matrix == null ) { - throw new RuntimeException( "Full coexpression matrix could not be computed." ); - } + SampleCoexpressionMatrix regressedMatrix = matrices.regressedMatrix; // this one is optional // this one is optional if ( regressedMatrix == null ) { @@ -408,3 +420,5 @@ private ExpressionDataDoubleMatrix regressionResiduals( ExpressionDataDoubleMatr return new ExpressionDataDoubleMatrix( dmatrix, f, dmatrix.getQuantitationTypes() ); } } + + diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionDaoImpl.java index f1ffd82883..08b5579d61 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionDaoImpl.java @@ -2083,11 +2083,12 @@ private void removeGeneCoexpressedWith( Long geneId, Collection removedGen .createQuery( "from GeneCoexpressedGenes where geneId = :id" ).setParameter( "id", geneId ) .uniqueResult(); // note this might be a no-op. - for ( Long g : removedGenes ) { - gcti.removeEntity( g ); - sess.update( gcti ); + if ( gcti != null ) { + for ( Long g : removedGenes ) { + gcti.removeEntity( g ); + sess.update( gcti ); + } } - } /** diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionQueryQueueImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionQueryQueueImpl.java index 8543a56d07..479e5aa262 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionQueryQueueImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/association/coexpression/CoexpressionQueryQueueImpl.java @@ -43,7 +43,7 @@ class CoexpressionQueryQueueImpl implements CoexpressionQueryQueue, Initializing private final CoexpressionDao coexpressionDao; private final GeneDao geneDao; - private Future queryCacheFuture; + private final ExecutorService queryCacheExecutor = Executors.newSingleThreadExecutor(); public CoexpressionQueryQueueImpl( CoexpressionDao coexpressionDao, GeneDao geneDao ) { this.coexpressionDao = coexpressionDao; @@ -79,7 +79,7 @@ public void removeFromQueue( Collection genes ) { @Override public void afterPropertiesSet() throws Exception { - queryCacheFuture = Executors.newSingleThreadExecutor().submit( new DelegatingSecurityContextRunnable( new Runnable() { + queryCacheExecutor.submit( new DelegatingSecurityContextRunnable( new Runnable() { private static final int MAX_WARNINGS = 5; @@ -109,13 +109,13 @@ public void run() { } } } - } ) ); } @Override public void destroy() throws Exception { - queryCacheFuture.cancel( true ); + // filling the coexpression cache is not really critical, so we can safely interrupt it + queryCacheExecutor.shutdownNow(); } private void queryForCache( Long geneId ) { diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDao.java index 6a0e59399d..d49b8ea0cc 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDao.java @@ -76,4 +76,6 @@ Map, Map> getLastEventsBy void retainHavingEvent( Collection a, Class type ); void retainLackingEvent( Collection a, Class type ); + + Map getCreateEvents( Collection auditables ); } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDaoImpl.java index 023b8ccfb7..6bbe63666c 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventDaoImpl.java @@ -48,8 +48,8 @@ public class AuditEventDaoImpl extends AbstractDao implements AuditE * Classes that we track for 'updated since'. This is used for "What's new" functionality. */ private static final String[] AUDITABLES_TO_TRACK_FOR_WHATS_NEW = { - "ubic.gemma.model.expression.arrayDesign.ArrayDesign", - "ubic.gemma.model.expression.experiment.ExpressionExperiment" }; + "ubic.gemma.model.expression.arrayDesign.ArrayDesign", + "ubic.gemma.model.expression.experiment.ExpressionExperiment" }; @Autowired public AuditEventDaoImpl( SessionFactory sessionFactory ) { @@ -68,8 +68,8 @@ public List getEvents( final Auditable auditable ) { Long id = auditable.getAuditTrail().getId(); //noinspection unchecked return this.getSessionFactory().getCurrentSession() - .createQuery( "select e from AuditTrail t join t.events e where t.id = :id order by e.date,e.id " ) - .setParameter( "id", id ).list(); + .createQuery( "select e from AuditTrail t join t.events e where t.id = :id order by e.date,e.id " ) + .setParameter( "id", id ).list(); } @@ -85,13 +85,13 @@ public AuditEvent getLastEvent( Auditable auditable, Class, Map> getLastEventsByType( - Collection auditables, Collection> types ) { + Collection auditables, Collection> types ) { Map, Map> results = new HashMap<>(); for ( Class ti : types ) { Map results2 = getLastEvents( auditables, ti, null ); results.put( ti, results2.entrySet().stream() - .filter( e -> ti.isAssignableFrom( e.getValue().getEventType().getClass() ) ) - .collect( Collectors.toMap( Map.Entry::getKey, Map.Entry::getValue ) ) ); + .filter( e -> ti.isAssignableFrom( e.getValue().getEventType().getClass() ) ) + .collect( Collectors.toMap( Map.Entry::getKey, Map.Entry::getValue ) ) ); } return results; } @@ -108,7 +108,7 @@ public Collection getNewSinceDate( Date date ) { Collection result = new HashSet<>(); for ( String clazz : AuditEventDaoImpl.AUDITABLES_TO_TRACK_FOR_WHATS_NEW ) { String queryString = "select distinct adb from " + clazz - + " adb inner join adb.auditTrail atr inner join atr.events as ae where ae.date > :date and ae.action='C'"; + + " adb inner join adb.auditTrail atr inner join atr.events as ae where ae.date > :date and ae.action='C'"; this.tryAddAllToResult( result, queryString, date ); } return result; @@ -126,7 +126,7 @@ public Collection getUpdatedSinceDate( Date date ) { Collection result = new HashSet<>(); for ( String clazz : AuditEventDaoImpl.AUDITABLES_TO_TRACK_FOR_WHATS_NEW ) { String queryString = "select distinct adb from " + clazz - + " adb inner join adb.auditTrail atr inner join atr.events as ae where ae.date > :date and ae.action='U'"; + + " adb inner join adb.auditTrail atr inner join atr.events as ae where ae.date > :date and ae.action='U'"; this.tryAddAllToResult( result, queryString, date ); } return result; @@ -139,7 +139,7 @@ public boolean hasEvent( Auditable a, Class type ) { @Override public void retainHavingEvent( final Collection a, - final Class type ) { + final Class type ) { final Map events = this.getLastEvents( a, type, null ); @@ -149,7 +149,7 @@ public void retainHavingEvent( final Collection a, @Override public void retainLackingEvent( final Collection a, - final Class type ) { + final Class type ) { StopWatch timer = new StopWatch(); timer.start(); final Map events = this.getLastEvents( a, type, null ); @@ -159,6 +159,32 @@ public void retainLackingEvent( final Collection a, } + public Map getCreateEvents( final Collection auditables ) { + + if ( auditables.isEmpty() ) { + return Collections.emptyMap(); + } + + Map result = new HashMap<>( auditables.size() ); + + final Map atMap = auditables.stream() + .collect( Collectors.toMap( a -> a.getAuditTrail().getId(), Function.identity() ) ); + + final String queryString = "select trail.id, ae from AuditTrail trail join trail.events" + + " ae where trail.id in :trails and ae.action = 'C'"; + Query queryObject = this.getSessionFactory().getCurrentSession() + .createQuery( queryString ) + .setParameterList( "trails", atMap.keySet() ); + List qr = queryObject.list(); + for ( Object o : qr ) { + Object[] ar = ( Object[] ) o; + Long t = ( Long ) ar[0]; + AuditEvent e = ( AuditEvent ) ar[1]; + result.put( atMap.get( t ), e ); + } + return result; + } + private Map getLastEvents( final Collection auditables, Class types, @Nullable Collection> excludedTypes ) { if ( auditables.isEmpty() ) { return Collections.emptyMap(); @@ -170,7 +196,7 @@ private Map getLastEvents( final Collection atMap = auditables.stream() - .collect( Collectors.toMap( a -> a.getAuditTrail().getId(), Function.identity() ) ); + .collect( Collectors.toMap( a -> a.getAuditTrail().getId(), Function.identity() ) ); Set> classes = getClassHierarchy( types ); @@ -183,19 +209,19 @@ private Map getLastEvents( final Collection qr = queryObject.list(); for ( Object o : qr ) { @@ -209,8 +235,8 @@ private Map getLastEvents( final Collection 500 ) { AbstractDao.log.info( String.format( "Last event of type %s (closure: %s) retrieved for %d items in %d ms", - types.getName(), classes.stream().map( Class::getName ).collect( Collectors.joining( ", " ) ), - auditables.size(), timer.getTime() ) ); + types.getName(), classes.stream().map( Class::getName ).collect( Collectors.joining( ", " ) ), + auditables.size(), timer.getTime() ) ); } return result; @@ -241,7 +267,7 @@ private Set> getClassHierarchy( Class type ) classes.add( Class.forName( className ) ); } catch ( ClassNotFoundException e ) { log.error( String.format( "Failed to find subclass %s of %s, it will not be included in the query." - , className, type.getName() ), e ); + , className, type.getName() ), e ); } } return classes; diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventService.java index 1a6ae126b7..1038f36c2d 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventService.java @@ -19,6 +19,7 @@ package ubic.gemma.persistence.service.common.auditAndSecurity; import org.springframework.security.access.annotation.Secured; +import org.springframework.transaction.annotation.Transactional; import ubic.gemma.model.common.Auditable; import ubic.gemma.model.common.auditAndSecurity.AuditEvent; import ubic.gemma.model.common.auditAndSecurity.eventType.AuditEventType; @@ -37,6 +38,9 @@ public interface AuditEventService { @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY" }) List getEvents( Auditable auditable ); + @Transactional(readOnly = true) + Map getCreateEvents( Collection auditable ); + @Nullable @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY" }) AuditEvent getLastEvent( Auditable auditable, Class type ); @@ -55,7 +59,7 @@ public interface AuditEventService { */ @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY" }) Map, Map> getLastEvents( - Collection auditables, Collection> types ); + Collection auditables, Collection> types ); /** * @param date date diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventServiceImpl.java index d0f9196afe..c80b06732e 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/common/auditAndSecurity/AuditEventServiceImpl.java @@ -49,6 +49,12 @@ public List getEvents( Auditable auditable ) { return this.auditEventDao.getEvents( auditable ); } + @Override + @Transactional(readOnly = true) + public Map getCreateEvents( Collection auditables ) { + return this.auditEventDao.getCreateEvents( auditables ); + } + @Override @Transactional(readOnly = true) public AuditEvent getLastEvent( Auditable auditable, Class type ) { @@ -64,7 +70,7 @@ public AuditEvent getLastEvent( Auditable auditable, Class, Map> getLastEvents( - Collection auditables, Collection> types ) { + Collection auditables, Collection> types ) { return this.auditEventDao.getLastEventsByType( auditables, types ); } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDao.java index c50504ca94..b68bee4371 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDao.java @@ -20,8 +20,6 @@ package ubic.gemma.persistence.service.expression.bioAssayData; import ubic.gemma.core.datastructure.matrix.QuantitationMismatchException; -import ubic.gemma.model.common.quantitationtype.QuantitationType; -import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.bioAssayData.DoubleVectorValueObject; import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; import ubic.gemma.model.expression.designElement.CompositeSequence; @@ -95,14 +93,6 @@ Map>> getRanksB void removeProcessedDataVectors( final ExpressionExperiment expressionExperiment ); - Collection find( ArrayDesign arrayDesign, - QuantitationType quantitationType ); - - Collection find( Collection designElements, - QuantitationType quantitationType ); - - Collection findByExpressionExperiment( ExpressionExperiment ee, QuantitationType quantitationType ); - enum RankMethod { max, mean } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoImpl.java index ca23405967..31eebd0d09 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoImpl.java @@ -23,7 +23,6 @@ import org.hibernate.Hibernate; import org.hibernate.Query; import org.hibernate.SessionFactory; -import org.hibernate.type.LongType; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Repository; import ubic.basecode.dataStructure.matrix.DenseDoubleMatrix; @@ -517,49 +516,6 @@ private Collection ensureLog2Scale( return new HashSet<>( matrix.toRawDataVectors() ); } - @Override - public Collection find( ArrayDesign arrayDesign, - QuantitationType quantitationType ) { - //noinspection unchecked - return new HashSet<>( this.getSessionFactory().getCurrentSession().createQuery( - "select dev from ProcessedExpressionDataVector dev " - + "join fetch dev.bioAssayDimension bd " - + "join dev.designElement de " - + "where de.arrayDesign = :ad and dev.quantitationType = :quantitationType" ) - .setParameter( "quantitationType", quantitationType ) - .setParameter( "ad", arrayDesign ) - .list() ); - } - - @Override - public Collection find( Collection designElements, - QuantitationType quantitationType ) { - if ( designElements == null || designElements.size() == 0 ) - return new HashSet<>(); - - //noinspection unchecked - return this.getSessionFactory().getCurrentSession().createQuery( - "select dev from ProcessedExpressionDataVector as dev " - // no need for fetch jointures here since the design elements and biological - // characteristics are already in the session - + "join dev.designElement as de " - + "where de in (:des) and dev.quantitationType = :qt" ) - .setParameterList( "des", designElements ) - .setParameter( "qt", quantitationType ) - .list(); - } - - @Override - public Collection findByExpressionExperiment( ExpressionExperiment ee, QuantitationType quantitationType ) { - //noinspection unchecked - return this.getSessionFactory().getCurrentSession().createQuery( - "select v from ProcessedExpressionDataVector as v " - + "where v.expressionExperiment = :ee and v.quantitationType = :qt" ) - .setParameter( "ee", ee ) - .setParameter( "qt", quantitationType ) - .list(); - } - // // @Override // public ExpressionExperiment createProcessedDataVectors( ExpressionExperiment ee, @@ -634,7 +590,7 @@ private void cacheResults( Collection newResults ) { } } // WARNING cache size() can be slow, esp. terracotta. - AbstractDao.log.info( "Cached " + i + ", input " + newResults.size() + "; total cached: " + AbstractDao.log.debug( "Cached " + i + ", input " + newResults.size() + "; total cached: " /* + this.processedDataVectorCache.size() */ ); } @@ -933,7 +889,7 @@ private Collection getProcessedDataArraysByProbeIds( Co } } - AbstractDao.log.info( cs2gene.size() + " probes associated with a gene; " + noGeneProbes.size() + " not" ); + AbstractDao.log.debug( cs2gene.size() + " probes associated with a gene; " + noGeneProbes.size() + " not" ); /* * To Check the cache we need the list of genes 1st. Get from CS2Gene list then check the cache. @@ -950,7 +906,7 @@ private Collection getProcessedDataArraysByProbeIds( Co this.checkCache( ees, genes, results, needToSearch, genesToSearch ); if ( !results.isEmpty() ) - AbstractDao.log.info( results.size() + " vectors fetched from cache" ); + AbstractDao.log.debug( results.size() + " vectors fetched from cache" ); /* * Get data that wasn't in the cache. @@ -972,7 +928,7 @@ private Collection getProcessedDataArraysByProbeIds( Co } if ( !noncached.isEmpty() ) - AbstractDao.log.info( noncached.size() + " vectors retrieved so far, for noGeneProbes" ); + AbstractDao.log.debug( noncached.size() + " vectors retrieved so far, for noGeneProbes" ); /* * Non-cached items. @@ -990,7 +946,7 @@ private Collection getProcessedDataArraysByProbeIds( Co } if ( !moreNonCached.isEmpty() ) - AbstractDao.log.info( noncached.size() + " more fetched from db" ); + AbstractDao.log.debug( noncached.size() + " more fetched from db" ); noncached.putAll( moreNonCached ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorService.java index d6850940a3..d173043088 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorService.java @@ -212,9 +212,6 @@ Map>> getRanksB @Secured({ "GROUP_ADMIN" }) void reorderByDesign( ExpressionExperiment ee ); - @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "AFTER_ACL_DATAVECTOR_COLLECTION_READ" }) - Collection findByExpressionExperiment( ExpressionExperiment ee, QuantitationType quantitationType ); - @Secured({ "GROUP_USER" }) void update( Collection updatedVectors ); } diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorServiceImpl.java index d819b8e545..7569521964 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorServiceImpl.java @@ -365,12 +365,6 @@ public void reorderByDesign( ExpressionExperiment ee ) { this.auditTrailService.addUpdateEvent( ee, "Reordered the data vectors by experimental design" ); } - @Override - @Transactional(readOnly = true) - public Collection findByExpressionExperiment( ExpressionExperiment ee, QuantitationType quantitationType ) { - return processedExpressionDataVectorDao.findByExpressionExperiment( ee, quantitationType ); - } - /** * Creates an ExperimentExpressionLevelValueObject for the given experiment and collection of double vector VOs, and * adds it to the given vos collection. diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDao.java index 6c6f66fda0..3b4c586b30 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDao.java @@ -21,7 +21,6 @@ import ubic.gemma.model.expression.biomaterial.BioMaterial; import ubic.gemma.model.expression.biomaterial.BioMaterialValueObject; import ubic.gemma.model.expression.experiment.ExpressionExperiment; -import ubic.gemma.model.expression.experiment.FactorValue; import ubic.gemma.persistence.service.BaseVoEnabledDao; import java.util.Collection; @@ -35,8 +34,6 @@ public interface BioMaterialDao extends BaseVoEnabledDao findByExperiment( ExpressionExperiment experiment ); - Collection findByFactorValue( FactorValue fv ); - /** * @param bioMaterialId biomaterial id * @return the experiment the biomaterial appears in diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDaoImpl.java index 9affb1276c..95cda5c7aa 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialDaoImpl.java @@ -95,14 +95,6 @@ public Collection findByExperiment( ExpressionExperiment experiment .setParameter( "ee", experiment ).list(); } - @Override - public Collection findByFactorValue( FactorValue fv ) { - //noinspection unchecked - return this.getSessionFactory().getCurrentSession() - .createQuery( "select distinct b from BioMaterial b join b.factorValues fv where fv = :f" ) - .setParameter( "f", fv ).list(); - } - @Override public ExpressionExperiment getExpressionExperiment( Long bioMaterialId ) { return ( ExpressionExperiment ) this.getSessionFactory().getCurrentSession().createQuery( diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialService.java index 17b9ad7a29..8f1d4365a2 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialService.java @@ -49,9 +49,6 @@ public interface BioMaterialService extends BaseService, BaseVoEnab @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "ACL_SECURABLE__READ" }) Collection findByExperiment( ExpressionExperiment experiment ); - @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "AFTER_ACL_COLLECTION_READ" }) - Collection findByFactorValue( FactorValue fv ); - @Override @Secured({ "GROUP_USER", "AFTER_ACL_READ" }) BioMaterial findOrCreate( BioMaterial bioMaterial ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialServiceImpl.java index 0882121ffe..6d799cde24 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/biomaterial/BioMaterialServiceImpl.java @@ -66,6 +66,7 @@ public BioMaterialServiceImpl( BioMaterialDao bioMaterialDao, FactorValueDao fac } @Override + @Transactional(readOnly = true) public BioMaterial copy( BioMaterial bioMaterial ) { return this.bioMaterialDao.copy( bioMaterial ); } @@ -76,12 +77,6 @@ public Collection findByExperiment( ExpressionExperiment experiment return this.bioMaterialDao.findByExperiment( experiment ); } - @Override - @Transactional(readOnly = true) - public Collection findByFactorValue( FactorValue fv ) { - return this.bioMaterialDao.findByFactorValue( fv ); - } - @Override @Transactional(readOnly = true) public ExpressionExperiment getExpressionExperiment( Long id ) { diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoImpl.java index a026f541e3..a3ccf0696b 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoImpl.java @@ -30,6 +30,7 @@ import ubic.gemma.persistence.service.AbstractVoEnabledDao; import ubic.gemma.persistence.util.BusinessKey; +import java.util.Collection; import java.util.List; import java.util.Objects; @@ -52,30 +53,8 @@ public ExperimentalFactor load( Long id ) { .setParameter( "id", id ).uniqueResult(); } - @Override - public void remove( ExperimentalFactor experimentalFactor ) { - ExperimentalDesign ed = experimentalFactor.getExperimentalDesign(); - - // detach the experimental factor from its experimental design, otherwise it will be re-saved in cascade - ed.getExperimentalFactors().remove( experimentalFactor ); - - // remove associations with the experimental factor values in related expression experiments - //noinspection unchecked - List bioMaterials = getSessionFactory().getCurrentSession() - .createQuery( "select bm from BioMaterial as bm join bm.factorValues fv where fv.experimentalFactor = :ef group by bm" ) - .setParameter( "ef", experimentalFactor ) - .list(); - for ( BioMaterial bm : bioMaterials ) { - bm.getFactorValues().removeAll( experimentalFactor.getFactorValues() ); - } - - // remove the experimental factor this cascades to values. - super.remove( experimentalFactor ); - } - @Override public ExperimentalFactor find( ExperimentalFactor experimentalFactor ) { - BusinessKey.checkValidKey( experimentalFactor ); Criteria queryObject = super.getSessionFactory().getCurrentSession().createCriteria( ExperimentalFactor.class ); BusinessKey.addRestrictions( queryObject, experimentalFactor ); @@ -95,4 +74,31 @@ public ExperimentalFactor thaw( ExperimentalFactor ef ) { Hibernate.initialize( ef.getExperimentalDesign() ); return ef; } + + @Override + public void remove( ExperimentalFactor experimentalFactor ) { + // associated analyses are removed in ExperimentalFactorService + + // detach the experimental factor from its experimental design, otherwise it will be re-saved in cascade + ExperimentalDesign ed = experimentalFactor.getExperimentalDesign(); + ed.getExperimentalFactors().remove( experimentalFactor ); + + // remove associations with the experimental factor values in related expression experiments + Collection bioMaterials = getBioMaterials( experimentalFactor ); + if ( !bioMaterials.isEmpty() ) { + for ( BioMaterial bm : bioMaterials ) { + if ( bm.getFactorValues().removeAll( experimentalFactor.getFactorValues() ) ) { + log.info( "Removed factor value(s) of " + experimentalFactor + " from " + bm ); + } + } + } + + super.remove( experimentalFactor ); + } + + private List getBioMaterials( ExperimentalFactor ef ) { + return getSessionFactory().getCurrentSession().createQuery( "select distinct bm from BioMaterial bm join bm.factorValues fv where fv.experimentalFactor = :ef" ) + .setParameter( "ef", ef ) + .list(); + } } \ No newline at end of file diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorServiceImpl.java index 4f430ae5ed..7aef4fcb2e 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorServiceImpl.java @@ -17,11 +17,11 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; -import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysis; import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.ExperimentalFactorValueObject; import ubic.gemma.persistence.service.AbstractVoEnabledService; import ubic.gemma.persistence.service.analysis.expression.diff.DifferentialExpressionAnalysisService; +import ubic.gemma.persistence.service.expression.biomaterial.BioMaterialService; import java.util.Collection; @@ -39,7 +39,7 @@ public class ExperimentalFactorServiceImpl @Autowired public ExperimentalFactorServiceImpl( ExperimentalFactorDao experimentalFactorDao, - DifferentialExpressionAnalysisService differentialExpressionAnalysisService ) { + DifferentialExpressionAnalysisService differentialExpressionAnalysisService, BioMaterialService bioMaterialService ) { super( experimentalFactorDao ); this.experimentalFactorDao = experimentalFactorDao; this.differentialExpressionAnalysisService = differentialExpressionAnalysisService; @@ -49,13 +49,11 @@ public ExperimentalFactorServiceImpl( ExperimentalFactorDao experimentalFactorDa @Transactional public void remove( ExperimentalFactor experimentalFactor ) { experimentalFactor = ensureInSession( experimentalFactor ); - /* - * First, check to see if there are any diff results that use this factor. - */ - Collection analyses = differentialExpressionAnalysisService - .findByFactor( experimentalFactor ); - for ( DifferentialExpressionAnalysis a : analyses ) { - differentialExpressionAnalysisService.remove( a ); + log.info( "Removing factor " + experimentalFactor + "..." ); + // First, check to see if there are any diff results that use this factor. + int removedAnalysis = differentialExpressionAnalysisService.removeForExperimentalFactor( experimentalFactor ); + if ( removedAnalysis > 0 ) { + log.info( String.format( "Removed %d analyses associated to factor %s", removedAnalysis, experimentalFactor ) ); } super.remove( experimentalFactor ); } @@ -63,7 +61,13 @@ public void remove( ExperimentalFactor experimentalFactor ) { @Override @Transactional public void remove( Collection experimentalFactors ) { - experimentalFactors.forEach( this::remove ); + experimentalFactors = ensureInSession( experimentalFactors ); + // First, check to see if there are any diff results that use this factor. + int removedAnalysis = differentialExpressionAnalysisService.removeForExperimentalFactors( experimentalFactors ); + if ( removedAnalysis > 0 ) { + log.info( String.format( "Removed %d analyses associated to %d factors", removedAnalysis, experimentalFactors.size() ) ); + } + super.remove( experimentalFactors ); } @Override diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDao.java index d97e8beb34..f3d637b7c4 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDao.java @@ -187,10 +187,9 @@ public interface ExpressionExperimentDao QuantitationType getPreferredQuantitationType( ExpressionExperiment ee ); /** - * Obtain the masked preferred quantitation type, if available. + * Test if the dataset has preferred expression data vectors. */ - @Nullable - QuantitationType getMaskedPreferredQuantitationType( ExpressionExperiment ee ); + boolean hasProcessedExpressionData( ExpressionExperiment ee ); Map> getSampleRemovalEvents( Collection expressionExperiments ); @@ -257,6 +256,11 @@ Map> getSampleRemovalEvents( */ Map, List> getAllAnnotations( ExpressionExperiment expressionExperiment ); + /** + * Obtain experiment-level annotations. + */ + List getExperimentAnnotations( ExpressionExperiment expressionExperiment ); + /** * Obtain sample-level annotations. */ diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoImpl.java index 488323a7c4..a7f95558a7 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoImpl.java @@ -625,17 +625,27 @@ public Collection getAnnotationsByFactorValues( @Override public Map, List> getAllAnnotations( ExpressionExperiment expressionExperiment ) { //noinspection unchecked - List result = ( ( List ) getSessionFactory().getCurrentSession().createSQLQuery( - "select {T.*}, {T}.LEVEL as LEVEL from EXPRESSION_EXPERIMENT2CHARACTERISTIC {T} " - + "where T.EXPRESSION_EXPERIMENT_FK = :eeId" ) - .addEntity( "T", Characteristic.class ) + List result = getSessionFactory().getCurrentSession() + .createSQLQuery( "select T.`VALUE` as `VALUE`, T.VALUE_URI as VALUE_URI, T.CATEGORY as CATEGORY, T.CATEGORY_URI as CATEGORY_URI, T.EVIDENCE_CODE as EVIDENCE_CODE, T.LEVEL as LEVEL from EXPRESSION_EXPERIMENT2CHARACTERISTIC T " + + "where T.EXPRESSION_EXPERIMENT_FK = :eeId" ) + .addScalar( "VALUE", StandardBasicTypes.STRING ) + .addScalar( "VALUE_URI", StandardBasicTypes.STRING ) + .addScalar( "CATEGORY", StandardBasicTypes.STRING ) + .addScalar( "CATEGORY_URI", StandardBasicTypes.STRING ) + // FIXME: use an EnumType for converting + .addScalar( "EVIDENCE_CODE", StandardBasicTypes.STRING ) .addScalar( "LEVEL", StandardBasicTypes.CLASS ) .setParameter( "eeId", expressionExperiment.getId() ) - .list() ); + .list(); //noinspection unchecked return result.stream() - .collect( Collectors.groupingBy( row -> ( Class ) row[1], - Collectors.mapping( row -> ( Characteristic ) row[0], Collectors.toList() ) ) ); + .collect( Collectors.groupingBy( row -> ( Class ) row[5], + Collectors.mapping( this::convertRowToCharacteristic, Collectors.toList() ) ) ); + } + + @Override + public List getExperimentAnnotations( ExpressionExperiment expressionExperiment ) { + return getAnnotationsByLevel( expressionExperiment, BioMaterial.class ); } @Override @@ -650,13 +660,19 @@ public List getExperimentalDesignAnnotations( ExpressionExperime private List getAnnotationsByLevel( ExpressionExperiment expressionExperiment, Class level ) { //noinspection unchecked - return getSessionFactory().getCurrentSession().createSQLQuery( - "select {T.*} from EXPRESSION_EXPERIMENT2CHARACTERISTIC {T} " - + "where {T}.LEVEL = :level and T.EXPRESSION_EXPERIMENT_FK = :eeId" ) - .addEntity( "T", Characteristic.class ) + List result = getSessionFactory().getCurrentSession() + .createSQLQuery( "select T.`VALUE` as `VALUE`, T.VALUE_URI as VALUE_URI, T.CATEGORY as CATEGORY, T.CATEGORY_URI as CATEGORY_URI, T.EVIDENCE_CODE as EVIDENCE_CODE from EXPRESSION_EXPERIMENT2CHARACTERISTIC T " + + "where T.LEVEL = :level and T.EXPRESSION_EXPERIMENT_FK = :eeId" ) + .addScalar( "VALUE", StandardBasicTypes.STRING ) + .addScalar( "VALUE_URI", StandardBasicTypes.STRING ) + .addScalar( "CATEGORY", StandardBasicTypes.STRING ) + .addScalar( "CATEGORY_URI", StandardBasicTypes.STRING ) + // FIXME: use an EnumType for converting + .addScalar( "EVIDENCE_CODE", StandardBasicTypes.STRING ) .setParameter( "level", level ) .setParameter( "eeId", expressionExperiment.getId() ) .list(); + return result.stream().map( this::convertRowToCharacteristic ).collect( Collectors.toList() ); } @Override @@ -690,12 +706,11 @@ public Map getCategoriesUsageFrequency( @Nullable Collecti } String query = "select T.CATEGORY as CATEGORY, T.CATEGORY_URI as CATEGORY_URI, count(distinct T.EXPRESSION_EXPERIMENT_FK) as EE_COUNT from EXPRESSION_EXPERIMENT2CHARACTERISTIC T " + EE2CAclQueryUtils.formNativeAclJoinClause( "T.EXPRESSION_EXPERIMENT_FK" ) + " " - + "where T.ID is not null "; + + "where T.EXPRESSION_EXPERIMENT_FK is not null "; if ( eeIds != null ) { query += " and T.EXPRESSION_EXPERIMENT_FK in :eeIds"; } - query += getExcludeUrisClause( "T.CATEGORY_URI", "T.CATEGORY", "excludedCategoryUris", excludedCategoryUris, excludeFreeTextCategories, excludeUncategorized, retainedTermUris ); - query += getExcludeUrisClause( "T.VALUE_URI", "T.`VALUE`", "excludedTermUris", excludedTermUris, excludeFreeTextTerms, false, retainedTermUris ); + query += getExcludeUrisClause( excludedCategoryUris, excludedTermUris, excludeFreeTextCategories, excludeFreeTextTerms, excludeUncategorized, retainedTermUris ); query += EE2CAclQueryUtils.formNativeAclRestrictionClause( ( SessionFactoryImplementor ) getSessionFactory(), "T.ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK" ) + " " + "group by COALESCE(T.CATEGORY_URI, T.CATEGORY) " + "order by EE_COUNT desc"; @@ -765,7 +780,7 @@ public Map getAnnotationsUsageFrequency( @Nullable Collect } String query = "select T.`VALUE` as `VALUE`, T.VALUE_URI as VALUE_URI, T.CATEGORY as CATEGORY, T.CATEGORY_URI as CATEGORY_URI, T.EVIDENCE_CODE as EVIDENCE_CODE, count(distinct T.EXPRESSION_EXPERIMENT_FK) as EE_COUNT from EXPRESSION_EXPERIMENT2CHARACTERISTIC T " + EE2CAclQueryUtils.formNativeAclJoinClause( "T.EXPRESSION_EXPERIMENT_FK" ) + " " - + "where T.ID is not null"; // this is necessary for the clause building since there might be no clause + + "where T.EXPRESSION_EXPERIMENT_FK is not null"; // this is necessary for the clause building since there might be no clause if ( eeIds != null ) { query += " and T.EXPRESSION_EXPERIMENT_FK in :eeIds"; } @@ -773,17 +788,28 @@ public Map getAnnotationsUsageFrequency( @Nullable Collect query += " and T.LEVEL = :level"; } if ( category != null ) { + // a specific category is requested if ( category.equals( UNCATEGORIZED ) ) { query += " and COALESCE(T.CATEGORY_URI, T.CATEGORY) is NULL"; + } + // using COALESCE(T.CATEGORY_URI, T.CATEGORY) = :category is very inefficient and we never use http:// in category labels + else if ( category.startsWith( "http://" ) ) { + query += " and T.CATEGORY_URI = :category"; } else { - query += " and COALESCE(T.CATEGORY_URI, T.CATEGORY) = :category"; + query += " and T.CATEGORY = :category"; } + // no need to filter out excluded categories if a specific one is requested + query += getExcludeUrisClause( null, excludedTermUris, excludeFreeTextCategories, excludeFreeTextTerms, excludeUncategorized, retainedTermUris ); + } else { + // all categories are requested, we may filter out excluded ones + query += getExcludeUrisClause( excludedCategoryUris, excludedTermUris, excludeFreeTextCategories, excludeFreeTextTerms, excludeUncategorized, retainedTermUris ); } - query += getExcludeUrisClause( "T.CATEGORY_URI", "T.CATEGORY", "excludedCategoryUris", excludedCategoryUris, excludeFreeTextCategories, excludeUncategorized, retainedTermUris ); - query += getExcludeUrisClause( "T.VALUE_URI", "T.`VALUE`", "excludedTermUris", excludedTermUris, excludeFreeTextTerms, false, retainedTermUris ); query += EE2CAclQueryUtils.formNativeAclRestrictionClause( ( SessionFactoryImplementor ) getSessionFactory(), "T.ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK" ) + " " - + "group by COALESCE(T.CATEGORY_URI, T.CATEGORY), COALESCE(T.VALUE_URI, T.`VALUE`) " - + "having EE_COUNT >= :minFrequency "; + + "group by " + // no need to group by category if a specific one is requested + + ( category == null ? "COALESCE(T.CATEGORY_URI, T.CATEGORY), " : "" ) + + "COALESCE(T.VALUE_URI, T.`VALUE`) " + + ( minFrequency > 0 ? "having EE_COUNT >= :minFrequency " : "" ); if ( retainedTermUris != null && !retainedTermUris.isEmpty() ) { query += " or VALUE_URI in (:retainedTermUris)"; } @@ -819,61 +845,69 @@ public Map getAnnotationsUsageFrequency( @Nullable Collect if ( level != null ) { q.setParameter( "level", level ); } - q.setParameter( "minFrequency", minFrequency ); + if ( minFrequency > 0 ) { + q.setParameter( "minFrequency", minFrequency ); + } EE2CAclQueryUtils.addAclParameters( q, ExpressionExperiment.class ); //noinspection unchecked List result = q.list(); TreeMap byC = new TreeMap<>( Characteristic.getByCategoryAndValueComparator() ); for ( Object[] row : result ) { - GOEvidenceCode evidenceCode; - try { - evidenceCode = row[4] != null ? GOEvidenceCode.valueOf( ( String ) row[4] ) : null; - } catch ( IllegalArgumentException e ) { - evidenceCode = null; - } - Characteristic c = Characteristic.Factory.newInstance( null, null, ( String ) row[0], ( String ) row[1], ( String ) row[2], ( String ) row[3], evidenceCode ); - byC.put( c, ( Long ) row[5] ); + byC.put( convertRowToCharacteristic( row ), ( Long ) row[5] ); } return byC; } + private Characteristic convertRowToCharacteristic( Object[] row ) { + GOEvidenceCode evidenceCode; + try { + evidenceCode = row[4] != null ? GOEvidenceCode.valueOf( ( String ) row[4] ) : null; + } catch ( IllegalArgumentException e ) { + evidenceCode = null; + } + Characteristic c = Characteristic.Factory.newInstance( null, null, ( String ) row[0], ( String ) row[1], ( String ) row[2], ( String ) row[3], evidenceCode ); + return c; + } + /** * Produce a SQL clause for excluding URIs and free-text (i.e. null) URIs. *

* FIXME: There's a bug in Hibernate that that prevents it from producing proper tuples the excluded URIs and * retained term URIs - * @param column column holding the URI to be excluded - * @param labelColumn column holding the label (only used if excludeFreeText or excludeUncategorized is true, - * then we will check if the label is non-null to cover some edge cases) - * @param excludedUrisParam name of the binding parameter for the excluded URIs - * @param excludedUris list of URIs to exclude - * @param excludeFreeText whether to exclude free-text URIs - * @param retainedTermUris list of terms that should bypass the exclusion + * @param excludedTermUris list of URIs to exclude + * + * @param excludeFreeTextCategories whether to exclude free-text categories + * @param excludeFreeTextTerms whether to exclude free-text terms + * @param retainedTermUris list of terms that should bypass the exclusion */ - private String getExcludeUrisClause( String column, String labelColumn, String excludedUrisParam, @Nullable Collection excludedUris, boolean excludeFreeText, boolean excludeUncategorized, @Nullable Collection retainedTermUris ) { - String query = ""; - if ( excludedUris != null && !excludedUris.isEmpty() ) { - query += " and ((" + column + " not in (:" + excludedUrisParam + ")"; - if ( excludeUncategorized ) { - query += " and COALESCE(" + column + ", " + labelColumn + ") is not null"; - } - if ( excludeFreeText ) { - query += " and (" + column + " is not null or " + labelColumn + " is null)"; - } - query += ")"; + private String getExcludeUrisClause( @Nullable Collection excludedCategoryUris, @Nullable Collection excludedTermUris, boolean excludeFreeTextCategories, boolean excludeFreeTextTerms, boolean excludeUncategorized, @Nullable Collection retainedTermUris ) { + List clauses = new ArrayList<>( 5 ); + if ( excludedCategoryUris != null && !excludedCategoryUris.isEmpty() ) { + clauses.add( "T.CATEGORY_URI is null or T.CATEGORY_URI not in (:excludedCategoryUris)" ); + } + if ( excludedTermUris != null && !excludedTermUris.isEmpty() ) { + clauses.add( "T.VALUE_URI is null or T.VALUE_URI not in (:excludedTermUris)" ); + } + if ( excludeFreeTextCategories ) { + // we don't want to exclude "uncategorized" terms when excluding free-text categories + clauses.add( "T.CATEGORY_URI is not null or T.CATEGORY is null" ); + } + if ( excludeFreeTextTerms ) { + clauses.add( "T.VALUE_URI is not null" ); + } + if ( excludeUncategorized ) { + clauses.add( "COALESCE(T.CATEGORY_URI, T.CATEGORY) is not null" ); + } + if ( !clauses.isEmpty() ) { + String query = ""; + query += " and ((" + String.join( ") and (", clauses ) + ")"; if ( retainedTermUris != null && !retainedTermUris.isEmpty() ) { query += " or T.VALUE_URI in (:retainedTermUris)"; } query += ")"; - } else { - if ( excludeUncategorized ) { - query += " and COALESCE(" + column + ", " + labelColumn + ") is not null"; - } - if ( excludeFreeText ) { - query += " and (" + column + " is not null or " + labelColumn + " is null)"; - } + return query; } - return query; + return ""; } @Override @@ -1297,13 +1331,10 @@ public QuantitationType getPreferredQuantitationType( ExpressionExperiment ee ) } @Override - public QuantitationType getMaskedPreferredQuantitationType( ExpressionExperiment ee ) { - return ( QuantitationType ) getSessionFactory().getCurrentSession() - .createQuery( "select qt from ExpressionExperiment ee " - + "join ee.processedExpressionDataVectors pv " - + "join pv.quantitationType qt " - + "where qt.isMaskedPreferred = true and ee = :ee " - + "group by qt" ) + public boolean hasProcessedExpressionData( ExpressionExperiment ee ) { + return ( Boolean ) getSessionFactory().getCurrentSession() + .createQuery( "select count(pedv) > 0 from ProcessedExpressionDataVector pedv " + + "where pedv.expressionExperiment = :ee" ) .setParameter( "ee", ee ) .uniqueResult(); } @@ -1755,42 +1786,72 @@ public void remove( ExpressionExperiment ee ) { ee.getCurationDetails().setLastTroubledEvent( null ); // dissociate this EE from other parts - for ( ExpressionExperiment e : ee.getOtherParts() ) { - e.getOtherParts().remove( ee ); - } - ee.getOtherParts().clear(); - - // detach from BA dimensions - Collection dims = this.getBioAssayDimensions( ee ); - for ( BioAssayDimension dim : dims ) { - dim.getBioAssays().clear(); + if ( !ee.getOtherParts().isEmpty() ) { + log.info( String.format( "Detaching split experiment from %d other parts", ee.getOtherParts().size() ) ); + for ( ExpressionExperiment e : ee.getOtherParts() ) { + log.debug( "Detaching from " + e ); + e.getOtherParts().remove( ee ); + } + ee.getOtherParts().clear(); } - // first pass, detach BAs from the samples - for ( BioAssay ba : ee.getBioAssays() ) { - ba.getSampleUsed().getBioAssaysUsedIn().remove( ba ); + // detach from BAs from dimensions, completely detached dimension will be removed later + Set dimensionsToRemove = new HashSet<>(); + for ( BioAssayDimension dim : this.getBioAssayDimensions( ee ) ) { + dim.getBioAssays().removeAll( ee.getBioAssays() ); + if ( dim.getBioAssays().isEmpty() ) { + dimensionsToRemove.add( dim ); + } else { + log.warn( dim + " is attached to more than one ExpressionExperiment, the dimension will not be deleted." ); + } } - // second pass, delete samples that are no longer attached to BAs + // detach BAs from the samples, completely detached samples will be removed later Set samplesToRemove = new HashSet<>(); + Set fvs = new HashSet<>( getFactorValues( ee ) ); for ( BioAssay ba : ee.getBioAssays() ) { - if ( ba.getSampleUsed().getBioAssaysUsedIn().isEmpty() ) { + ba.getSampleUsed().getFactorValues().removeAll( fvs ); + ba.getSampleUsed().getBioAssaysUsedIn().removeAll( ee.getBioAssays() ); + if ( ba.getSampleUsed().getBioAssaysUsedIn().isEmpty() && ba.getSampleUsed().getFactorValues().isEmpty() ) { samplesToRemove.add( ba.getSampleUsed() ); } else { - log.warn( String.format( "%s is attached to more than one ExpressionExperiment, the sample will not be deleted.", ba.getSampleUsed() ) ); + log.warn( ba.getSampleUsed() + " is attached to more than one ExpressionExperiment (via one or more BioAssay or FactorValue), the sample will not be deleted." ); } } super.remove( ee ); - // those need to be removed afterward because otherwise the BioAssay.sampleUsed would become transient while - // cascading and that is not allowed in the data model - log.debug( String.format( "Removing %d BioMaterial that are no longer attached to any BioAssay", samplesToRemove.size() ) ); - for ( BioMaterial bm : samplesToRemove ) { - getSessionFactory().getCurrentSession().delete( bm ); + if ( !samplesToRemove.isEmpty() ) { + // those need to be removed afterward because otherwise the BioAssay.sampleUsed would become transient while + // cascading and that is not allowed in the data model + log.info( String.format( "Removing %d BioMaterial that are no longer attached to any BioAssay", samplesToRemove.size() ) ); + for ( BioMaterial bm : samplesToRemove ) { + log.debug( "Removing " + bm + "..." ); + getSessionFactory().getCurrentSession().delete( bm ); + } + } + + if ( !dimensionsToRemove.isEmpty() ) { + log.info( String.format( "Removing %d BioAssayDimension that are no longer attached to any BioAssay", dimensionsToRemove.size() ) ); + for ( BioAssayDimension dim : dimensionsToRemove ) { + log.debug( "Removing " + dim + "..." ); + getSessionFactory().getCurrentSession().delete( dim ); + } } } + private List getFactorValues( ExpressionExperiment ee ) { + //noinspection unchecked + return getSessionFactory().getCurrentSession() + .createQuery( "select distinct fv from ExpressionExperiment ee " + + "join ee.experimentalDesign ed " + + "join ed.experimentalFactors ef " + + "join ef.factorValues fv " + + "where ee = :ee" ) + .setParameter( "ee", ee ) + .list(); + } + @Override public void thaw( final ExpressionExperiment expressionExperiment ) { thawWithoutVectors( expressionExperiment ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentService.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentService.java index ba58bdbb4b..89d4e01f61 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentService.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentService.java @@ -469,11 +469,10 @@ class CharacteristicWithUsageStatisticsAndOntologyTerm { QuantitationType getPreferredQuantitationType( ExpressionExperiment ee ); /** - * @see ExpressionExperimentDao#getMaskedPreferredQuantitationType(ExpressionExperiment) + * Test if the given experiment has processed data vectors. */ - @Nullable @Secured({ "IS_AUTHENTICATED_ANONYMOUSLY", "ACL_SECURABLE_READ" }) - QuantitationType getMaskedPreferredQuantitationType( ExpressionExperiment ee ); + boolean hasProcessedExpressionData( ExpressionExperiment ee ); /** * @return count of an expressionExperiment's design element data vectors, grouped by quantitation type diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentServiceImpl.java index b5de6b95f2..7bd86362a5 100755 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentServiceImpl.java @@ -793,7 +793,8 @@ public List getAnnotationsUsag private Set inferTermsUris( Collection termUris ) { Set excludedTermUris = new HashSet<>( termUris ); // null is a special indicator for free-text terms or categories - excludedTermUris.remove( FREE_TEXT ); + boolean removedFreeText = excludedTermUris.remove( FREE_TEXT ); + boolean removedUncategorized = excludedTermUris.remove( UNCATEGORIZED ); // expand exclusions with implied terms via subclass relation Set excludedTerms = ontologyService.getTerms( excludedTermUris ); // exclude terms using the subClass relation @@ -801,6 +802,12 @@ private Set inferTermsUris( Collection termUris ) { for ( OntologyTerm t : impliedTerms ) { excludedTermUris.add( t.getUri() ); } + if ( removedFreeText ) { + excludedTermUris.add( FREE_TEXT ); + } + if ( removedUncategorized ) { + excludedTermUris.add( UNCATEGORIZED ); + } return excludedTermUris; } @@ -992,11 +999,29 @@ public BatchEffectDetails getBatchEffectDetails( ExpressionExperiment ee ) { log.warn( "SVD was null for " + ef + ", can't compute batch effect statistics." ); break; } + + // Use the "date run" information as a first pass to decide if there is a batch association. + // This won't always be present. double minP = 1.0; + if ( svd.getDatePvals() != null ) { + for ( Integer component : svd.getDatePvals().keySet() ) { + Double pVal = svd.getDatePvals().get( component ); + if ( pVal != null && pVal < minP ) { + details.setBatchEffectStatistics( pVal, component + 1, svd.getVariances()[component] ); + minP = pVal; + } + } + } + + // we can override the date-based p-value with the factor-based p-value if it is lower. + // The reason to do this is it can be underpowered. The date-based one is more sensitive. for ( Integer component : svd.getFactorPvals().keySet() ) { Map cmpEffects = svd.getFactorPvals().get( component ); - Double pVal = cmpEffects.get( ef.getId() ); + // could use the effect size instead of the p-values (or in addition) + //Map cmpEffectSizes = svd.getFactorCorrelations().get( component ); + + Double pVal = cmpEffects.get( ef.getId() ); if ( pVal != null && pVal < minP ) { details.setBatchEffectStatistics( pVal, component + 1, svd.getVariances()[component] ); minP = pVal; @@ -1012,9 +1037,6 @@ public BatchEffectDetails getBatchEffectDetails( ExpressionExperiment ee ) { return details; } - /** - * WARNING: do not change these strings as they are used directly in ExpressionExperimentPage.js - */ @Override @Transactional(readOnly = true) public BatchEffectType getBatchEffect( ExpressionExperiment ee ) { @@ -1036,6 +1058,7 @@ public BatchEffectType getBatchEffect( ExpressionExperiment ee ) { } else if ( beDetails.getBatchEffectStatistics() == null ) { return BatchEffectType.BATCH_EFFECT_UNDETERMINED_FAILURE; } else if ( beDetails.getBatchEffectStatistics().getPvalue() < ExpressionExperimentServiceImpl.BATCH_EFFECT_THRESHOLD ) { + // this means there was a batch effect but we couldn't correct it return BatchEffectType.BATCH_EFFECT_FAILURE; } else { return BatchEffectType.NO_BATCH_EFFECT_SUCCESS; @@ -1141,8 +1164,8 @@ public QuantitationType getPreferredQuantitationType( final ExpressionExperiment @Override @Transactional(readOnly = true) - public QuantitationType getMaskedPreferredQuantitationType( ExpressionExperiment ee ) { - return expressionExperimentDao.getMaskedPreferredQuantitationType( ee ); + public boolean hasProcessedExpressionData( ExpressionExperiment ee ) { + return expressionExperimentDao.hasProcessedExpressionData( ee ); } @Override diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentSetServiceImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentSetServiceImpl.java index 0e5e0fd00f..4c2e86f9a5 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentSetServiceImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentSetServiceImpl.java @@ -389,7 +389,11 @@ public void update( final ExpressionExperimentSet expressionExperimentSet ) { for ( BioAssaySet ee : expressionExperimentSet.getExperiments() ) { eeTaxon = this.getTaxonForSet( ee ); - assert eeTaxon != null; + if ( eeTaxon == null ) { + // this can happen if there are 0 samples + continue; + } + if ( !eeTaxon.equals( groupTaxon ) ) { throw new IllegalArgumentException( "Failed to add experiments of wrong taxa (" + ee + ") to eeset. " + "EESet taxon is " diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDao.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDao.java index df97afc243..20589a46ec 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDao.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDao.java @@ -47,12 +47,16 @@ public interface GeneSetDao extends BaseVoEnabledDao getTaxa( GeneSet geneSet ); DatabaseBackedGeneSetValueObject loadValueObjectByIdLite( Long id ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDaoImpl.java b/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDaoImpl.java index d48cb7513a..0c2ea712a4 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDaoImpl.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/service/genome/gene/GeneSetDaoImpl.java @@ -63,14 +63,22 @@ public int getGeneCount( Long id ) { } @Override - public Taxon getTaxon( Long id ) { + public Taxon getTaxon( GeneSet geneSet ) { // get one gene, check the taxon. - Query q = this.getSessionFactory().getCurrentSession() - .createQuery( "select g from GeneSet gs join gs.members m join m.gene g where gs.id = :id" ) - .setParameter( "id", id ).setMaxResults( 1 ); + return ( Taxon ) this.getSessionFactory().getCurrentSession() + .createQuery( "select g.taxon from GeneSet gs join gs.members m join m.gene g where gs = :gs" ) + .setParameter( "gs", geneSet ) + .setMaxResults( 1 ) + .uniqueResult(); + } - Gene g = ( Gene ) q.uniqueResult(); - return g != null ? g.getTaxon() : null; + @Override + public List getTaxa( GeneSet geneSet ) { + //noinspection unchecked + return this.getSessionFactory().getCurrentSession() + .createQuery( "select distinct g.taxon from GeneSet gs join gs.members m join m.gene g where gs = :gs" ) + .setParameter( "gs", geneSet ) + .list(); } @Override diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/util/AbstractAsyncFactoryBean.java b/gemma-core/src/main/java/ubic/gemma/persistence/util/AbstractAsyncFactoryBean.java index 09fb3bc387..eed253df10 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/util/AbstractAsyncFactoryBean.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/util/AbstractAsyncFactoryBean.java @@ -36,6 +36,11 @@ public abstract class AbstractAsyncFactoryBean implements AsyncFactoryBean */ private final ExecutorService executor; + /** + * Whether to shut down the {@link #executor} when this bean is disposed. + */ + private boolean shutdownExecutorOnDispose = false; + /** * Singleton if {@link #isSingleton()} is true. */ @@ -50,6 +55,7 @@ public abstract class AbstractAsyncFactoryBean implements AsyncFactoryBean protected AbstractAsyncFactoryBean() { this( Executors.newSingleThreadExecutor() ); + this.shutdownExecutorOnDispose = true; } protected AbstractAsyncFactoryBean( ExecutorService executor ) { @@ -94,6 +100,9 @@ public final boolean isInitialized() { @Override public final void destroy() { + if ( shutdownExecutorOnDispose ) { + executor.shutdown(); + } pendingBeans.removeIf( Future::isDone ); if ( !pendingBeans.isEmpty() ) { log.info( String.format( "There are pending beans creation in %s, they will be cancelled.", getClass().getName() ) ); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/util/EnvironmentProfiles.java b/gemma-core/src/main/java/ubic/gemma/persistence/util/EnvironmentProfiles.java new file mode 100644 index 0000000000..73950ae672 --- /dev/null +++ b/gemma-core/src/main/java/ubic/gemma/persistence/util/EnvironmentProfiles.java @@ -0,0 +1,16 @@ +package ubic.gemma.persistence.util; + +/** + * Environment profiles used in the Spring context. + *

+ * These are mutually exclusive. + * @author poirigui + */ +@SuppressWarnings("unused") +public class EnvironmentProfiles { + + public static final String + PRODUCTION = "production", + DEV = "dev", + TEST = "test"; +} diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/util/SettingsConfig.java b/gemma-core/src/main/java/ubic/gemma/persistence/util/SettingsConfig.java index 89e2dbcea2..b117a0cb67 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/util/SettingsConfig.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/util/SettingsConfig.java @@ -4,13 +4,14 @@ import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.context.support.PropertySourcesPlaceholderConfigurer; +import org.springframework.core.convert.ConversionService; import org.springframework.core.env.MutablePropertySources; import org.springframework.core.env.PropertiesPropertySource; -import org.springframework.core.env.PropertySource; import org.springframework.core.env.PropertySources; import org.springframework.core.io.ClassPathResource; import org.springframework.core.io.FileSystemResource; import org.springframework.core.io.support.ResourcePropertySource; +import org.springframework.format.support.DefaultFormattingConversionService; import java.io.IOException; import java.nio.file.Files; @@ -37,6 +38,18 @@ public static PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderCon return configurer; } + /** + * The default Spring conversion service has limited support for Java 8 types. + *

+ * This might be resolved in Spring 4+, in which case we could remove this declaration. + */ + @Bean + public ConversionService conversionService() { + DefaultFormattingConversionService service = new DefaultFormattingConversionService(); + service.addConverter( String.class, Path.class, source -> Paths.get( ( String ) source ) ); + return service; + } + private static PropertySources propertySources() throws IOException { MutablePropertySources result = new MutablePropertySources(); diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringContextUtil.java b/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringContextUtil.java index 9b84d80fe5..584a3e741d 100644 --- a/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringContextUtil.java +++ b/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringContextUtil.java @@ -31,6 +31,7 @@ import java.util.Arrays; import java.util.List; import java.util.concurrent.TimeUnit; +import java.util.stream.Stream; /** * Methods to create Spring contexts for Gemma manually. This is meant to be used by CLIs only. @@ -44,7 +45,7 @@ public class SpringContextUtil { /** * Obtain an application context for Gemma. * - * @param activeProfiles list of active profiles, for testing use {@link SpringProfiles#TEST} + * @param activeProfiles list of active profiles, for testing use {@link EnvironmentProfiles#TEST} * @param additionalConfigurationLocations a list of additional configuration location to load beans from * @return a fully initialized {@link ApplicationContext} * @throws org.springframework.beans.BeansException if the creation of the context fails @@ -93,18 +94,27 @@ public static ApplicationContext getApplicationContext( boolean testing, boolean * Perform the following steps: *

    *
  • activate the {@code dev} profile as a fallback if no profile are active
  • + *
  • verify that exactly one environment profile is active (see {@link EnvironmentProfiles})
  • *
  • log an informative message with the context version and active profiles
  • *
*/ public static void prepareContext( ApplicationContext context ) { if ( context instanceof ConfigurableApplicationContext ) { ConfigurableApplicationContext cac = ( ConfigurableApplicationContext ) context; - if ( !cac.getEnvironment().acceptsProfiles( SpringProfiles.PRODUCTION, SpringProfiles.DEV, SpringProfiles.TEST ) ) { + if ( !cac.getEnvironment().acceptsProfiles( EnvironmentProfiles.PRODUCTION, EnvironmentProfiles.DEV, EnvironmentProfiles.TEST ) ) { log.warn( "No profiles were detected, activating the 'dev' profile as a fallback. Use -Dspring.profiles.active=dev explicitly to remove this warning." ); - cac.getEnvironment().addActiveProfile( SpringProfiles.DEV ); + cac.getEnvironment().addActiveProfile( EnvironmentProfiles.DEV ); } } - BuildInfo buildInfo = BuildInfo.fromSettings(); + long numberOfActiveEnvironmentProfiles = Stream.of( EnvironmentProfiles.PRODUCTION, EnvironmentProfiles.DEV, EnvironmentProfiles.TEST ) + .filter( context.getEnvironment()::acceptsProfiles ) + .count(); + if ( numberOfActiveEnvironmentProfiles == 0 ) { + throw new IllegalStateException( "The context must contain at least one environment profile." ); + } else if ( numberOfActiveEnvironmentProfiles > 1 ) { + throw new IllegalStateException( "The context must contain at most one environment profile." ); + } + BuildInfo buildInfo = BuildInfo.fromClasspath(); SpringContextUtil.log.info( String.format( "Loading Gemma %s%s, hold on!", buildInfo, context.getEnvironment().getActiveProfiles().length > 0 ? diff --git a/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringProfiles.java b/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringProfiles.java deleted file mode 100644 index 56d8ca5d03..0000000000 --- a/gemma-core/src/main/java/ubic/gemma/persistence/util/SpringProfiles.java +++ /dev/null @@ -1,13 +0,0 @@ -package ubic.gemma.persistence.util; - -/** - * Constants used for various Spring profiles. - * @author poirigui - */ -@SuppressWarnings("unused") -public class SpringProfiles { - - public static final String PRODUCTION = "production", - DEV = "dev", - TEST = "test"; -} diff --git a/gemma-core/src/main/resources/default.properties b/gemma-core/src/main/resources/default.properties index 6cef3e03f6..43705db5ee 100755 --- a/gemma-core/src/main/resources/default.properties +++ b/gemma-core/src/main/resources/default.properties @@ -21,6 +21,7 @@ gemma.compass.dir=${gemma.search.dir} gemma.fastq.headers.dir=${gemma.appdata.home}/fastqHeaders # Directory for on-disk cache, overwritten by the ehcache.disk.store.dir system property gemma.cache.dir=${gemma.appdata.home}/cache +gemma.gene2cs.path=${gemma.appdata.home}/DBReports/gene2cs.info ##################################################### # EMAIL and URLS # base url for the system, used in formed URLs @@ -203,4 +204,4 @@ gemma.externalDatabases.featured=hg38,mm39,rn7,gene,go # Enable cache statistics on startup gemma.cacheMonitor.enableStatistics=false # URL to use for GemBrow -gemma.gemBrow.url=/browse \ No newline at end of file +gemma.gemBrow.url=https://gemma.msl.ubc.ca/browse \ No newline at end of file diff --git a/gemma-core/src/main/resources/sql/init-entities.sql b/gemma-core/src/main/resources/sql/init-entities.sql index c3b26180b1..a706a3fa47 100644 --- a/gemma-core/src/main/resources/sql/init-entities.sql +++ b/gemma-core/src/main/resources/sql/init-entities.sql @@ -1,45 +1,17 @@ -- Initialize the database with some scraps of data. See also init-indices.sql and mysql-acegi-acl.sql. --- hilo for generating IDs, under the MultipleHiLoPerTableGenerator method. --- See http://blog.eyallupu.com/2011/01/hibernatejpa-identity-generators.html -drop table if exists hibernate_sequences; -create table hibernate_sequences ( - sequence_name VARCHAR(255) not null, - sequence_next_hi_value BIGINT not null -); - -delete from CONTACT; -delete from TAXON; -delete from EXTERNAL_DATABASE; -delete from AUDIT_TRAIL; - --- alter CHROMOSOME_FEATURE for case insensitive search -ALTER TABLE CHROMOSOME_FEATURE MODIFY OFFICIAL_SYMBOL varchar(255) default NULL; -ALTER TABLE CHROMOSOME_FEATURE MODIFY NAME varchar(255) default NULL; -ALTER TABLE CHROMOSOME_FEATURE MODIFY NCBI_GI varchar(255) default NULL; -ALTER TABLE CHROMOSOME_FEATURE MODIFY NCBI_GENE_ID int(11) UNIQUE; --- alter GENE_ALIAS for case insensitive search -ALTER TABLE GENE_ALIAS MODIFY ALIAS varchar(255) default NULL; - - --- wider columns. -alter table BIO_SEQUENCE modify SEQUENCE LONGTEXT; -alter table JOB_INFO modify MESSAGES LONGTEXT; - - -- all of these are used. insert into AUDIT_TRAIL VALUES (1); insert into AUDIT_TRAIL VALUES (2); insert into AUDIT_TRAIL VALUES (3); - set @n:=now(); -- username=gemmaAgent: id = 2, password = 'XXXXXXXX', audit trail #2, using salt={username} -insert into CONTACT (ID, CLASS, NAME, LAST_NAME, USER_NAME, PASSWORD, ENABLED, EMAIL, PASSWORD_HINT) values (2, "User", "gemmaAgent", "", "gemmaAgent", "2db458c67b4b52bba0184611c302c9c174ce8de4", 1, "pavlab-support@msl.ubc.ca", "hint"); +insert into CONTACT (ID, CLASS, NAME, LAST_NAME, USER_NAME, PASSWORD, ENABLED, EMAIL, PASSWORD_HINT) values (2, 'User', 'gemmaAgent', '', 'gemmaAgent', '2db458c67b4b52bba0184611c302c9c174ce8de4', 1, 'pavlab-support@msl.ubc.ca', 'hint'); -- username=administrator: id = 1, password = 'administrator', audit trail #1 using salt=username ('administrator') -insert into CONTACT (ID, CLASS, NAME, LAST_NAME, USER_NAME, PASSWORD, ENABLED, EMAIL, PASSWORD_HINT) values (1, "User", "administrator", "", "administrator", "b7338dcc17d6b6c199a75540aab6d0506567b980", 1, "pavlab-support@msl.ubc.ca", "hint"); +insert into CONTACT (ID, CLASS, NAME, LAST_NAME, USER_NAME, PASSWORD, ENABLED, EMAIL, PASSWORD_HINT) values (1, 'User', 'administrator', '', 'administrator', 'b7338dcc17d6b6c199a75540aab6d0506567b980', 1, 'pavlab-support@msl.ubc.ca', 'hint'); -- initialize the audit trails insert into AUDIT_EVENT VALUES (1, @n, 'C', 'From init script', '', 1, NULL, 1); @@ -48,12 +20,12 @@ insert into AUDIT_EVENT VALUES (3, @n, 'C', 'From init script', '', 1, NULL, 3); -- Note that 'Administrators' is a constant set in AuthorityConstants. The names of these groups are defined in UserGroupDao. -insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (1, "Administrators", "Users with administrative rights", 1); -insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (2, "Users", "Default group for all authenticated users", 2); -insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (3, "Agents", "For 'autonomous' agents that run within the server context, such as scheduled tasks.", 3); -insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (1, "ADMIN", 1); -insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (2, "USER", 2); -insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (3, "AGENT", 3); +insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (1, 'Administrators', 'Users with administrative rights', 1); +insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (2, 'Users', 'Default group for all authenticated users', 2); +insert into USER_GROUP (ID, NAME, DESCRIPTION, AUDIT_TRAIL_FK) VALUES (3, 'Agents', 'For \'autonomous\' agents that run within the server context, such as scheduled tasks.', 3); +insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (1, 'ADMIN', 1); +insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (2, 'USER', 2); +insert into GROUP_AUTHORITY (ID, AUTHORITY, GROUP_FK) VALUES (3, 'AGENT', 3); -- make admin in the admin group insert into GROUP_MEMBERS (USER_GROUPS_FK, GROUP_MEMBERS_FK) VALUES (1, 1); @@ -65,13 +37,13 @@ insert into GROUP_MEMBERS (USER_GROUPS_FK, GROUP_MEMBERS_FK) VALUES (2, 1); insert into GROUP_MEMBERS (USER_GROUPS_FK, GROUP_MEMBERS_FK) VALUES (3, 2); -- taxa -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Homo sapiens","human","9606",1); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Mus musculus","mouse","10090",1); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Rattus norvegicus","rat","10116",1); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE,SECONDARY_NCBI_ID) values ("Saccharomyces cerevisiae","yeast","4932",1,559292); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Danio rerio","zebrafish","7955",1); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Drosophila melanogaster","fly","7227",1); -insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ("Caenorhabditis elegans","worm","6239",1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Homo sapiens','human','9606',1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Mus musculus','mouse','10090',1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Rattus norvegicus','rat','10116',1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE,SECONDARY_NCBI_ID) values ('Saccharomyces cerevisiae','yeast','4932',1,559292); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Danio rerio','zebrafish','7955',1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Drosophila melanogaster','fly','7227',1); +insert into TAXON (SCIENTIFIC_NAME,COMMON_NAME,NCBI_ID,IS_GENES_USABLE) values ('Caenorhabditis elegans','worm','6239',1); -- external databases @@ -141,7 +113,6 @@ call add_external_database_relation('rn7', 'rn7 RNA-Seq annotations'); drop procedure add_external_database_relation; -- denormalized table joining genes and compositeSequences; maintained by TableMaintenanceUtil. -drop table if exists GENE2CS; create table GENE2CS ( GENE BIGINT not null, @@ -156,7 +127,8 @@ alter table GENE2CS alter table GENE2CS add constraint GENE2CS_GENE_FKC foreign key (GENE) references CHROMOSOME_FEATURE (ID) on update cascade on delete cascade; -drop table if exists EXPRESSION_EXPERIMENT2CHARACTERISTIC; +-- this table is created in the hibernate schema +drop table EXPRESSION_EXPERIMENT2CHARACTERISTIC; create table EXPRESSION_EXPERIMENT2CHARACTERISTIC ( ID bigint, @@ -171,7 +143,7 @@ create table EXPRESSION_EXPERIMENT2CHARACTERISTIC EXPRESSION_EXPERIMENT_FK bigint, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK int not null default 0, LEVEL varchar(255), - primary key (ID, EXPRESSION_EXPERIMENT_FK, LEVEL) + primary key (ID, EXPRESSION_EXPERIMENT_FK) ); -- note: constraint names cannot exceed 64 characters, so we cannot use the usual naming convention @@ -185,7 +157,6 @@ alter table EXPRESSION_EXPERIMENT2CHARACTERISTIC add index EE2C_CATEGORY_URI_CATEGORY_VALUE_URI_VALUE (CATEGORY_URI(100), CATEGORY, VALUE_URI(100), VALUE), add index EE2C_LEVEL (LEVEL); -drop table if exists EXPRESSION_EXPERIMENT2ARRAY_DESIGN; create table EXPRESSION_EXPERIMENT2ARRAY_DESIGN ( EXPRESSION_EXPERIMENT_FK bigint not null, diff --git a/gemma-core/src/main/resources/sql/migrations/db.1.31.2.sql b/gemma-core/src/main/resources/sql/migrations/db.1.31.2.sql new file mode 100644 index 0000000000..ab179fdde9 --- /dev/null +++ b/gemma-core/src/main/resources/sql/migrations/db.1.31.2.sql @@ -0,0 +1,4 @@ +-- drop the LEVEL from the primary key +alter table EXPRESSION_EXPERIMENT2CHARACTERISTIC + drop primary key, + add primary key (ID, EXPRESSION_EXPERIMENT_FK); \ No newline at end of file diff --git a/gemma-core/src/main/resources/ubic/gemma/applicationContext-dataSource.xml b/gemma-core/src/main/resources/ubic/gemma/applicationContext-dataSource.xml index 38b3baa494..049453c23b 100644 --- a/gemma-core/src/main/resources/ubic/gemma/applicationContext-dataSource.xml +++ b/gemma-core/src/main/resources/ubic/gemma/applicationContext-dataSource.xml @@ -21,7 +21,7 @@ - + diff --git a/gemma-core/src/main/resources/ubic/gemma/core/ontology/valueStringToOntologyTermMappings.txt b/gemma-core/src/main/resources/ubic/gemma/core/ontology/valueStringToOntologyTermMappings.txt index 23e63f4e21..90124e1ba3 100644 --- a/gemma-core/src/main/resources/ubic/gemma/core/ontology/valueStringToOntologyTermMappings.txt +++ b/gemma-core/src/main/resources/ubic/gemma/core/ontology/valueStringToOntologyTermMappings.txt @@ -3,12 +3,17 @@ # Case of the string value is ignored; the category is checked against the type of variable imported, so if it doesn't match what we have here, # it won't be mapped. # String value value valueUri category categoryUri -126S6/SvEvTac 129S6 http://www.ebi.ac.uk/efo/EFO_0000598 strain http://www.ebi.ac.uk/efo/EFO_0005135 129 129 mouse strain http://www.ebi.ac.uk/efo/EFO_0000597 strain http://www.ebi.ac.uk/efo/EFO_0005135 +126S6/SvEvTac 129S6 http://www.ebi.ac.uk/efo/EFO_0000598 strain http://www.ebi.ac.uk/efo/EFO_0005135 129/Sv 129/Sv http://www.ebi.ac.uk/efo/EFO_0000599 strain http://www.ebi.ac.uk/efo/EFO_0005135 +129S6 129S6 http://www.ebi.ac.uk/efo/EFO_0000598 strain http://www.ebi.ac.uk/efo/EFO_0005135 129SV 129/Sv http://www.ebi.ac.uk/efo/EFO_0000599 strain http://www.ebi.ac.uk/efo/EFO_0005135 17beta-estradiol 17beta-estradiol http://purl.obolibrary.org/obo/CHEBI_16469 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +2-pam pralidoxime http://purl.obolibrary.org/obo/CHEBI_8354 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +5-HT neuron serotonergic neuron http://purl.obolibrary.org/obo/CL_0000850 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +5xFAD 5xFAD http://gemma.msl.ubc.ca/ont/TGEMO_00172 strain http://www.ebi.ac.uk/efo/EFO_0005135 A/J A/J http://www.ebi.ac.uk/efo/EFO_0001327 strain http://www.ebi.ac.uk/efo/EFO_0005135 +A375 A-375 cell http://purl.obolibrary.org/obo/CLO_0001582 cell line http://purl.obolibrary.org/obo/CLO_0000031 A549 A549 cell http://purl.obolibrary.org/obo/CLO_0001601 cell line http://purl.obolibrary.org/obo/CLO_0000031 A549 cells A549 cell http://purl.obolibrary.org/obo/CLO_0001601 cell line http://purl.obolibrary.org/obo/CLO_0000031 A549 epithelial cells A549 cell http://purl.obolibrary.org/obo/CLO_0001601 cell line http://purl.obolibrary.org/obo/CLO_0000031 @@ -18,256 +23,515 @@ active tuberculosis tuberculosis http://purl.obolibrary.org/obo/MONDO_0018076 di Acute hippocampal slice Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Acute Lymphoblastic Leukemia (ALL) acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0004967 disease http://www.ebi.ac.uk/efo/EFO_0000408 acute myeloid leukemia acute myeloid leukemia http://purl.obolibrary.org/obo/MONDO_0018874 disease http://www.ebi.ac.uk/efo/EFO_0000408 +AD Alzheimer disease http://purl.obolibrary.org/obo/MONDO_0004975 disease http://www.ebi.ac.uk/efo/EFO_0000408 Adeno carcinoma adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0004970 disease http://www.ebi.ac.uk/efo/EFO_0000408 Adenocarcinoma adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0004970 disease http://www.ebi.ac.uk/efo/EFO_0000408 Adenocarcinoma (NOS) of the prostate prostate adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005082 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Adenocarcinoma of the lung lung adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005061 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Adenoma adenoma http://purl.obolibrary.org/obo/MONDO_0004972 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Adenocarcinoma of the Lung lung adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005061 disease http://www.ebi.ac.uk/efo/EFO_0000408 +adenoma adenoma http://purl.obolibrary.org/obo/MONDO_0004972 disease http://www.ebi.ac.uk/efo/EFO_0000408 +adipocyte adipocyte http://purl.obolibrary.org/obo/CL_0000136 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +adipose adipose tissue http://purl.obolibrary.org/obo/UBERON_0001013 organism part http://www.ebi.ac.uk/efo/EFO_0000635 adipose tissue adipose tissue http://purl.obolibrary.org/obo/UBERON_0001013 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +adipose_tissue adipose tissue http://purl.obolibrary.org/obo/UBERON_0001013 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Adrenal adrenal gland http://purl.obolibrary.org/obo/UBERON_0002369 organism part http://www.ebi.ac.uk/efo/EFO_0000635 adrenal cortex adrenal cortex http://purl.obolibrary.org/obo/UBERON_0001235 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Adrenal Gland adrenal gland http://purl.obolibrary.org/obo/UBERON_0002369 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +adrenal gland adrenal gland http://purl.obolibrary.org/obo/UBERON_0002369 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Adrenocortical Carcinoma adrenal cortex carcinoma http://purl.obolibrary.org/obo/MONDO_0006639 disease http://www.ebi.ac.uk/efo/EFO_0000408 adult adult http://www.ebi.ac.uk/efo/EFO_0001272 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +Adult Brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Adult Head head http://purl.obolibrary.org/obo/UBERON_0000033 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Adult mouse midbrain midbrain http://purl.obolibrary.org/obo/UBERON_0001891 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +advanced non-small cell lung cancer non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 African American African American http://purl.obolibrary.org/obo/HANCESTRO_0568 population http://purl.obolibrary.org/obo/OBI_0000181 +african-american African American http://purl.obolibrary.org/obo/HANCESTRO_0568 population http://purl.obolibrary.org/obo/OBI_0000181 +Aged old http://purl.obolibrary.org/obo/PATO_0000308 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +airway epithelial brushing tracheal brush http://www.ebi.ac.uk/efo/EFO_0011029 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +airway smooth muscle cells respiratory system smooth muscle http://purl.obolibrary.org/obo/UBERON_0004225 organism part http://www.ebi.ac.uk/efo/EFO_0000635 AKR/J AKR/J http://www.ebi.ac.uk/efo/EFO_0007726 strain http://www.ebi.ac.uk/efo/EFO_0005135 -Amygdala amygdala http://purl.obolibrary.org/obo/UBERON_0001876 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +alcohol alcohol http://purl.obolibrary.org/obo/CHEBI_30879 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +ALS amyotrophic lateral sclerosis http://purl.obolibrary.org/obo/MONDO_0004976 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ALS Spectrum MND amyotrophic lateral sclerosis http://purl.obolibrary.org/obo/MONDO_0004976 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Alzheimer's disease Alzheimer disease http://purl.obolibrary.org/obo/MONDO_0004975 disease http://www.ebi.ac.uk/efo/EFO_0000408 +AML acute myeloid leukemia http://purl.obolibrary.org/obo/MONDO_0018874 disease http://www.ebi.ac.uk/efo/EFO_0000408 +amygdala amygdala http://purl.obolibrary.org/obo/UBERON_0001876 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +amygdala (AMG) amygdala http://purl.obolibrary.org/obo/UBERON_0001876 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Amygdala, Dissected whole amygdala http://purl.obolibrary.org/obo/UBERON_0001876 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ancestry (cauc European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 anterior cingulate anterior cingulate gyrus http://purl.obolibrary.org/obo/UBERON_0002756 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Aorta aorta http://purl.obolibrary.org/obo/UBERON_0000947 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Anterior Cingulate Cortex anterior cingulate cortex http://purl.obolibrary.org/obo/UBERON_0009835 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +anterior pituitary adenohypophysis http://purl.obolibrary.org/obo/UBERON_0002196 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +aorta aorta http://purl.obolibrary.org/obo/UBERON_0000947 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +APP/PS1 APP/PS1 http://gemma.msl.ubc.ca/ont/TGEMO_00174 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Appendix vermiform appendix http://purl.obolibrary.org/obo/UBERON_0001154 organism part http://www.ebi.ac.uk/efo/EFO_0000635 arcuate nucleus arcuate nucleus of hypothalamus http://purl.obolibrary.org/obo/UBERON_0001932 organism part http://www.ebi.ac.uk/efo/EFO_0000635 articular cartilage articular cartilage of joint http://purl.obolibrary.org/obo/UBERON_0010996 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Asain Asian http://purl.obolibrary.org/obo/HANCESTRO_0008 population http://purl.obolibrary.org/obo/OBI_0000181 +ascending colon ascending colon http://purl.obolibrary.org/obo/UBERON_0001156 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ASD autism spectrum disorder http://purl.obolibrary.org/obo/MONDO_0005258 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Asian Asian http://purl.obolibrary.org/obo/HANCESTRO_0008 population http://www.ebi.ac.uk/efo/EFO_0000324 Asthma asthma http://purl.obolibrary.org/obo/MONDO_0004979 disease http://www.ebi.ac.uk/efo/EFO_0000408 +asthmatic asthma http://purl.obolibrary.org/obo/MONDO_0004979 disease http://www.ebi.ac.uk/efo/EFO_0000408 astrocyte astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 astrocytes astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +astrocytoma astrocytoma (excluding glioblastoma) http://purl.obolibrary.org/obo/MONDO_0019781 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ATCC ATCC cell line cell http://purl.obolibrary.org/obo/CLO_0000010 cell line http://purl.obolibrary.org/obo/CLO_0000031 +atropine atropine http://purl.obolibrary.org/obo/CHEBI_16684 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +autism autism http://purl.obolibrary.org/obo/MONDO_0005260 disease http://www.ebi.ac.uk/efo/EFO_0000408 autism autism spectrum disorder http://purl.obolibrary.org/obo/MONDO_0005258 disease http://www.ebi.ac.uk/efo/EFO_0000408 B cell B cell http://purl.obolibrary.org/obo/CL_0000236 cell type http://www.ebi.ac.uk/efo/EFO_0000324 B cells B cell http://purl.obolibrary.org/obo/CL_0000236 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +B lymphoblastoid B cell http://purl.obolibrary.org/obo/CL_0000236 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +B-cell lymphoma B-cell lymphoma, unclassifiable, with features intermediate between diffuse large b-cell lymphoma and classical Hodgkin lymphoma http://purl.obolibrary.org/obo/MONDO_0003658 disease http://www.ebi.ac.uk/efo/EFO_0000408 B-cell lymphoma B-cell neoplasm http://purl.obolibrary.org/obo/MONDO_0004095 disease http://www.ebi.ac.uk/efo/EFO_0000408 B6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 B6C3F1 B6C3F1 http://www.ebi.ac.uk/efo/EFO_0001340 strain http://www.ebi.ac.uk/efo/EFO_0005135 +B6C3F1/Crl B6C3F1 http://www.ebi.ac.uk/efo/EFO_0001340 strain http://www.ebi.ac.uk/efo/EFO_0005135 +BA9 Brodmann (1909) area 9 http://purl.obolibrary.org/obo/UBERON_0013540 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +BA9 prefrontal cortex Brodmann (1909) area 9 http://purl.obolibrary.org/obo/UBERON_0013540 organism part http://www.ebi.ac.uk/efo/EFO_0000635 BALB BALB/c http://www.ebi.ac.uk/efo/EFO_0000602 strain http://www.ebi.ac.uk/efo/EFO_0005135 BALB/c BALB/c http://www.ebi.ac.uk/efo/EFO_0000602 strain http://www.ebi.ac.uk/efo/EFO_0005135 BALB/cJ BALB/c http://www.ebi.ac.uk/efo/EFO_0000602 strain http://www.ebi.ac.uk/efo/EFO_0005135 +baseline reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +basolateral amygdala basolateral amygdaloid nuclear complex http://purl.obolibrary.org/obo/UBERON_0006107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 BEAS-2B BEAS-2B cell http://purl.obolibrary.org/obo/CLO_0001925 cell line http://purl.obolibrary.org/obo/CLO_0000031 +bed nucleus of the stria terminalis bed nucleus of stria terminalis http://purl.obolibrary.org/obo/UBERON_0001880 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +before treatment reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Benign benign http://www.ebi.ac.uk/efo/EFO_0002751 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 Biceps biceps brachii http://purl.obolibrary.org/obo/UBERON_0001507 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +biopsy biopsy http://purl.obolibrary.org/obo/OBI_0002650 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +Biotin biotin http://purl.obolibrary.org/obo/CHEBI_15956 treatment http://www.ebi.ac.uk/efo/EFO_0000727 bipolar bipolar disorder http://purl.obolibrary.org/obo/MONDO_0004985 disease http://www.ebi.ac.uk/efo/EFO_0000408 -bipolar disorder bipolar disorder http://purl.obolibrary.org/obo/MONDO_0004985 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Bipolar disorder bipolar disorder http://purl.obolibrary.org/obo/MONDO_0004985 disease http://www.ebi.ac.uk/efo/EFO_0000408 +bisphenol A bisphenol A http://purl.obolibrary.org/obo/CHEBI_33216 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +BL6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 bladder urinary bladder http://purl.obolibrary.org/obo/UBERON_0001255 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +bladder cancer urinary bladder cancer http://purl.obolibrary.org/obo/MONDO_0001187 disease http://www.ebi.ac.uk/efo/EFO_0000408 Blastocyst blastocyst http://purl.obolibrary.org/obo/UBERON_0000358 organism part http://www.ebi.ac.uk/efo/EFO_0000635 blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 blood cells blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +blood leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +blood plasma blood plasma http://purl.obolibrary.org/obo/UBERON_0001969 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Blood sample blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Blood Vessel blood vessel http://purl.obolibrary.org/obo/UBERON_0001981 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +boitin biotin http://purl.obolibrary.org/obo/CHEBI_15956 treatment http://www.ebi.ac.uk/efo/EFO_0000727 bone bone tissue http://purl.obolibrary.org/obo/UBERON_0002481 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +bone (ulna) ulna http://purl.obolibrary.org/obo/UBERON_0001424 organism part http://www.ebi.ac.uk/efo/EFO_0000635 bone marrow bone marrow http://purl.obolibrary.org/obo/UBERON_0002371 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +bone marrow cells bone marrow http://purl.obolibrary.org/obo/UBERON_0002371 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Bone Marrow cells bone marrow cell http://purl.obolibrary.org/obo/CL_0002092 cell type http://www.ebi.ac.uk/efo/EFO_0000324 bone marrow derived macrophage bone marrow macrophage http://purl.obolibrary.org/obo/CL_0002476 cell type http://www.ebi.ac.uk/efo/EFO_0000324 bone marrow derived macrophages bone marrow macrophage http://purl.obolibrary.org/obo/CL_0002476 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +bone marrow derived macrophages (BMM) bone marrow macrophage http://purl.obolibrary.org/obo/CL_0002476 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Bone Marrow Mononuclear Cells mononuclear cell of bone marrow http://purl.obolibrary.org/obo/CL_0010004 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Bone marrow sample bone marrow http://purl.obolibrary.org/obo/UBERON_0002371 organism part http://www.ebi.ac.uk/efo/EFO_0000635 bone marrow-derived macrophages bone marrow macrophage http://purl.obolibrary.org/obo/CL_0002476 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Borrelia burgdorferi Borreliella burgdorferi http://purl.obolibrary.org/obo/NCBITaxon_139 treatment http://www.ebi.ac.uk/efo/EFO_0000727 brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain  brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain - Cerebellum cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain - Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain (cortex) cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain (frontal cortex) frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 brain amygdala amygdala http://purl.obolibrary.org/obo/UBERON_0001876 organism part http://www.ebi.ac.uk/efo/EFO_0000635 brain anterior cingulate cortex anterior cingulate cortex http://purl.obolibrary.org/obo/UBERON_0009835 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain Endothelial cells endothelial cell http://purl.obolibrary.org/obo/CL_0000115 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Brain Frontal Cortex frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain metastasis metastasis http://www.ebi.ac.uk/efo/EFO_0009708 disease http://www.ebi.ac.uk/efo/EFO_0000408 Brain microglia microglial cell http://purl.obolibrary.org/obo/CL_0000129 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Brain organoids brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain prefrontal cortex, broadman areas 11 Brodmann (1909) area 11 http://purl.obolibrary.org/obo/UBERON_0013528 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain prefrontal cortex, broadman areas 47 Brodmann (1909) area 47 http://purl.obolibrary.org/obo/UBERON_0006484 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain stem brainstem http://purl.obolibrary.org/obo/UBERON_0002298 organism part http://www.ebi.ac.uk/efo/EFO_0000635 brain striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain tissue brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brain tumor brain cancer http://purl.obolibrary.org/obo/MONDO_0001657 disease http://www.ebi.ac.uk/efo/EFO_0000408 brain tumor (ependymoma) ependymoma http://purl.obolibrary.org/obo/MONDO_0016698 disease http://www.ebi.ac.uk/efo/EFO_0000408 +brain tumor tissue brain cancer http://purl.obolibrary.org/obo/MONDO_0001657 disease http://www.ebi.ac.uk/efo/EFO_0000408 brain, cerebellum cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain, cerebral cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 brain, frontal cortex frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -brainstem brainstem http://purl.obolibrary.org/obo/UBERON_0002298 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +brain, hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Brainstem brainstem http://purl.obolibrary.org/obo/UBERON_0002298 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Breast breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +breast adenocarcinoma breast adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0004988 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Breast Cancer Carcinoma breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004989 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Breast cancer cell line breast cancer cell line http://www.ebi.ac.uk/efo/EFO_0002885 cell line http://purl.obolibrary.org/obo/CLO_0000031 +breast cancer cells breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 breast cancer specimen breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Breast cancer tissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 breast cancer tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 breast cancer tumor tissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 breast carcinoma associated fibroblast fibroblast of mammary gland http://purl.obolibrary.org/obo/CL_0002555 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +breast cell line immortal breast-derived cell line cell http://purl.obolibrary.org/obo/CLO_0000257 cell line http://purl.obolibrary.org/obo/CLO_0000031 Breast tissue breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Breast tissue, cancer breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +breast tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Breast tumor sample breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +breast tumor tissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +BreastTumorTissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 Bronchial Epithelia epithelium of main bronchus http://purl.obolibrary.org/obo/UBERON_0002340 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Bronchial Epithelium epithelium of bronchus http://purl.obolibrary.org/obo/UBERON_0002031 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Bronchoalveolar lavage bronchoalveolar lavage http://purl.obolibrary.org/obo/BTO_0000155 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 Brown Adipose Tissue brown adipose tissue http://purl.obolibrary.org/obo/UBERON_0001348 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Brown Norway Brown Norway http://www.ebi.ac.uk/efo/EFO_0005290 strain http://www.ebi.ac.uk/efo/EFO_0005135 buccal mucosa buccal mucosa http://purl.obolibrary.org/obo/UBERON_0006956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -C Caucasian http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +C-Section cesarean section http://www.ebi.ac.uk/efo/EFO_0009636 treatment http://www.ebi.ac.uk/efo/EFO_0000727 C2C12 RCB0987 cell http://purl.obolibrary.org/obo/CLO_0050871 cell line http://purl.obolibrary.org/obo/CLO_0000031 C3H Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 C3H/HeJ C3H/HeJ http://www.ebi.ac.uk/efo/EFO_0001329 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C56BL/6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C56BL/6J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C56Bl/6N C57BL/6NCrl http://www.ebi.ac.uk/efo/EFO_0011030 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57/B6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57/BL6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C57B/6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57B6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C57B6/J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL/6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C57BL/6 mice C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL/6J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL/6J mouse C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 -C57BL/6N C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C57BL\\6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL6 C57BL/6 http://www.ebi.ac.uk/efo/EFO_0022397 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL6/J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 +C57bl6/N C57BL/6NCrl http://www.ebi.ac.uk/efo/EFO_0011030 strain http://www.ebi.ac.uk/efo/EFO_0005135 C57BL6J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 +CA1 CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 CA1 hippocampal subregion CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -CA1 hippocampus CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +CA1 Hippocampus CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +CA3 CA3 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003883 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Caffeine caffeine http://purl.obolibrary.org/obo/CHEBI_27732 treatment http://www.ebi.ac.uk/efo/EFO_0000727 Calu-3 Calu-3 cell http://purl.obolibrary.org/obo/CLO_0002192 cell line http://purl.obolibrary.org/obo/CLO_0000031 cancer cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 +cancer cell line cancer cell line http://www.ebi.ac.uk/efo/EFO_0001639 cell line http://purl.obolibrary.org/obo/CLO_0000031 cancer tumor cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 Canton S Canton-S http://www.ebi.ac.uk/efo/EFO_0001325 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Capillary blood capillary blood http://purl.obolibrary.org/obo/UBERON_0013757 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Carcinoma carcinoma http://purl.obolibrary.org/obo/MONDO_0004993 disease http://www.ebi.ac.uk/efo/EFO_0000408 CAU European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +CAUC European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 caucasian European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 Caucasian origin European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +caudate caudate nucleus http://purl.obolibrary.org/obo/UBERON_0001873 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Caudate Nucleus caudate nucleus http://purl.obolibrary.org/obo/UBERON_0001873 organism part http://www.ebi.ac.uk/efo/EFO_0000635 CBA/CaJ CBA/CaJ http://www.ebi.ac.uk/efo/EFO_0001336 strain http://www.ebi.ac.uk/efo/EFO_0005135 CBA/J CBA/J http://www.ebi.ac.uk/efo/EFO_0007735 strain http://www.ebi.ac.uk/efo/EFO_0005135 +ccRCC tumour tissue clear cell renal carcinoma http://purl.obolibrary.org/obo/MONDO_0005005 disease http://www.ebi.ac.uk/efo/EFO_0000408 CD-1 CD1 mus strain http://www.ebi.ac.uk/efo/EFO_0005180 strain http://www.ebi.ac.uk/efo/EFO_0005135 +CD-1 mouse CD1 mus strain http://www.ebi.ac.uk/efo/EFO_0005180 strain http://www.ebi.ac.uk/efo/EFO_0005135 CD1 CD1 mus strain http://www.ebi.ac.uk/efo/EFO_0005180 strain http://www.ebi.ac.uk/efo/EFO_0005135 CD34+ mononuclear mononuclear cell http://purl.obolibrary.org/obo/CL_0000842 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +CD4 T cells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +CD4 T-cell CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD4+ lymphocyte CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD4+ T cell CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD4+ T cells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD4+ T-cells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +CD4+ Tcells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD8 T cells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +CD8 T-cell CD8-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000625 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CD8+ T cells CD8-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000625 cell type http://www.ebi.ac.uk/efo/EFO_0000324 CDF Fisher 344 Fischer 344 http://www.ebi.ac.uk/efo/EFO_0000176 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Cecum caecum http://purl.obolibrary.org/obo/UBERON_0001153 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Celiac Disease celiac disease http://purl.obolibrary.org/obo/MONDO_0005130 disease http://www.ebi.ac.uk/efo/EFO_0000408 +cell culture cell culture http://purl.obolibrary.org/obo/OBI_0001876 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +central amygdala central amygdaloid nucleus http://purl.obolibrary.org/obo/UBERON_0002883 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Central Nucleus of Amygdala central amygdaloid nucleus http://purl.obolibrary.org/obo/UBERON_0002883 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +central nucleus of the amygdala central amygdaloid nucleus http://purl.obolibrary.org/obo/UBERON_0002883 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cerebella cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 cerebellar cortex cerebellar cortex http://purl.obolibrary.org/obo/UBERON_0002129 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cerebellar Purkinje Cells Purkinje cell http://purl.obolibrary.org/obo/CL_0000121 cell type http://www.ebi.ac.uk/efo/EFO_0000324 cerebellum cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Cervix uterine cervix http://purl.obolibrary.org/obo/UBERON_0000002 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +cerebrum cerebral hemisphere http://purl.obolibrary.org/obo/UBERON_0001869 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cervical cancer cervical cancer http://purl.obolibrary.org/obo/MONDO_0002974 disease http://www.ebi.ac.uk/efo/EFO_0000408 +cervical spinal cord cervical spinal cord http://purl.obolibrary.org/obo/UBERON_0002726 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cervical tumor cervical cancer http://purl.obolibrary.org/obo/MONDO_0002974 disease http://www.ebi.ac.uk/efo/EFO_0000408 +cervix uterine cervix http://purl.obolibrary.org/obo/UBERON_0000002 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Chinese Chinese http://purl.obolibrary.org/obo/HANCESTRO_0021 population http://purl.obolibrary.org/obo/OBI_0000181 +Chinese patient Chinese http://purl.obolibrary.org/obo/HANCESTRO_0021 population http://purl.obolibrary.org/obo/OBI_0000181 Chloroprene chloroprene http://purl.obolibrary.org/obo/CHEBI_39481 treatment http://www.ebi.ac.uk/efo/EFO_0000727 cholangiocarcinoma cholangiocarcinoma http://purl.obolibrary.org/obo/MONDO_0019087 disease http://www.ebi.ac.uk/efo/EFO_0000408 Choroid Plexus choroid plexus http://purl.obolibrary.org/obo/UBERON_0001886 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +chow reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 +Chow diet reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 CHP cumene hydroperoxide http://purl.obolibrary.org/obo/CHEBI_78673 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +chromosome 11 trisomy chromosome 11q trisomy http://purl.obolibrary.org/obo/MONDO_0022173 disease http://www.ebi.ac.uk/efo/EFO_0000408 +chromosome 19 trisomy distal trisomy 19q http://purl.obolibrary.org/obo/MONDO_0015744 disease http://www.ebi.ac.uk/efo/EFO_0000408 chronic hepatitis C hepatitis C virus infection http://purl.obolibrary.org/obo/MONDO_0005231 disease http://www.ebi.ac.uk/efo/EFO_0000408 chronic Hodgkin lymphoma Hodgkins lymphoma http://purl.obolibrary.org/obo/MONDO_0004952 disease http://www.ebi.ac.uk/efo/EFO_0000408 +chronic lymphocytic leukemia chronic lymphocytic leukemia/small lymphocytic lymphoma http://purl.obolibrary.org/obo/MONDO_0003864 disease http://www.ebi.ac.uk/efo/EFO_0000408 chronic lymphocytic leukemia B-cell B-cell chronic lymphocytic leukemia http://purl.obolibrary.org/obo/MONDO_0004948 disease http://www.ebi.ac.uk/efo/EFO_0000408 +cingulate cortex cingulate cortex http://purl.obolibrary.org/obo/UBERON_0003027 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cingulate Gyrus cingulate gyrus http://purl.obolibrary.org/obo/UBERON_0002967 organism part http://www.ebi.ac.uk/efo/EFO_0000635 circulating leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Circulating mononuclear cells peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +cirrhosis cirrhosis of liver http://purl.obolibrary.org/obo/MONDO_0005155 disease http://www.ebi.ac.uk/efo/EFO_0000408 clear cell renal cell carcinoma clear cell renal carcinoma http://purl.obolibrary.org/obo/MONDO_0005005 disease http://www.ebi.ac.uk/efo/EFO_0000408 Clear-cell renal cell carcinoma clear cell renal carcinoma http://purl.obolibrary.org/obo/MONDO_0005005 disease http://www.ebi.ac.uk/efo/EFO_0000408 Clinical Breast Cancer Specimen breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +CNS central nervous system http://purl.obolibrary.org/obo/UBERON_0001017 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Cocaine cocaine http://purl.obolibrary.org/obo/CHEBI_27958 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +cochlea cochlea http://purl.obolibrary.org/obo/UBERON_0001844 organism part http://www.ebi.ac.uk/efo/EFO_0000635 colitis colitis http://purl.obolibrary.org/obo/MONDO_0005292 disease http://www.ebi.ac.uk/efo/EFO_0000408 Colon colon http://purl.obolibrary.org/obo/UBERON_0001155 organism part http://www.ebi.ac.uk/efo/EFO_0000635 colon adenocarcinoma cells colon adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0002271 disease http://www.ebi.ac.uk/efo/EFO_0000408 +colon adenocarcinoma stage II colon adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0002271 disease http://www.ebi.ac.uk/efo/EFO_0000408 colon cancer malignant colon neoplasm http://purl.obolibrary.org/obo/MONDO_0021063 disease http://www.ebi.ac.uk/efo/EFO_0000408 Colon tissue from patient with colon cancer malignant colon neoplasm http://purl.obolibrary.org/obo/MONDO_0021063 disease http://www.ebi.ac.uk/efo/EFO_0000408 colon tumor malignant colon neoplasm http://purl.obolibrary.org/obo/MONDO_0021063 disease http://www.ebi.ac.uk/efo/EFO_0000408 -colonic biopsy colon http://purl.obolibrary.org/obo/UBERON_0001155 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Colorecal Cancer colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 colorectal adenocarcinoma colorectal adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005008 disease http://www.ebi.ac.uk/efo/EFO_0000408 colorectal cancer colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 -colorectal cancer biopsy colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 +colorectal cancer cell line colorectal cancer cell line http://purl.obolibrary.org/obo/BTO_0001616 cell line http://purl.obolibrary.org/obo/CLO_0000031 colorectal cancer cell line colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 Colorectal cancer patient colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 +colorectal carcinoma cell line colorectal cancer cell line http://purl.obolibrary.org/obo/BTO_0001616 cell line http://purl.obolibrary.org/obo/CLO_0000031 +common reference sample reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 common reference sample compsed of total RNAs isolated from whole blood from 20 Prachatice children blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Con reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 Cone photoreceptor cone retinal bipolar cell http://purl.obolibrary.org/obo/CL_0000752 cell type http://www.ebi.ac.uk/efo/EFO_0000324 control reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 -copd chronic obstructive pulmonary disease http://purl.obolibrary.org/obo/MONDO_0005002 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Control - 8 weeks reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Control (0) reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +control (C) reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +control (no ionizing radiation) reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +control (vehicle) reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Control diet reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 +Control subject reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +COPD chronic obstructive pulmonary disease http://purl.obolibrary.org/obo/MONDO_0005002 disease http://www.ebi.ac.uk/efo/EFO_0000408 +COPD Subjects chronic obstructive pulmonary disease http://purl.obolibrary.org/obo/MONDO_0005002 disease http://www.ebi.ac.uk/efo/EFO_0000408 Cord blood umbilical cord blood http://purl.obolibrary.org/obo/UBERON_0012168 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Corn Oil corn oil http://purl.obolibrary.org/obo/CHEBI_195250 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +corpus callosum corpus callosum http://purl.obolibrary.org/obo/UBERON_0002336 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Corpus Striatum corpus striatum http://purl.obolibrary.org/obo/UBERON_0000369 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +cortical cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Cortical neuron cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Cortical neurons cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Cranial neural crest cells cranial neural crest http://purl.obolibrary.org/obo/UBERON_0003099 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +CTL reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +ctr reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +CTRL reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Cultured airway epithelial cells (basal cells) basal cell of epithelium of bronchus http://purl.obolibrary.org/obo/CL_1000349 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Cultured cortical neurons cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Cultured organotypic cerebellar slices cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Cultured postnatal astrocytes from cerebral cortex astrocyte of the cerebral cortex http://purl.obolibrary.org/obo/CL_0002605 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Current Smoker smoking behavior http://www.ebi.ac.uk/efo/EFO_0004318 environmental history http://www.ebi.ac.uk/efo/EFO_0004444 +Day0 initial time point http://www.ebi.ac.uk/efo/EFO_0004425 timepoint http://www.ebi.ac.uk/efo/EFO_0000724 DBA DBA http://www.ebi.ac.uk/efo/EFO_0022419 strain http://www.ebi.ac.uk/efo/EFO_0005135 +DCIS high grade ductal breast carcinoma in situ http://purl.obolibrary.org/obo/MONDO_0005023 disease http://www.ebi.ac.uk/efo/EFO_0000408 +de novo AML acute myeloid leukemia with multilineage dysplasia http://purl.obolibrary.org/obo/MONDO_0019456 disease http://www.ebi.ac.uk/efo/EFO_0000408 Dead death stage http://purl.obolibrary.org/obo/UBERON_0000071 environmental history http://www.ebi.ac.uk/efo/EFO_0004444 Dechorionated embryo embryo http://purl.obolibrary.org/obo/UBERON_0000922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 deltoid deltoid http://purl.obolibrary.org/obo/UBERON_0001476 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dendritic cells dendritic cell http://purl.obolibrary.org/obo/CL_0000451 cell type http://www.ebi.ac.uk/efo/EFO_0000324 dengue shock syndrome dengue shock syndrome http://purl.obolibrary.org/obo/MONDO_0000248 disease http://www.ebi.ac.uk/efo/EFO_0000408 -dermal fibroblasts fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Dentate Gyrus dentate gyrus of hippocampal formation http://purl.obolibrary.org/obo/UBERON_0001885 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Dentate Gyrus Hippocampus dentate gyrus of hippocampal formation http://purl.obolibrary.org/obo/UBERON_0001885 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dermal fibroblasts skin fibroblast http://purl.obolibrary.org/obo/CL_0002620 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Descending colon descending colon http://purl.obolibrary.org/obo/UBERON_0001158 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dexamethasone dexamethasone http://purl.obolibrary.org/obo/CHEBI_41879 treatment http://www.ebi.ac.uk/efo/EFO_0000727 -diabetic diabetes mellitus http://purl.obolibrary.org/obo/MONDO_0005015 disease http://www.ebi.ac.uk/efo/EFO_0000408 -differentiated adipocytes fat cell http://purl.obolibrary.org/obo/CL_0000136 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +DFC dorsolateral prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0009834 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Diabetic diabetes mellitus http://purl.obolibrary.org/obo/MONDO_0005015 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Diagnostic_acute_leukemia acute leukemia http://purl.obolibrary.org/obo/MONDO_0010643 disease http://www.ebi.ac.uk/efo/EFO_0000408 +differentiated adipocytes adipocyte http://purl.obolibrary.org/obo/CL_0000136 cell type http://www.ebi.ac.uk/efo/EFO_0000324 diffuse intrinsic pontine glioma diffuse intrinsic pontine glioma http://purl.obolibrary.org/obo/MONDO_0006033 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Diffuse large B-cell lymphoma diffuse large B-cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018905 disease http://www.ebi.ac.uk/efo/EFO_0000408 +diffuse large B-cell lymphoma (DLBCL) diffuse large B-cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018905 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Dilated cardiomyopathy dilated cardiomyopathy http://purl.obolibrary.org/obo/MONDO_0005021 disease http://www.ebi.ac.uk/efo/EFO_0000408 Distal colon left colon http://purl.obolibrary.org/obo/UBERON_0008971 organism part http://www.ebi.ac.uk/efo/EFO_0000635 distal lung epithelium lung epithelium http://purl.obolibrary.org/obo/UBERON_0000115 organism part http://www.ebi.ac.uk/efo/EFO_0000635 DLBCL diffuse large B-cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018905 disease http://www.ebi.ac.uk/efo/EFO_0000408 -DLBCL frozen biopsy diffuse large B-cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018905 disease http://www.ebi.ac.uk/efo/EFO_0000408 DLBCL patient sample diffuse large B-cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018905 disease http://www.ebi.ac.uk/efo/EFO_0000408 DLPFC dorsolateral prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0009834 organism part http://www.ebi.ac.uk/efo/EFO_0000635 DMSO dimethyl sulfoxide http://purl.obolibrary.org/obo/CHEBI_28262 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +DMSO control reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Dorsal dentate gyrus dentate gyrus of hippocampal formation http://purl.obolibrary.org/obo/UBERON_0001885 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsal forebrain forebrain http://purl.obolibrary.org/obo/UBERON_0001890 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsal hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Dorsal Lateral Prefrontal Cortex dorsolateral prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0009834 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsal lateral prefrontal cortex (Brodmann Area 9) Brodmann (1909) area 9 http://purl.obolibrary.org/obo/UBERON_0013540 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsal raphe nucleus dorsal raphe nucleus http://purl.obolibrary.org/obo/UBERON_0002043 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Dorsal root ganglia dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsal root ganglia dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsal root ganglia (DRG) dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsal root ganglion dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsal skin skin of back http://purl.obolibrary.org/obo/UBERON_0001068 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsal striatum dorsal striatum http://purl.obolibrary.org/obo/UBERON_0005382 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsal telencephalon dorsal pallium http://purl.obolibrary.org/obo/UBERON_0014740 organism part http://www.ebi.ac.uk/efo/EFO_0000635 dorsolateral prefrontal cortex dorsolateral prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0009834 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dorsolateral prefrontal cortex (DLPFC) dorsolateral prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0009834 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Down syndrome Down syndrome http://purl.obolibrary.org/obo/MONDO_0008608 disease http://www.ebi.ac.uk/efo/EFO_0000408 +dox doxycycline http://purl.obolibrary.org/obo/CHEBI_50845 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Dox+ doxycycline http://purl.obolibrary.org/obo/CHEBI_50845 treatment http://www.ebi.ac.uk/efo/EFO_0000727 doxycycline doxycycline http://purl.obolibrary.org/obo/CHEBI_50845 treatment http://www.ebi.ac.uk/efo/EFO_0000727 DRG dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +DRG_RNA dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +DRGs dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0000044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +DU145 DU 145 http://www.ebi.ac.uk/efo/EFO_0005441 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Duodenum duodenum http://purl.obolibrary.org/obo/UBERON_0002114 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +dura mater dura mater http://purl.obolibrary.org/obo/UBERON_0002363 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Dutch European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +EAE experimental autoimmune encephalomyelitis http://purl.obolibrary.org/obo/MONDO_0005134 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ear tissue ear http://purl.obolibrary.org/obo/UBERON_0001690 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +EBV-transformed B lymphocytes Epstein Barr virus transformed B cell http://purl.obolibrary.org/obo/OBI_0100010 cell type http://www.ebi.ac.uk/efo/EFO_0000324 EBV-transformed B lymphocytes lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 +EBV-transformed B-cells Epstein Barr virus transformed B cell http://purl.obolibrary.org/obo/OBI_0100010 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +EBV-transformed lymphoblastoid cell line Epstein Barr virus transformed B cell http://purl.obolibrary.org/obo/OBI_0100010 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +EBV-transformed lymphoblastoid cells Epstein Barr virus transformed B cell http://purl.obolibrary.org/obo/OBI_0100010 cell type http://www.ebi.ac.uk/efo/EFO_0000324 EBV-transformed lymphoblastoid cells lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 ECC-1 ECC-1 cell http://purl.obolibrary.org/obo/CLO_0037231 cell line http://purl.obolibrary.org/obo/CLO_0000031 -embryo embryo stage http://purl.obolibrary.org/obo/UBERON_0000068 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +embryo embryo http://purl.obolibrary.org/obo/UBERON_0000922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Embryoid bodies embryo http://purl.obolibrary.org/obo/UBERON_0000922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +embryonic brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +embryonic cerebral cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Embryonic cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 embryonic fibroblast embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 embryonic fibroblasts embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +embryonic kidney kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 embryonic stem cell embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Embryonic stem cells embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +empty vector wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +Endometrioid endometrioid tumor http://purl.obolibrary.org/obo/MONDO_0002480 disease http://www.ebi.ac.uk/efo/EFO_0000408 endometrium endometrium http://purl.obolibrary.org/obo/UBERON_0001295 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +endothelial endothelial cell http://purl.obolibrary.org/obo/CL_0000115 cell type http://www.ebi.ac.uk/efo/EFO_0000324 endothelial cell endothelial cell http://purl.obolibrary.org/obo/CL_0000115 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +endothelial cells endothelial cell http://purl.obolibrary.org/obo/CL_0000115 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Entorhinal Cortex entorhinal cortex http://purl.obolibrary.org/obo/UBERON_0002728 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Ependymoma brain tumor ependymoma http://purl.obolibrary.org/obo/MONDO_0016698 disease http://www.ebi.ac.uk/efo/EFO_0000408 epidermis skin epidermis http://purl.obolibrary.org/obo/UBERON_0001003 organism part http://www.ebi.ac.uk/efo/EFO_0000635 epididymal adipose tissue epididymal fat pad http://purl.obolibrary.org/obo/UBERON_0010412 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +epididymal white adipose tissue white adipose tissue http://purl.obolibrary.org/obo/UBERON_0001347 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Epididymal white adipose tissue epididymal fat pad http://purl.obolibrary.org/obo/UBERON_0010412 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -epilepsy epilepsy http://purl.obolibrary.org/obo/MONDO_0005027 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Epilepsy epilepsy http://purl.obolibrary.org/obo/MONDO_0005027 disease http://www.ebi.ac.uk/efo/EFO_0000408 +epithelial cells epithelial cell http://purl.obolibrary.org/obo/CL_0000066 cell type http://www.ebi.ac.uk/efo/EFO_0000324 epithelial cells from the inferior nasal turbinate inferior nasal concha http://purl.obolibrary.org/obo/UBERON_0005922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 epithelian ovarian tumor malignant epithelial tumor of ovary http://purl.obolibrary.org/obo/MONDO_0018364 disease http://www.ebi.ac.uk/efo/EFO_0000408 +epithelium epithelium http://purl.obolibrary.org/obo/UBERON_0000483 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Epstein-Barr virus (EBV) transformed B cells Epstein Barr virus transformed B cell http://purl.obolibrary.org/obo/OBI_0100010 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +ER Positive estrogen-receptor positive breast cancer http://purl.obolibrary.org/obo/MONDO_0006512 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ER- estrogen-receptor negative breast cancer http://purl.obolibrary.org/obo/MONDO_0006513 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ER(-) estrogen-receptor negative breast cancer http://purl.obolibrary.org/obo/MONDO_0006513 disease http://www.ebi.ac.uk/efo/EFO_0000408 ER+ estrogen-receptor positive breast cancer http://purl.obolibrary.org/obo/MONDO_0006512 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ERneg estrogen-receptor negative breast cancer http://purl.obolibrary.org/obo/MONDO_0006513 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ERpos estrogen-receptor positive breast cancer http://purl.obolibrary.org/obo/MONDO_0006512 disease http://www.ebi.ac.uk/efo/EFO_0000408 ES cell embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 ES cell culture embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 ES cells embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +ES-derived neural progenitor cells neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 ESC embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 esophageal squamous cell carcinoma esophageal squamous cell carcinoma http://purl.obolibrary.org/obo/MONDO_0005580 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Esophagus esophagus http://purl.obolibrary.org/obo/UBERON_0001043 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +esophagus esophagus http://purl.obolibrary.org/obo/UBERON_0001043 organism part http://www.ebi.ac.uk/efo/EFO_0000635 esphageal squamous cell carcinoma esophageal squamous cell carcinoma http://purl.obolibrary.org/obo/MONDO_0005580 disease http://www.ebi.ac.uk/efo/EFO_0000408 -ethanol ethanol http://purl.obolibrary.org/obo/CHEBI_16236 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Ethanol ethanol http://purl.obolibrary.org/obo/CHEBI_16236 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +EtOH ethanol http://purl.obolibrary.org/obo/CHEBI_16236 treatment http://www.ebi.ac.uk/efo/EFO_0000727 European European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +ex-vivo Liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Exercise exercise http://www.ebi.ac.uk/efo/EFO_0000483 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +exercised exercise http://www.ebi.ac.uk/efo/EFO_0000483 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +extracellular vesicles extracellular vesicle http://purl.obolibrary.org/obo/GO_1903561 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Extracellular vesicles derived from plasma extracellular vesicle http://purl.obolibrary.org/obo/GO_1903561 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +extraembryonic placenta placenta http://purl.obolibrary.org/obo/UBERON_0001987 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Extremities sarcoma sarcoma http://purl.obolibrary.org/obo/MONDO_0005089 disease http://www.ebi.ac.uk/efo/EFO_0000408 +eye eye http://purl.obolibrary.org/obo/UBERON_0000970 organism part http://www.ebi.ac.uk/efo/EFO_0000635 F female http://purl.obolibrary.org/obo/PATO_0000383 biological sex http://purl.obolibrary.org/obo/PATO_0000047 F344 Fischer 344 http://www.ebi.ac.uk/efo/EFO_0000176 strain http://www.ebi.ac.uk/efo/EFO_0005135 +F344/NCrl Fischer 344 http://www.ebi.ac.uk/efo/EFO_0000176 strain http://www.ebi.ac.uk/efo/EFO_0005135 FEM female http://purl.obolibrary.org/obo/PATO_0000383 biological sex http://purl.obolibrary.org/obo/PATO_0000047 female female http://purl.obolibrary.org/obo/PATO_0000383 biological sex http://purl.obolibrary.org/obo/PATO_0000047 -femur femur http://purl.obolibrary.org/obo/UBERON_0000981 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +females female http://purl.obolibrary.org/obo/PATO_0000383 biological sex http://purl.obolibrary.org/obo/PATO_0000047 +Femur femur http://purl.obolibrary.org/obo/UBERON_0000981 organism part http://www.ebi.ac.uk/efo/EFO_0000635 fetal brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +fetal brain tissue brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +fetal liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Fetal pituitary pituitary gland http://purl.obolibrary.org/obo/UBERON_0000007 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Fetal testis testis http://purl.obolibrary.org/obo/UBERON_0000473 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +fetus late embryonic stage http://purl.obolibrary.org/obo/UBERON_0007220 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +FFPE FFPE specimen http://purl.obolibrary.org/obo/OBI_1200000 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +FFPE Gastric Adenocarcinoma gastric adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005036 disease http://www.ebi.ac.uk/efo/EFO_0000408 Fibroblast fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 -Fibroblasts fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +fibroblasts fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +First lower molar lower first primary molar tooth http://purl.obolibrary.org/obo/UBERON_0018589 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Fischer 344 Fischer 344 http://www.ebi.ac.uk/efo/EFO_0000176 strain http://www.ebi.ac.uk/efo/EFO_0005135 Fisher 344 Fischer 344 http://www.ebi.ac.uk/efo/EFO_0000176 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Fluoxetine fluoxetine http://purl.obolibrary.org/obo/CHEBI_5118 treatment http://www.ebi.ac.uk/efo/EFO_0000727 follicular lymphoma tumor follicular lymphoma http://purl.obolibrary.org/obo/MONDO_0018906 disease http://www.ebi.ac.uk/efo/EFO_0000408 forebrain forebrain http://purl.obolibrary.org/obo/UBERON_0001890 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Forebrain tissue forebrain http://purl.obolibrary.org/obo/UBERON_0001890 organism part http://www.ebi.ac.uk/efo/EFO_0000635 foreskin prepuce of penis http://purl.obolibrary.org/obo/UBERON_0001332 organism part http://www.ebi.ac.uk/efo/EFO_0000635 formaldehyde formaldehyde http://purl.obolibrary.org/obo/CHEBI_16842 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +fresh frozen laryngeal tumor larynx cancer http://purl.obolibrary.org/obo/MONDO_0002352 disease http://www.ebi.ac.uk/efo/EFO_0000408 fresh/frozen lymphoma tissue lymphoma http://purl.obolibrary.org/obo/MONDO_0005062 disease http://www.ebi.ac.uk/efo/EFO_0000408 freshly frozen lymph nodes lymph node http://purl.obolibrary.org/obo/UBERON_0000029 organism part http://www.ebi.ac.uk/efo/EFO_0000635 frontal cortex frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +frontal lobe frontal lobe http://purl.obolibrary.org/obo/UBERON_0016525 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +frontal_cortex frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 frozen breast tissue breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 frozen tissue of ovarian tumors ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 frozen tissue of primary breast tumors breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +frozen tissue of primary lung tumor lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 +frozen tissue of primary lung tumors lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 full-thickness colon colon http://purl.obolibrary.org/obo/UBERON_0001155 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -fvb FVB http://www.ebi.ac.uk/efo/EFO_0022483 strain http://www.ebi.ac.uk/efo/EFO_0005135 -fvb/n FVB/N http://www.ebi.ac.uk/efo/EFO_0022467 strain http://www.ebi.ac.uk/efo/EFO_0005135 +fusiform gyrus fusiform gyrus http://purl.obolibrary.org/obo/UBERON_0002766 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +FVB FVB http://www.ebi.ac.uk/efo/EFO_0022483 strain http://www.ebi.ac.uk/efo/EFO_0005135 +FVB/N FVB/N http://www.ebi.ac.uk/efo/EFO_0022467 strain http://www.ebi.ac.uk/efo/EFO_0005135 fvb/nj FVB/NJ http://www.ebi.ac.uk/efo/EFO_0007728 strain http://www.ebi.ac.uk/efo/EFO_0005135 gactrocnemius muscle gastrocnemius http://purl.obolibrary.org/obo/UBERON_0001388 organism part http://www.ebi.ac.uk/efo/EFO_0000635 gastric adenocarcinoma gastric adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005036 disease http://www.ebi.ac.uk/efo/EFO_0000408 gastric cancer gastric cancer http://purl.obolibrary.org/obo/MONDO_0001056 disease http://www.ebi.ac.uk/efo/EFO_0000408 +gastric cancer tissue gastric cancer http://purl.obolibrary.org/obo/MONDO_0001056 disease http://www.ebi.ac.uk/efo/EFO_0000408 +gastric tumor tissue gastric neoplasm http://purl.obolibrary.org/obo/MONDO_0021085 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Gastrocnemius gastrocnemius http://purl.obolibrary.org/obo/UBERON_0001388 organism part http://www.ebi.ac.uk/efo/EFO_0000635 gastrocnemius muscle gastrocnemius http://purl.obolibrary.org/obo/UBERON_0001388 organism part http://www.ebi.ac.uk/efo/EFO_0000635 GBM glioblastoma http://purl.obolibrary.org/obo/MONDO_0018177 disease http://www.ebi.ac.uk/efo/EFO_0000408 +GBM Tissue glioblastoma http://purl.obolibrary.org/obo/MONDO_0018177 disease http://www.ebi.ac.uk/efo/EFO_0000408 +GENDER_male male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 genistein genistein http://purl.obolibrary.org/obo/CHEBI_28088 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Germ cell tumor germ cell tumor http://purl.obolibrary.org/obo/MONDO_0005040 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Gingival gingiva http://purl.obolibrary.org/obo/UBERON_0001828 organism part http://www.ebi.ac.uk/efo/EFO_0000635 GIST Tumor gastrointestinal stromal tumor http://purl.obolibrary.org/obo/MONDO_0011719 disease http://www.ebi.ac.uk/efo/EFO_0000408 Glioblastoma glioblastoma http://purl.obolibrary.org/obo/MONDO_0018177 disease http://www.ebi.ac.uk/efo/EFO_0000408 +glioblastoma cells glioblastoma http://purl.obolibrary.org/obo/MONDO_0018177 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Glioblastoma multiforme glioblastoma multiforme http://www.ebi.ac.uk/efo/EFO_0000519 disease http://www.ebi.ac.uk/efo/EFO_0000408 Glioblastoma multiforme glioblastoma http://purl.obolibrary.org/obo/MONDO_0018177 disease http://www.ebi.ac.uk/efo/EFO_0000408 glioma malignant glioma http://purl.obolibrary.org/obo/MONDO_0100342 disease http://www.ebi.ac.uk/efo/EFO_0000408 +gonadal white adipose tissue gonadal fat pad http://purl.obolibrary.org/obo/UBERON_0003428 organism part http://www.ebi.ac.uk/efo/EFO_0000635 granule cell granule cell http://purl.obolibrary.org/obo/CL_0000120 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Grey Matter gray matter http://purl.obolibrary.org/obo/UBERON_0002020 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ground control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +H1N1 swine influenza http://purl.obolibrary.org/obo/MONDO_0005460 disease http://www.ebi.ac.uk/efo/EFO_0000408 +H9 H9 http://www.ebi.ac.uk/efo/EFO_0003045 cell line http://purl.obolibrary.org/obo/CLO_0000031 H9 H9 ES cell http://purl.obolibrary.org/obo/CLO_0037313 cell line http://purl.obolibrary.org/obo/CLO_0000031 +H9 hESC H9 cell http://purl.obolibrary.org/obo/CLO_0003612 cell line http://purl.obolibrary.org/obo/CLO_0000031 +hair follicle hair follicle http://purl.obolibrary.org/obo/UBERON_0002073 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +HapMap CEU European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +HBV positive Hepatocellular Carcinoma (HCC) hepatitis B virus induced hepatocellular carcinoma http://www.ebi.ac.uk/efo/EFO_0008503 disease http://www.ebi.ac.uk/efo/EFO_0000408 +HC reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +HCT-116 HCT 116 cell http://purl.obolibrary.org/obo/CLO_0003665 cell line http://purl.obolibrary.org/obo/CLO_0000031 HCT116 HCT 116 cell http://purl.obolibrary.org/obo/CLO_0003665 cell line http://purl.obolibrary.org/obo/CLO_0000031 +HCV-infected hepatitis C virus infection http://purl.obolibrary.org/obo/MONDO_0005231 disease http://www.ebi.ac.uk/efo/EFO_0000408 head head http://purl.obolibrary.org/obo/UBERON_0000033 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +head and neck squamous cell carcinoma head and neck squamous cell carcinoma http://purl.obolibrary.org/obo/MONDO_0010150 disease http://www.ebi.ac.uk/efo/EFO_0000408 Healthy reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Healthy control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 healthy control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Healthy controls reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +healthy donor reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +healthy subject reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 Healthy volunteer reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 healthy volunteers reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 Heart heart http://purl.obolibrary.org/obo/UBERON_0000948 organism part http://www.ebi.ac.uk/efo/EFO_0000635 heart left ventricle cardiac ventricle http://purl.obolibrary.org/obo/UBERON_0002082 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Heart tissue heart http://purl.obolibrary.org/obo/UBERON_0000948 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +HEK293 HEK293 http://purl.obolibrary.org/obo/CLO_0001230 cell line http://purl.obolibrary.org/obo/CLO_0000031 HEK293T HEK293T cell http://purl.obolibrary.org/obo/CLO_0037372 cell line http://purl.obolibrary.org/obo/CLO_0000031 HeLa HeLa cell http://purl.obolibrary.org/obo/CLO_0003684 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Hela cells HeLa cell http://purl.obolibrary.org/obo/CLO_0003684 cell line http://purl.obolibrary.org/obo/CLO_0000031 +hematoma hematoma http://www.ebi.ac.uk/efo/EFO_0010680 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +Hematopoietic stem cells hematopoietic stem cell http://purl.obolibrary.org/obo/CL_0000037 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Hematopoietic System hematopoietic system http://purl.obolibrary.org/obo/UBERON_0002390 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hepatocellular carcinoma hepatocellular carcinoma http://purl.obolibrary.org/obo/MONDO_0007256 disease http://www.ebi.ac.uk/efo/EFO_0000408 hepatocellular carcinoma (HCC) hepatocellular carcinoma http://purl.obolibrary.org/obo/MONDO_0007256 disease http://www.ebi.ac.uk/efo/EFO_0000408 hepatocyte hepatocyte http://purl.obolibrary.org/obo/CL_0000182 cell type http://www.ebi.ac.uk/efo/EFO_0000324 @@ -275,64 +539,170 @@ hepatocytes hepatocyte http://purl.obolibrary.org/obo/CL_0000182 cell type http: HepG2 Hep G2 cell http://purl.obolibrary.org/obo/CLO_0003704 cell line http://purl.obolibrary.org/obo/CLO_0000031 HepG2 cells Hep G2 cell http://purl.obolibrary.org/obo/CLO_0003704 cell line http://purl.obolibrary.org/obo/CLO_0000031 hermaphrodite hermaphrodite http://purl.obolibrary.org/obo/PATO_0001340 biological sex http://purl.obolibrary.org/obo/PATO_0000047 +hESC embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +hESCs embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +HFD high fat diet http://www.ebi.ac.uk/efo/EFO_0002757 diet http://www.ebi.ac.uk/efo/EFO_0002755 +High Drinker alcohol abuse http://purl.obolibrary.org/obo/MONDO_0002046 disease http://www.ebi.ac.uk/efo/EFO_0000408 high fat high fat diet http://www.ebi.ac.uk/efo/EFO_0002757 diet http://www.ebi.ac.uk/efo/EFO_0002755 +high fat diet high fat diet http://www.ebi.ac.uk/efo/EFO_0002757 diet http://www.ebi.ac.uk/efo/EFO_0002755 +High-fat diet high fat diet http://www.ebi.ac.uk/efo/EFO_0002757 diet http://www.ebi.ac.uk/efo/EFO_0002755 hindbrain hindbrain http://purl.obolibrary.org/obo/UBERON_0002028 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +hip hip http://purl.obolibrary.org/obo/UBERON_0001464 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Hippocampal CA1 CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hippocampal formation hippocampal formation http://purl.obolibrary.org/obo/UBERON_0002421 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hippocampal neurons hippocampal neuron http://purl.obolibrary.org/obo/CL_0002608 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Hippocampal slice Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hippocampal tissue Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hippocampus (CA1 region) CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Hippocampus CA1 area CA1 field of hippocampus http://purl.obolibrary.org/obo/UBERON_0003881 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +hiPSC induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 hispanic Hispanic or Latin American http://purl.obolibrary.org/obo/HANCESTRO_0014 population http://purl.obolibrary.org/obo/OBI_0000181 +Hispanic or Latino Hispanic or Latin American http://purl.obolibrary.org/obo/HANCESTRO_0014 population http://purl.obolibrary.org/obo/OBI_0000181 +HIV HIV infectious disease http://purl.obolibrary.org/obo/MONDO_0005109 disease http://www.ebi.ac.uk/efo/EFO_0000408 +HIV infected individuals HIV infectious disease http://purl.obolibrary.org/obo/MONDO_0005109 disease http://www.ebi.ac.uk/efo/EFO_0000408 HIV positive HIV infectious disease http://purl.obolibrary.org/obo/MONDO_0005109 disease http://www.ebi.ac.uk/efo/EFO_0000408 +HMEC HMEC http://www.ebi.ac.uk/efo/EFO_0001188 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Hodgkin's Lymphoma Hodgkins lymphoma http://purl.obolibrary.org/obo/MONDO_0004952 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Homo sapiens;tissue: blood cells blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +HSC hematopoietic stem cell http://purl.obolibrary.org/obo/CL_0000037 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Huh7 Huh7 cell http://purl.obolibrary.org/obo/CLO_0009989 cell line http://purl.obolibrary.org/obo/CLO_0000031 human adipose tissue adipose tissue http://purl.obolibrary.org/obo/UBERON_0001013 organism part http://www.ebi.ac.uk/efo/EFO_0000635 human airway smooth muscle cells respiratory system smooth muscle http://purl.obolibrary.org/obo/UBERON_0004225 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Human Brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Human Brain (BA10) brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human Brain Tissue: Purkinje Cells Purkinje cell http://purl.obolibrary.org/obo/CL_0000121 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human Breast breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +human breast cancer breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +human breast cancer tumors breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Human Breast tissue breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +human breast tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Human Bronchial Epithelial Cells bronchial epithelial cell http://purl.obolibrary.org/obo/CL_0002328 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human bronchial epithelial cells (HBE) bronchial epithelial cell http://purl.obolibrary.org/obo/CL_0002328 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +human cancer cell line cancer cell line http://www.ebi.ac.uk/efo/EFO_0001639 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Human cell line immortal human cell line cell http://purl.obolibrary.org/obo/CLO_0000020 cell line http://purl.obolibrary.org/obo/CLO_0000031 +human colon colon http://purl.obolibrary.org/obo/UBERON_0001155 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human cord blood umbilical cord blood http://purl.obolibrary.org/obo/UBERON_0012168 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +human cord blood derived T cells T cell http://purl.obolibrary.org/obo/CL_0000084 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human cranial neural crest cells cranial neural crest http://purl.obolibrary.org/obo/UBERON_0003099 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human dendritic cells dendritic cell, human http://purl.obolibrary.org/obo/CL_0001056 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human Dermal Fibroblast skin fibroblast http://purl.obolibrary.org/obo/CL_0002620 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human Embryonic Stem cell embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human embryonic stem cells embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human hepatocellular carcinoma hepatocellular carcinoma http://purl.obolibrary.org/obo/MONDO_0007256 disease http://www.ebi.ac.uk/efo/EFO_0000408 +human induced pluripotent stem cells induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Human intrahepatic cholangiocarcinoma intrahepatic cholangiocarcinoma http://purl.obolibrary.org/obo/MONDO_0003210 disease http://www.ebi.ac.uk/efo/EFO_0000408 +human iPSC derived cell induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 +human leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human neocortex neocortex http://purl.obolibrary.org/obo/UBERON_0001950 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human osteoblast cell lines osteoblast http://purl.obolibrary.org/obo/CL_0000062 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human PBMC peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human PBMC collected from whole blood. peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human peripheral blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human peripheral blood mononuclear cells peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +human placenta placenta http://purl.obolibrary.org/obo/UBERON_0001987 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human polymorphonuclear (PMN) leukocytes neutrophil http://purl.obolibrary.org/obo/CL_0000775 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human post mortem tissue post mortem specimen http://purl.obolibrary.org/obo/OBI_0000902 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +human primary myotube cells myotube http://purl.obolibrary.org/obo/CL_0002372 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human skeletal muscle skeletal muscle tissue http://purl.obolibrary.org/obo/UBERON_0001134 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Human Skeletal Muscle Myoblasts (HSMM) skeletal muscle myoblast http://purl.obolibrary.org/obo/CL_0000515 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human soft tissue sarcoma soft tissue sarcoma http://purl.obolibrary.org/obo/MONDO_0018078 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Human white blood cells leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Human whole blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +HumanAorticEndothelialCells aortic endothelial cell http://purl.obolibrary.org/obo/CL_0002544 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Huntington's disease Huntington disease http://purl.obolibrary.org/obo/MONDO_0007739 disease http://www.ebi.ac.uk/efo/EFO_0000408 +HUVEC endothelial cell of umbilical vein http://purl.obolibrary.org/obo/CL_0002618 cell type http://www.ebi.ac.uk/efo/EFO_0000324 HUVEC HUV-EC-C cell http://purl.obolibrary.org/obo/CLO_0004307 cell line http://purl.obolibrary.org/obo/CLO_0000031 +hyperplasia hyperplasia http://purl.obolibrary.org/obo/MONDO_0005043 disease http://www.ebi.ac.uk/efo/EFO_0000408 +hypertension hypertensive disorder http://purl.obolibrary.org/obo/MONDO_0005044 disease http://www.ebi.ac.uk/efo/EFO_0000408 hypothalamic arcuate nucleus arcuate nucleus of hypothalamus http://purl.obolibrary.org/obo/UBERON_0001932 organism part http://www.ebi.ac.uk/efo/EFO_0000635 hypothalamus hypothalamus http://purl.obolibrary.org/obo/UBERON_0001898 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Hypoxia hypoxia http://www.ebi.ac.uk/efo/EFO_0009444 treatment http://www.ebi.ac.uk/efo/EFO_0000727 ICR ICR/HaJ http://www.ebi.ac.uk/efo/EFO_0009917 strain http://www.ebi.ac.uk/efo/EFO_0005135 -Ileal biopsy ileum http://purl.obolibrary.org/obo/UBERON_0002116 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Ileum ileum http://purl.obolibrary.org/obo/UBERON_0002116 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Immortalized human bronchial epithelial cells immortal human epithelial cell line cell http://purl.obolibrary.org/obo/CLO_0000563 cell line http://purl.obolibrary.org/obo/CLO_0000031 immune cells leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 IMR90 IMR-90 cell http://purl.obolibrary.org/obo/CLO_0006951 cell line http://purl.obolibrary.org/obo/CLO_0000031 +In vitro in vitro design http://purl.obolibrary.org/obo/OBI_0001285 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +in vivo in vivo design http://purl.obolibrary.org/obo/OBI_0001199 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +Induced astrocytes astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +induced pluripotent stem cell induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Induced Pluripotent Stem Cells induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 induced pluripotent stem cells induced pluripotent stem cell http://www.ebi.ac.uk/efo/EFO_0004905 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +induced pluripotent stem cells (iPSCs) induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 infection code: mock control http://www.ebi.ac.uk/efo/EFO_0001461 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Inferior Frontal Gyrus inferior frontal gyrus http://purl.obolibrary.org/obo/UBERON_0002998 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Inferior Temporal Gyrus inferior temporal gyrus http://purl.obolibrary.org/obo/UBERON_0002751 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Inferior termporal cortex inferior temporal gyrus http://purl.obolibrary.org/obo/UBERON_0002751 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Infiltrating Ductal Carcinoma invasive ductal breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004953 disease http://www.ebi.ac.uk/efo/EFO_0000408 Infiltrating Ductal Carcinoma (IDC) invasive ductal breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004953 disease http://www.ebi.ac.uk/efo/EFO_0000408 Inguinal adipose tissue inguinal fat pad http://purl.obolibrary.org/obo/UBERON_0010410 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -invasive breast carcinomas breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004989 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Insulin insulin http://purl.obolibrary.org/obo/CHEBI_145810 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Intermittent hypoxia hypoxia http://www.ebi.ac.uk/efo/EFO_0009444 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Interneurons interneuron http://purl.obolibrary.org/obo/CL_0000099 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +intestinal intestine http://purl.obolibrary.org/obo/UBERON_0000160 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +intestine intestine http://purl.obolibrary.org/obo/UBERON_0000160 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +intrahepatic cholangiocarcinoma intrahepatic cholangiocarcinoma http://purl.obolibrary.org/obo/MONDO_0003210 disease http://www.ebi.ac.uk/efo/EFO_0000408 +invasive breast carcinomas invasive ductal breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004953 disease http://www.ebi.ac.uk/efo/EFO_0000408 +invasive ductal carcinoma invasive ductal breast carcinoma http://purl.obolibrary.org/obo/MONDO_0004953 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Ionizing radiation radiation exposure http://www.ebi.ac.uk/efo/EFO_0020980 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +ionizing radiation (IR) radiation exposure http://www.ebi.ac.uk/efo/EFO_0020980 treatment http://www.ebi.ac.uk/efo/EFO_0000727 iPSC induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 -iPSC-derived neurons neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +iPSC-derived astrocytes astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +iPSCs induced pluripotent stem cell line cell http://purl.obolibrary.org/obo/CLO_0037307 cell line http://purl.obolibrary.org/obo/CLO_0000031 iPSCs induced pluripotent stem cell http://www.ebi.ac.uk/efo/EFO_0004905 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +ipsilateral ipsilateral to http://purl.obolibrary.org/obo/PATO_0002035 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +IPTG isopropyl β-D-thiogalactopyranoside http://purl.obolibrary.org/obo/CHEBI_61448 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +IRd (insulin resistant) insulin resistance http://www.ebi.ac.uk/efo/EFO_0002614 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +irradiated radiation exposure http://www.ebi.ac.uk/efo/EFO_0020980 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Ischaemic heart disease myocardial ischemia http://purl.obolibrary.org/obo/MONDO_0024644 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Ischemic Stroke Ischemic stroke http://purl.obolibrary.org/obo/HP_0002140 disease http://www.ebi.ac.uk/efo/EFO_0000408 Ishikawa Cell Line Ishikawa cell http://purl.obolibrary.org/obo/CLO_0037163 cell line http://purl.obolibrary.org/obo/CLO_0000031 Islets of Langerhans islet of Langerhans http://purl.obolibrary.org/obo/UBERON_0000006 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Isoniazid isoniazide http://purl.obolibrary.org/obo/CHEBI_6030 treatment http://www.ebi.ac.uk/efo/EFO_0000727 Isoproterenol isoprenaline http://purl.obolibrary.org/obo/CHEBI_64317 treatment http://www.ebi.ac.uk/efo/EFO_0000727 Ixabepilone ixabepilone http://purl.obolibrary.org/obo/CHEBI_63605 treatment http://www.ebi.ac.uk/efo/EFO_0000727 jejunum jejunum http://purl.obolibrary.org/obo/UBERON_0002115 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -K-ras Status: Wt wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +Jurkat JURKAT cell http://purl.obolibrary.org/obo/CLO_0007043 cell line http://purl.obolibrary.org/obo/CLO_0000031 +kainate kainate(1−) http://purl.obolibrary.org/obo/CHEBI_156548 treatment http://www.ebi.ac.uk/efo/EFO_0000727 KCl potassium chloride http://purl.obolibrary.org/obo/CHEBI_32588 treatment http://www.ebi.ac.uk/efo/EFO_0000727 kidney kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +kidney cortex cortex of kidney http://purl.obolibrary.org/obo/UBERON_0001225 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +kidney medulla renal medulla http://purl.obolibrary.org/obo/UBERON_0000362 organism part http://www.ebi.ac.uk/efo/EFO_0000635 kidney tissue kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 knockdown gene knockdown http://purl.obolibrary.org/obo/OBI_0002625 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +KRAS wild type wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +Late-stage high-grade ovarian cancer ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Lateral Habenula habenula http://purl.obolibrary.org/obo/UBERON_0001904 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +left lateral liver lobe left lobe of liver http://purl.obolibrary.org/obo/UBERON_0001115 organism part http://www.ebi.ac.uk/efo/EFO_0000635 left liver lobe left lobe of liver http://purl.obolibrary.org/obo/UBERON_0001115 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Left ventricle left ventricle myocardium http://purl.obolibrary.org/obo/UBERON_0006566 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Left ventricle heart left ventricle http://purl.obolibrary.org/obo/UBERON_0002084 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Left ventricle of heart heart left ventricle http://purl.obolibrary.org/obo/UBERON_0002084 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Leiomyosarcoma leiomyosarcoma http://purl.obolibrary.org/obo/MONDO_0005058 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Leukemia leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Lesion lesioned http://purl.obolibrary.org/obo/PATO_0040025 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +lesional lesioned http://purl.obolibrary.org/obo/PATO_0040025 disease http://www.ebi.ac.uk/efo/EFO_0000408 +lesional skin lesioned http://purl.obolibrary.org/obo/PATO_0040025 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +leukemia leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +leukemia cell line leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +leukemia cells leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Leukemia samples leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +leukemic cells leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 Leukemic peripheral blood leukemia http://purl.obolibrary.org/obo/MONDO_0005059 disease http://www.ebi.ac.uk/efo/EFO_0000408 +leukocyte leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +leukocyte transcriptome leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Lewis Lewis http://www.ebi.ac.uk/efo/EFO_0001353 strain http://www.ebi.ac.uk/efo/EFO_0005135 lipopolysaccharide lipopolysaccharide http://purl.obolibrary.org/obo/CHEBI_16412 treatment http://www.ebi.ac.uk/efo/EFO_0000727 lipopolysaccharide (LPS) lipopolysaccharide http://purl.obolibrary.org/obo/CHEBI_16412 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Liposarcoma liposarcoma http://purl.obolibrary.org/obo/MONDO_0005060 disease http://www.ebi.ac.uk/efo/EFO_0000408 liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Liver biopsy liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -liver biopsy specimen liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +liver cirrhosis cirrhosis of liver http://purl.obolibrary.org/obo/MONDO_0005155 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Liver Hepatocellular Carcinoma hepatocellular carcinoma http://purl.obolibrary.org/obo/MONDO_0007256 disease http://www.ebi.ac.uk/efo/EFO_0000408 liver metastasis liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 liver tissue liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -liver tumor liver cancer http://purl.obolibrary.org/obo/MONDO_0002691 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Liver tumor liver cancer http://purl.obolibrary.org/obo/MONDO_0002691 disease http://www.ebi.ac.uk/efo/EFO_0000408 +LNCaP LNCAP cell http://purl.obolibrary.org/obo/CLO_0007365 cell line http://purl.obolibrary.org/obo/CLO_0000031 LNCaP LNCaP cell http://purl.obolibrary.org/obo/CLO_0037116 cell line http://purl.obolibrary.org/obo/CLO_0000031 Location: posterior fossa posterior cranial fossa http://purl.obolibrary.org/obo/UBERON_0008788 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Long Evans Long Evans http://www.ebi.ac.uk/efo/EFO_0022385 strain http://www.ebi.ac.uk/efo/EFO_0005135 @@ -340,246 +710,528 @@ Long-Evans Long Evans http://www.ebi.ac.uk/efo/EFO_0022385 strain http://www.ebi LPS lipopolysaccharide http://purl.obolibrary.org/obo/CHEBI_16412 treatment http://www.ebi.ac.uk/efo/EFO_0000727 lumbar dorsal root ganglion lumbar dorsal root ganglion http://purl.obolibrary.org/obo/UBERON_0002836 organism part http://www.ebi.ac.uk/efo/EFO_0000635 lumbar spinal cord lumbar spinal cord http://purl.obolibrary.org/obo/UBERON_0002792 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +LuminalA luminal A breast carcinoma http://purl.obolibrary.org/obo/MONDO_0021116 disease http://www.ebi.ac.uk/efo/EFO_0000408 lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Lung - Low post-mortem interval lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Lung adenocarcinoma lung adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005061 disease http://www.ebi.ac.uk/efo/EFO_0000408 lung adenocarcinoma cells lung adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005061 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Lung Cancer lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Lung cancer lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 +lung cancer cell line lung cancer cell line http://www.ebi.ac.uk/efo/EFO_0002934 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Lung cancer specimen lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 +lung homogenate lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +lung reference lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Lung sample from recipient organ lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +lung tissue lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 lung tissue lobe of lung http://purl.obolibrary.org/obo/UBERON_0000101 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Lung tumor lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 lungs pair of lungs http://purl.obolibrary.org/obo/UBERON_0000170 organism part http://www.ebi.ac.uk/efo/EFO_0000635 lymph node lymph node http://purl.obolibrary.org/obo/UBERON_0000029 organism part http://www.ebi.ac.uk/efo/EFO_0000635 lymph nodes lymph node http://purl.obolibrary.org/obo/UBERON_0000029 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +lymphoblast lymphoblast http://purl.obolibrary.org/obo/CL_0017005 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +lymphoblast cell lines (LCLs) lymphoblast http://purl.obolibrary.org/obo/CL_0017005 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +lymphoblastoid lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 lymphoblastoid cell line lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Lymphoblastoid cell line (LCL) immortal lymphocyte cell line cell http://purl.obolibrary.org/obo/CLO_0000108 cell line http://purl.obolibrary.org/obo/CLO_0000031 +lymphoblastoid cell lines lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 Lymphoblastoid Cells lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Lymphoblastoid_cell_line lymphoblastoid cell line http://www.ebi.ac.uk/efo/EFO_0005292 cell line http://purl.obolibrary.org/obo/CLO_0000031 +lymphoblasts lymphoblast http://purl.obolibrary.org/obo/CL_0017005 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Lymphocyte TCD4 lymphocyte http://purl.obolibrary.org/obo/CL_0000542 cell type http://www.ebi.ac.uk/efo/EFO_0000324 lymphocytes lymphocyte http://purl.obolibrary.org/obo/CL_0000542 cell type http://www.ebi.ac.uk/efo/EFO_0000324 lymphoma lymphoma http://purl.obolibrary.org/obo/MONDO_0005062 disease http://www.ebi.ac.uk/efo/EFO_0000408 -m male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 +M male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 macrophage macrophage http://purl.obolibrary.org/obo/CL_0000235 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Macrophages macrophage http://purl.obolibrary.org/obo/CL_0000235 cell type http://www.ebi.ac.uk/efo/EFO_0000324 macular Retina macula lutea http://purl.obolibrary.org/obo/UBERON_0000053 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Major Depression major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Major Depressive Disorder major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 +major depressive disorder major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 major depressive disorder (MDD) major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 male male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 +male  male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 Male C57BL/6J C57BL/6J http://www.ebi.ac.uk/efo/EFO_0000606 strain http://www.ebi.ac.uk/efo/EFO_0005135 Males male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 malignant neoplastic, malignant http://purl.obolibrary.org/obo/PATO_0002097 disease http://www.ebi.ac.uk/efo/EFO_0000408 Malignant ovarian ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Mammary fat pad mammary gland fat http://purl.obolibrary.org/obo/UBERON_0004180 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Mammary fat pad mammary fat pad http://purl.obolibrary.org/obo/UBERON_0012282 organism part http://www.ebi.ac.uk/efo/EFO_0000635 mammary gland mammary gland http://purl.obolibrary.org/obo/UBERON_0001911 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mammary tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 mammay fat pads mammary fat pad http://purl.obolibrary.org/obo/UBERON_0012282 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Mantle cell lymphoma mantle cell lymphoma http://purl.obolibrary.org/obo/MONDO_0018876 disease http://www.ebi.ac.uk/efo/EFO_0000408 +match control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Matched Control Group reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Mature, MHCII-high medullary thymic epithelial cell medullary thymic epithelial cell http://purl.obolibrary.org/obo/CL_0002365 cell type http://www.ebi.ac.uk/efo/EFO_0000324 MCF-7 MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 +MCF-7 breast cancer cells MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 MCF-7 Cells MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 MCF10A MCF 10A cell http://purl.obolibrary.org/obo/CLO_0007599 cell line http://purl.obolibrary.org/obo/CLO_0000031 MCF7 MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 +MCF7 Breast Adenocarcinoma Cell Line MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 MCF7 cells after transfection MCF7 cell http://purl.obolibrary.org/obo/CLO_0007606 cell line http://purl.obolibrary.org/obo/CLO_0000031 MDA-MB-231 MDA-MB-231 cell http://purl.obolibrary.org/obo/CLO_0007634 cell line http://purl.obolibrary.org/obo/CLO_0000031 +MDD major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 +MDD case major depressive disorder http://purl.obolibrary.org/obo/MONDO_0002009 disease http://www.ebi.ac.uk/efo/EFO_0000408 MDD sample, brain anterior cingulate cortex anterior cingulate cortex http://purl.obolibrary.org/obo/UBERON_0009835 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +medial collateral ligament medial collateral ligament http://www.ebi.ac.uk/efo/EFO_0001967 organism part http://www.ebi.ac.uk/efo/EFO_0000635 medial ganglionic eminence medial ganglionic eminence http://purl.obolibrary.org/obo/UBERON_0004024 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +medial neocortex neocortex http://purl.obolibrary.org/obo/UBERON_0001950 organism part http://www.ebi.ac.uk/efo/EFO_0000635 medial prefrontal cortex prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +medial prefrontal cortex (mPFC) prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +medio-basal hypothalamus hypothalamus http://purl.obolibrary.org/obo/UBERON_0001898 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Mediobasal hypothalamus hypothalamus http://purl.obolibrary.org/obo/UBERON_0001898 organism part http://www.ebi.ac.uk/efo/EFO_0000635 medulla medulla oblongata http://purl.obolibrary.org/obo/UBERON_0001896 organism part http://www.ebi.ac.uk/efo/EFO_0000635 medullary thymic epithelial cell medullary thymic epithelial cell http://purl.obolibrary.org/obo/CL_0002365 cell type http://www.ebi.ac.uk/efo/EFO_0000324 medulloblastoma medulloblastoma http://purl.obolibrary.org/obo/MONDO_0007959 disease http://www.ebi.ac.uk/efo/EFO_0000408 MEF embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +MEFs embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Melanoma melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Melanoma Cell Line melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 -melanoma lymph node, fresh frozen tissue (>80% tumor cell content, <30% necrosis) melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Melanoma cell line melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Melanoma metastasis metastatic melanoma http://purl.obolibrary.org/obo/MONDO_0005191 disease http://www.ebi.ac.uk/efo/EFO_0000408 +melanoma patient melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 men male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 meningioma meningioma http://purl.obolibrary.org/obo/MONDO_0016642 disease http://www.ebi.ac.uk/efo/EFO_0000408 meningioma tumor meningioma http://purl.obolibrary.org/obo/MONDO_0016642 disease http://www.ebi.ac.uk/efo/EFO_0000408 Merkel cell carcinoma trabecular adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0002822 disease http://www.ebi.ac.uk/efo/EFO_0000408 +mESC embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Mesenchymal Stem Cells mesenchymal stem cell http://purl.obolibrary.org/obo/CL_0000134 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mesenteric Lymph Node (MLN) mesenteric lymph node http://purl.obolibrary.org/obo/UBERON_0002509 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Metastasis metastatic neoplasm http://purl.obolibrary.org/obo/MONDO_0024883 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Metastatic Melanoma metastatic melanoma http://purl.obolibrary.org/obo/MONDO_0005191 disease http://www.ebi.ac.uk/efo/EFO_0000408 Metastatic Melanoma melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Methamphetamine methamphetamine http://purl.obolibrary.org/obo/CHEBI_6809 treatment http://www.ebi.ac.uk/efo/EFO_0000727 microdissected colorectal cancer cells colorectal cancer http://purl.obolibrary.org/obo/MONDO_0005575 disease http://www.ebi.ac.uk/efo/EFO_0000408 +microdissected medial neocortex neocortex http://purl.obolibrary.org/obo/UBERON_0001950 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Microdissected renal tubule segment renal tubule http://purl.obolibrary.org/obo/UBERON_0009773 organism part http://www.ebi.ac.uk/efo/EFO_0000635 microglia microglial cell http://purl.obolibrary.org/obo/CL_0000129 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +microglia cells microglial cell http://purl.obolibrary.org/obo/CL_0000129 cell type http://www.ebi.ac.uk/efo/EFO_0000324 midbrain midbrain http://purl.obolibrary.org/obo/UBERON_0001891 organism part http://www.ebi.ac.uk/efo/EFO_0000635 middle ear middle ear http://purl.obolibrary.org/obo/UBERON_0001756 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +middle temporal gyrus middle temporal gyrus http://purl.obolibrary.org/obo/UBERON_0002771 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +middle_temporal_gyrus middle temporal gyrus http://purl.obolibrary.org/obo/UBERON_0002771 organism part http://www.ebi.ac.uk/efo/EFO_0000635 MKN45 RCB1001 cell http://purl.obolibrary.org/obo/CLO_0050797 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Mock reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Mock infected reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 mock infected control http://www.ebi.ac.uk/efo/EFO_0001461 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +mock injected reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 moderate-to-severe psoriasis psoriasis http://purl.obolibrary.org/obo/MONDO_0005083 disease http://www.ebi.ac.uk/efo/EFO_0000408 molecule subtype: total RNA total RNA http://www.ebi.ac.uk/efo/EFO_0004964 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 -monocyte monocyte http://purl.obolibrary.org/obo/CL_0000576 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Monocyte monocyte http://purl.obolibrary.org/obo/CL_0000576 cell type http://www.ebi.ac.uk/efo/EFO_0000324 monocyte-derived dendritic cells dendritic cell http://purl.obolibrary.org/obo/CL_0000451 cell type http://www.ebi.ac.uk/efo/EFO_0000324 monocyte-derived macrophage macrophage http://purl.obolibrary.org/obo/CL_0000235 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Monocyte-derived macrophages macrophage http://purl.obolibrary.org/obo/CL_0000235 cell type http://www.ebi.ac.uk/efo/EFO_0000324 monocytes monocyte http://purl.obolibrary.org/obo/CL_0000576 cell type http://www.ebi.ac.uk/efo/EFO_0000324 mononuclear cells from bone marrow mononuclear cell of bone marrow http://purl.obolibrary.org/obo/CL_0010004 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Motor Cortex primary motor cortex http://purl.obolibrary.org/obo/UBERON_0001384 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +motor neuron motor neuron http://purl.obolibrary.org/obo/CL_0000100 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Motor neurons motor neuron http://purl.obolibrary.org/obo/CL_0000100 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mouse brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mouse Brain Tissue brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mouse cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mouse embryonic fibroblast embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mouse embryonic fibroblasts embryonic fibroblast http://purl.obolibrary.org/obo/CL_2000042 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mouse embryonic stem cells embryonic stem cell http://purl.obolibrary.org/obo/CL_0002322 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +mouse fibroblasts fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mouse frontal cortex frontal cortex http://purl.obolibrary.org/obo/UBERON_0001870 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mouse heart heart http://purl.obolibrary.org/obo/UBERON_0000948 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mouse Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mouse Hypothalamus hypothalamus http://purl.obolibrary.org/obo/UBERON_0001898 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mouse Liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mouse lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mouse mammary tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +mouse model primary retinoblastoma tumor retinoblastoma http://purl.obolibrary.org/obo/MONDO_0008380 disease http://www.ebi.ac.uk/efo/EFO_0000408 +mouse prefrontal cortex prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mouse skin fibroblast skin fibroblast http://purl.obolibrary.org/obo/CL_0002620 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Mouse striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mPFC prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +MTB-infected tuberculosis http://purl.obolibrary.org/obo/MONDO_0018076 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Mucosa mucosa http://purl.obolibrary.org/obo/UBERON_0000344 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +mucosal mucosa http://purl.obolibrary.org/obo/UBERON_0000344 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Multiple Myeloma multiple myeloma http://www.ebi.ac.uk/efo/EFO_0001378 disease http://www.ebi.ac.uk/efo/EFO_0000408 multiple myeloma plasma cell myeloma http://purl.obolibrary.org/obo/MONDO_0009693 disease http://www.ebi.ac.uk/efo/EFO_0000408 multiple sclerosis multiple sclerosis http://purl.obolibrary.org/obo/MONDO_0005301 disease http://www.ebi.ac.uk/efo/EFO_0000408 +multisystem failure multiple organ dysfunction syndrome http://purl.obolibrary.org/obo/MONDO_0043726 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Murine Lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Murine primary cortical neurons cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Murine spinal cord spinal cord http://purl.obolibrary.org/obo/UBERON_0002240 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Murine tumor cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Mus musculus Cerebellum cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mus musculus Cerebral Cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mus musculus Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mus musculus Spinal Cord spinal cord http://purl.obolibrary.org/obo/UBERON_0002240 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Mus musculus Striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Muscle muscle tissue http://purl.obolibrary.org/obo/UBERON_0002385 organism part http://www.ebi.ac.uk/efo/EFO_0000635 musculus vastus lateralis vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +myelodysplastic syndromes (MDS) myelodysplastic syndrome http://purl.obolibrary.org/obo/MONDO_0018881 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Myeloid myeloid cell http://purl.obolibrary.org/obo/CL_0000763 cell type http://www.ebi.ac.uk/efo/EFO_0000324 myeloid leukemia myeloid leukemia http://purl.obolibrary.org/obo/MONDO_0004643 disease http://www.ebi.ac.uk/efo/EFO_0000408 +myeloma plasma cell myeloma http://purl.obolibrary.org/obo/MONDO_0009693 disease http://www.ebi.ac.uk/efo/EFO_0000408 Myeloma myeloid neoplasm http://purl.obolibrary.org/obo/MONDO_0005170 disease http://www.ebi.ac.uk/efo/EFO_0000408 -NAFLD liver biopsy tissue liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Myeloproliferative Disorder (MPD) myelodysplastic/myeloproliferative disease http://purl.obolibrary.org/obo/MONDO_0020077 disease http://www.ebi.ac.uk/efo/EFO_0000408 +myometrium myometrium http://purl.obolibrary.org/obo/UBERON_0001296 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +NAC core of nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0012170 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +nAcc nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0001882 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +NaCl sodium chloride http://purl.obolibrary.org/obo/CHEBI_26710 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Naive reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 naive reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 naïve reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +naïve CD4+ Tcells naive thymus-derived CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000895 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Nasal airway epithelium nasal cavity epithelium http://purl.obolibrary.org/obo/UBERON_0005384 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Nasal epithelial cells nasal cavity epithelium http://purl.obolibrary.org/obo/UBERON_0005384 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Nasal Epithelium epithelium of nasopharynx http://purl.obolibrary.org/obo/UBERON_0001951 organism part http://www.ebi.ac.uk/efo/EFO_0000635 NB4 human APL cell line NB-4 cell http://purl.obolibrary.org/obo/CLO_0007947 cell line http://purl.obolibrary.org/obo/CLO_0000031 +negative control reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Negative Control siRNA wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 neocortex neocortex http://purl.obolibrary.org/obo/UBERON_0001950 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +neonatal neonate stage http://purl.obolibrary.org/obo/UBERON_0007221 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 neonatal neonate http://www.ebi.ac.uk/efo/EFO_0001372 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 -neonatal foreskin prepuce of penis http://purl.obolibrary.org/obo/UBERON_0001332 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +neonate neonate stage http://purl.obolibrary.org/obo/UBERON_0007221 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 neonate neonate http://www.ebi.ac.uk/efo/EFO_0001372 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +Nerve nerve http://purl.obolibrary.org/obo/UBERON_0001021 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Neural Progenitor Cells neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Neural Progenitor Cells neuroblast (sensu Vertebrata) http://purl.obolibrary.org/obo/CL_0000031 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neural progenitor cells (NPCs) neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neural retina retinal neural layer http://purl.obolibrary.org/obo/UBERON_0003902 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +neural stem cell neural stem cell http://purl.obolibrary.org/obo/CL_0000047 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Neural stem cells neural stem cell http://purl.obolibrary.org/obo/CL_0000047 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neural tube neural tube http://purl.obolibrary.org/obo/UBERON_0001049 organism part http://www.ebi.ac.uk/efo/EFO_0000635 neuroblastoma neuroblastoma http://purl.obolibrary.org/obo/MONDO_0005072 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Neuroblastoma cell line neuroblastoma cell line http://www.ebi.ac.uk/efo/EFO_0005214 cell line http://purl.obolibrary.org/obo/CLO_0000031 +neuroblastoma cells neuroblastoma http://purl.obolibrary.org/obo/MONDO_0005072 disease http://www.ebi.ac.uk/efo/EFO_0000408 +neuroblastoma tumor neuroblastoma http://purl.obolibrary.org/obo/MONDO_0005072 disease http://www.ebi.ac.uk/efo/EFO_0000408 Neuroblastoma tumor obtained at diagnosis neuroblastoma http://purl.obolibrary.org/obo/MONDO_0005072 disease http://www.ebi.ac.uk/efo/EFO_0000408 +neurologically and neuropathologically normal reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 Neuron neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neuronal neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Neuronal Progenitor cells neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neurons neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 neuropathologically normal frozen temporal cortex temporal cortex http://purl.obolibrary.org/obo/UBERON_0016538 organism part http://www.ebi.ac.uk/efo/EFO_0000635 neutrophil neutrophil http://purl.obolibrary.org/obo/CL_0000775 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +neutrophils neutrophil http://purl.obolibrary.org/obo/CL_0000775 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Never-smoker lung adenocarcinoma patient lung adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005061 disease http://www.ebi.ac.uk/efo/EFO_0000408 +newly diagnosed multiple myeloma multiple myeloma http://www.ebi.ac.uk/efo/EFO_0001378 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Nicotine nicotine http://purl.obolibrary.org/obo/CHEBI_18723 treatment http://www.ebi.ac.uk/efo/EFO_0000727 NIH 3T3 NIH-3T3 cell http://purl.obolibrary.org/obo/CLO_0008172 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +NIH3T3 NIH3T3 http://www.ebi.ac.uk/efo/EFO_0001222 cell line http://purl.obolibrary.org/obo/CLO_0000031 NK cells natural killer cell http://purl.obolibrary.org/obo/CL_0000623 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +no injection reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +no treatment reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +non-cachectic melanoma cells melanoma http://purl.obolibrary.org/obo/MONDO_0005105 disease http://www.ebi.ac.uk/efo/EFO_0000408 +non-infected reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 non-metastatic prostate cancer prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 non-small cell lung cancer non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +non-small cell lung cancer cell line non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Non-Small-Cell Lung Cancer non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +none (control) reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +none (untreated control) reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 normal reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +normal airway epithelial cells respiratory epithelial cell http://purl.obolibrary.org/obo/CL_0002368 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +normal breast breast http://purl.obolibrary.org/obo/UBERON_0000310 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +normal chow reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 +normal colon colon http://purl.obolibrary.org/obo/UBERON_0001155 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +normal colon mucosa colonic mucosa http://purl.obolibrary.org/obo/UBERON_0000317 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +normal control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +normal liver tissue liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +normal lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Normal Lung Tissue lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +normal prostate prostate gland http://purl.obolibrary.org/obo/UBERON_0002367 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Normal Skin skin of body http://purl.obolibrary.org/obo/UBERON_0002097 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Normal tissue reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +NPC neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +NPCs neural progenitor cell http://purl.obolibrary.org/obo/CL_0011020 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +NSC neural stem cell http://purl.obolibrary.org/obo/CL_0000047 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +NSCLC non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +NSCLC cell line non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +NSCLC patient non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 +nucleus accumben nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0001882 organism part http://www.ebi.ac.uk/efo/EFO_0000635 nucleus accumbens nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0001882 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Nucleus accumbens (brain) nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0001882 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +nucleus accumbens (NAc) nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0001882 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Nucleus accumbens core core of nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0012170 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Nucleus Accumbens Shell shell of nucleus accumbens http://purl.obolibrary.org/obo/UBERON_0012171 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Nucleus of the solitary tract nucleus of solitary tract http://purl.obolibrary.org/obo/UBERON_0009050 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Nulliparous nulliparous http://purl.obolibrary.org/obo/PATO_0002368 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +obese obesity http://www.ebi.ac.uk/efo/EFO_0001073 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 occipital cortex occipital cortex http://purl.obolibrary.org/obo/UBERON_0016540 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +occipital lobe occipital lobe http://purl.obolibrary.org/obo/UBERON_0002021 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Occipital Visual Cortex visual cortex http://purl.obolibrary.org/obo/UBERON_0000411 organism part http://www.ebi.ac.uk/efo/EFO_0000635 ocular AMD age-related macular degeneration http://purl.obolibrary.org/obo/MONDO_0005150 disease http://www.ebi.ac.uk/efo/EFO_0000408 +OFC orbitofrontal cortex http://purl.obolibrary.org/obo/UBERON_0004167 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +old old http://purl.obolibrary.org/obo/PATO_0000308 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 olfactory bulb olfactory bulb http://purl.obolibrary.org/obo/UBERON_0002264 organism part http://www.ebi.ac.uk/efo/EFO_0000635 olfactory epithelium olfactory epithelium http://purl.obolibrary.org/obo/UBERON_0001997 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Olfactory mucosa olfactory segment of nasal mucosa http://purl.obolibrary.org/obo/UBERON_0005386 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Oligodendrocyte oligodendrocyte http://purl.obolibrary.org/obo/CL_0000128 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +oligodendrocyte precursor cells oligodendrocyte precursor cell http://purl.obolibrary.org/obo/CL_0002453 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Oligodendroglioma oligodendroglioma http://purl.obolibrary.org/obo/MONDO_0016695 disease http://www.ebi.ac.uk/efo/EFO_0000408 omental adipose adipocyte of omentum tissue http://purl.obolibrary.org/obo/CL_0002615 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Omentum omentum http://purl.obolibrary.org/obo/UBERON_0003688 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +optic nerve head optic disc http://purl.obolibrary.org/obo/UBERON_0001783 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +oral tissue mouth http://purl.obolibrary.org/obo/UBERON_0000165 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Orbitofrontal Cortex orbitofrontal cortex http://purl.obolibrary.org/obo/UBERON_0004167 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +osteoblast osteoblast http://purl.obolibrary.org/obo/CL_0000062 cell type http://www.ebi.ac.uk/efo/EFO_0000324 osteoblast immortal osteoblast cell line cell http://purl.obolibrary.org/obo/CLO_0000055 cell line http://purl.obolibrary.org/obo/CLO_0000031 osteoblasts osteoblast http://purl.obolibrary.org/obo/CL_0000062 cell type http://www.ebi.ac.uk/efo/EFO_0000324 osteosarcoma osteosarcoma http://purl.obolibrary.org/obo/MONDO_0009807 disease http://www.ebi.ac.uk/efo/EFO_0000408 osteosarcoma cells osteosarcoma http://purl.obolibrary.org/obo/MONDO_0009807 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ovarian ovary http://purl.obolibrary.org/obo/UBERON_0000992 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ovarian cancer ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 +ovarian cancer cells ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 ovarian carcinoma tumor ovarian carcinoma http://purl.obolibrary.org/obo/MONDO_0005140 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Ovarian tumor ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 ovarian tumors ovarian cancer http://purl.obolibrary.org/obo/MONDO_0008170 disease http://www.ebi.ac.uk/efo/EFO_0000408 ovary ovary http://purl.obolibrary.org/obo/UBERON_0000992 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +OxPAPC 1-palmitoyl-2-arachidonoyl-sn-glycero-3-phosphocholine http://purl.obolibrary.org/obo/CHEBI_73003 treatment http://www.ebi.ac.uk/efo/EFO_0000727 Paclitaxel paclitaxel http://purl.obolibrary.org/obo/CHEBI_45863 treatment http://www.ebi.ac.uk/efo/EFO_0000727 -pancreas pancreas http://purl.obolibrary.org/obo/UBERON_0001264 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Pancreas pancreas http://purl.obolibrary.org/obo/UBERON_0001264 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Pancreas Tissue pancreas http://purl.obolibrary.org/obo/UBERON_0001264 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +pancreatic ductal adenocarcinoma pancreatic ductal adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005184 disease http://www.ebi.ac.uk/efo/EFO_0000408 pancreatic islets islet of Langerhans http://purl.obolibrary.org/obo/UBERON_0000006 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Pancreatic Tumor malignant pancreatic neoplasm http://purl.obolibrary.org/obo/MONDO_0009831 disease http://www.ebi.ac.uk/efo/EFO_0000408 +papillary serous ovarian adenocarcinoma ovarian serous surface papillary adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0003874 disease http://www.ebi.ac.uk/efo/EFO_0000408 papillary serous ovarian adenocarcinoma ovarian serous adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005211 disease http://www.ebi.ac.uk/efo/EFO_0000408 Papillary Thyroid Carcinoma thyroid gland papillary carcinoma http://purl.obolibrary.org/obo/MONDO_0005075 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Parahippocampal Gyrus parahippocampal gyrus http://purl.obolibrary.org/obo/UBERON_0002973 organism part http://www.ebi.ac.uk/efo/EFO_0000635 paraventricular hypothalamus paraventricular nucleus of hypothalamus http://purl.obolibrary.org/obo/UBERON_0001930 organism part http://www.ebi.ac.uk/efo/EFO_0000635 parietal cortex parietal cortex http://purl.obolibrary.org/obo/UBERON_0016530 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Parkinson's Disease Parkinson disease http://purl.obolibrary.org/obo/MONDO_0005180 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Parkinson's disease Parkinson disease http://purl.obolibrary.org/obo/MONDO_0005180 disease http://www.ebi.ac.uk/efo/EFO_0000408 +parvalbumin (PV) neurons pvalb GABAergic cortical interneuron http://purl.obolibrary.org/obo/CL_4023018 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Patient Primary Pancreatic Tumor malignant pancreatic neoplasm http://purl.obolibrary.org/obo/MONDO_0009831 disease http://www.ebi.ac.uk/efo/EFO_0000408 Patient-matched nontumor control reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 PBMC peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 PBMCs peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 PBMCs from peripheral blood peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +PBS phosphate buffered saline solution http://purl.obolibrary.org/obo/OBI_0100046 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +pcr polymerase chain reaction http://purl.obolibrary.org/obo/OBI_0000415 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 PDAC pancreatic ductal adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005184 disease http://www.ebi.ac.uk/efo/EFO_0000408 +pediatric acute leukemia childhood acute myeloid leukemia http://purl.obolibrary.org/obo/MONDO_0004996 disease http://www.ebi.ac.uk/efo/EFO_0000408 pediatric acute leukemia childhood acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0000870 disease http://www.ebi.ac.uk/efo/EFO_0000408 +pediatric acute lymphoblastic leukemia childhood acute myeloid leukemia http://purl.obolibrary.org/obo/MONDO_0004996 disease http://www.ebi.ac.uk/efo/EFO_0000408 pediatric acute lymphoblastic leukemia childhood acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0000870 disease http://www.ebi.ac.uk/efo/EFO_0000408 +pediatric T-ALL childhood acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0000870 disease http://www.ebi.ac.uk/efo/EFO_0000408 +pediatric T-ALL cells childhood acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0000870 disease http://www.ebi.ac.uk/efo/EFO_0000408 pediatric T-ALL cells T-cell childhood acute lymphocytic leukemia http://purl.obolibrary.org/obo/MONDO_0000871 disease http://www.ebi.ac.uk/efo/EFO_0000408 Periferal blood mononuclear cells peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 peripheral blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 peripheral blood cell blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Peripheral Blood cells blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 peripheral blood leucocyte leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 peripheral blood leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Peripheral blood lymphocytes lymphocyte http://purl.obolibrary.org/obo/CL_0000542 cell type http://www.ebi.ac.uk/efo/EFO_0000324 peripheral blood monocytes monocyte http://purl.obolibrary.org/obo/CL_0000576 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Peripheral blood mononuclear peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Peripheral Blood Mononuclear Cell (PBMC) peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Peripheral blood mononuclear cells peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Peripheral Blood Mononuclear Cells (PBMC) peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 peripheral blood mononuclear cells (PBMCs) peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Peripheral blood sample blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 peripheral lymphocytes lymphocyte http://purl.obolibrary.org/obo/CL_0000542 cell type http://www.ebi.ac.uk/efo/EFO_0000324 -peripheral whole blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +peripheral T-cell lymphoma (PTCL) peripheral T-cell lymphoma, not otherwise specified http://purl.obolibrary.org/obo/MONDO_0004964 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Peripheral T-Cell Lymphoma-Not Otherwise Specified peripheral T-cell lymphoma, not otherwise specified http://purl.obolibrary.org/obo/MONDO_0004964 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Peripheral whole blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +PFC prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 pheochromocytoma adrenal gland pheochromocytoma http://purl.obolibrary.org/obo/MONDO_0004974 disease http://www.ebi.ac.uk/efo/EFO_0000408 Pilocytic astrocytoma pilocytic astrocytoma http://purl.obolibrary.org/obo/MONDO_0016691 disease http://www.ebi.ac.uk/efo/EFO_0000408 pineal gland pineal body http://purl.obolibrary.org/obo/UBERON_0001905 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Piriform Cortex piriform cortex http://purl.obolibrary.org/obo/UBERON_0004725 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Pituitary pituitary gland http://purl.obolibrary.org/obo/UBERON_0000007 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +pituitary adenoma pituitary gland adenoma http://purl.obolibrary.org/obo/MONDO_0006373 disease http://www.ebi.ac.uk/efo/EFO_0000408 +pituitary gland pituitary gland http://purl.obolibrary.org/obo/UBERON_0000007 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +placebo reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 placenta placenta http://purl.obolibrary.org/obo/UBERON_0001987 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +placental tissue placenta http://purl.obolibrary.org/obo/UBERON_0001987 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +plasma blood plasma http://purl.obolibrary.org/obo/UBERON_0001969 organism part http://www.ebi.ac.uk/efo/EFO_0000635 pluripotent stem cell pluripotent stem cell http://purl.obolibrary.org/obo/CL_0002248 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +pluripotent stem cells pluripotent stem cell http://purl.obolibrary.org/obo/CL_0002248 cell type http://www.ebi.ac.uk/efo/EFO_0000324 PMBCs peripheral blood mononuclear cell http://purl.obolibrary.org/obo/CL_2000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 polymorphnuclear leukocytes granulocyte http://purl.obolibrary.org/obo/CL_0000094 cell type http://www.ebi.ac.uk/efo/EFO_0000324 polymorphonuclear leukocytes granulocyte http://purl.obolibrary.org/obo/CL_0000094 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Pons pons http://purl.obolibrary.org/obo/UBERON_0000988 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Post-menopausal postmenopausal http://www.ebi.ac.uk/efo/EFO_0002721 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +post-mortem brain tissue brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +post-mortem cerebellum (white matter) white matter of cerebellum http://purl.obolibrary.org/obo/UBERON_0002317 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +post-mortem tissue post mortem specimen http://purl.obolibrary.org/obo/OBI_0000902 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +Posterior Cingulate Cortex posterior cingulate cortex http://purl.obolibrary.org/obo/UBERON_0022353 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +postmenopausal postmenopausal http://www.ebi.ac.uk/efo/EFO_0002721 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 postmortem brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 postpartum postpartum http://www.ebi.ac.uk/efo/EFO_0008562 timepoint http://www.ebi.ac.uk/efo/EFO_0000724 -pre-treatment bone marrow bone marrow http://purl.obolibrary.org/obo/UBERON_0002371 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Pre Frontal Cortex prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Pre-menopausal premenopausal status http://purl.obolibrary.org/obo/OBI_0002412 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +Precursor B-cell acute lymphoblastic leukemia (ALL) precursor B-cell acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0020511 disease http://www.ebi.ac.uk/efo/EFO_0000408 +precursor-B ALL precursor B-cell acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0020511 disease http://www.ebi.ac.uk/efo/EFO_0000408 prefrontal cortex prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +prefrontal cortex (BA46) Brodmann (1909) area 46 http://purl.obolibrary.org/obo/UBERON_0006483 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +prefrontal cortex (BA9) prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Prefrontal cortex (PFC) prefrontal cortex http://purl.obolibrary.org/obo/UBERON_0000451 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Pregnant female pregnancy http://purl.obolibrary.org/obo/GO_0007565 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 +Prelimbic cortex prelimbic area http://purl.obolibrary.org/obo/UBERON_8440032 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +premenopausal premenopausal status http://purl.obolibrary.org/obo/OBI_0002412 developmental stage http://www.ebi.ac.uk/efo/EFO_0000399 prenatal control reference substance role http://purl.obolibrary.org/obo/OBI_0000025 diet http://www.ebi.ac.uk/efo/EFO_0002755 +Primary Acute Lymphoblastic Leukemia Cells acute lymphoblastic leukemia http://purl.obolibrary.org/obo/MONDO_0004967 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary astrocytes astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 primary bladder cancer urinary bladder cancer http://purl.obolibrary.org/obo/MONDO_0001187 disease http://www.ebi.ac.uk/efo/EFO_0000408 Primary brain tumor tissue brain cancer http://purl.obolibrary.org/obo/MONDO_0001657 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary breast cancer breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary breast cancer sample, fresh-frozen breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary breast cancer tissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary breast cancer, ER negative estrogen-receptor negative breast cancer http://purl.obolibrary.org/obo/MONDO_0006513 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary breast cancer, ER positive estrogen-receptor positive breast cancer http://purl.obolibrary.org/obo/MONDO_0006512 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary breast tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary breast tumor - fresh surgical samples breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary cancer cell cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary CD4+ T cells CD4-positive, alpha-beta T cell http://purl.obolibrary.org/obo/CL_0000624 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary cerebella cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Primary Cerebrocortical Cultures cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 primary colon adenocarcinoma colon adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0002271 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary colorectal adenocarcinoma colorectal adenocarcinoma http://purl.obolibrary.org/obo/MONDO_0005008 disease http://www.ebi.ac.uk/efo/EFO_0000408 Primary cortical neurons cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary culture primary cultured cell http://purl.obolibrary.org/obo/CL_0000001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Primary Cutlure Mouse Cortical Neurons cerebral cortex neuron http://purl.obolibrary.org/obo/CL_0010012 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Primary fibroblasts fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Primary gastric cancer gastric cancer http://purl.obolibrary.org/obo/MONDO_0001056 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Primary gastric tumour gastric cancer http://purl.obolibrary.org/obo/MONDO_0001056 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Primary hepatocytes hepatocyte http://purl.obolibrary.org/obo/CL_0000182 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary hippocampal neurons hippocampal neuron http://purl.obolibrary.org/obo/CL_0002608 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Primary human osteoblasts osteoblast http://purl.obolibrary.org/obo/CL_0000062 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary human skeletal myotube cells myotube http://purl.obolibrary.org/obo/CL_0002372 cell type http://www.ebi.ac.uk/efo/EFO_0000324 primary liposarcoma liposarcoma http://purl.obolibrary.org/obo/MONDO_0005060 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary lung cancer lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary lung fibroblast fibroblast of lung http://purl.obolibrary.org/obo/CL_0002553 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Primary lung tumor lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 Primary medulloblastoma medulloblastoma http://purl.obolibrary.org/obo/MONDO_0007959 disease http://www.ebi.ac.uk/efo/EFO_0000408 Primary medulloblastoma tumor tissue medulloblastoma http://purl.obolibrary.org/obo/MONDO_0007959 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary microglia microglial cell http://purl.obolibrary.org/obo/CL_0000129 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary monocyte-derived macrophages macrophage http://purl.obolibrary.org/obo/CL_0000235 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary mouse microglia microglial cell http://purl.obolibrary.org/obo/CL_0000129 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Primary Neuron neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Primary neurons neuron http://purl.obolibrary.org/obo/CL_0000540 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Primary NSCLC non-small cell lung carcinoma http://purl.obolibrary.org/obo/MONDO_0005233 disease http://www.ebi.ac.uk/efo/EFO_0000408 primary prostate cancer prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +primary rat hepatocytes hepatocyte http://purl.obolibrary.org/obo/CL_0000182 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Primary T-cells T cell http://purl.obolibrary.org/obo/CL_0000084 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +primary tumor primary tumor sample http://www.ebi.ac.uk/efo/EFO_0010942 disease http://www.ebi.ac.uk/efo/EFO_0000408 primordial germ cells primordial germ cell http://purl.obolibrary.org/obo/CL_0000670 cell type http://www.ebi.ac.uk/efo/EFO_0000324 -Prostate prostate gland http://purl.obolibrary.org/obo/UBERON_0002367 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +prostaglandin E2 (PGE2) prostaglandin E2 http://purl.obolibrary.org/obo/CHEBI_15551 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +prostate prostate gland http://purl.obolibrary.org/obo/UBERON_0002367 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +prostate cancer prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Prostate cancer cell line prostate cancer cell line http://purl.obolibrary.org/obo/BTO_0001033 cell line http://purl.obolibrary.org/obo/CLO_0000031 Prostate cancer cell line prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +prostate cancer cells prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 Prostate cancer primary tumor prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +prostate cancer sample prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +prostate tumor prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 +prostate tumor/tissue prostate cancer http://purl.obolibrary.org/obo/MONDO_0008315 disease http://www.ebi.ac.uk/efo/EFO_0000408 proximal colon right colon http://purl.obolibrary.org/obo/UBERON_0008972 organism part http://www.ebi.ac.uk/efo/EFO_0000635 psoriasis psoriasis http://purl.obolibrary.org/obo/MONDO_0005083 disease http://www.ebi.ac.uk/efo/EFO_0000408 PTCL mature T-cell and NK-cell non-Hodgkin lymphoma http://purl.obolibrary.org/obo/MONDO_0000430 disease http://www.ebi.ac.uk/efo/EFO_0000408 +PTSD post-traumatic stress disorder http://purl.obolibrary.org/obo/MONDO_0005146 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Pulmonary embolism pulmonary embolism http://purl.obolibrary.org/obo/MONDO_0005279 disease http://www.ebi.ac.uk/efo/EFO_0000408 pulmonary epithelial cells epithelial cell of lung http://purl.obolibrary.org/obo/CL_0000082 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Purkinje Cells Purkinje cell http://purl.obolibrary.org/obo/CL_0000121 cell type http://www.ebi.ac.uk/efo/EFO_0000324 putamen putamen http://purl.obolibrary.org/obo/UBERON_0001874 organism part http://www.ebi.ac.uk/efo/EFO_0000635 pyramidal neuron cell pyramidal neuron http://purl.obolibrary.org/obo/CL_0000598 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Pyramidal neurons pyramidal neuron http://purl.obolibrary.org/obo/CL_0000598 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Quadriceps quadriceps femoris http://purl.obolibrary.org/obo/UBERON_0001377 organism part http://www.ebi.ac.uk/efo/EFO_0000635 quadriceps muscle quadriceps femoris http://purl.obolibrary.org/obo/UBERON_0001377 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +race: Caucasian European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +Rapamycin sirolimus http://purl.obolibrary.org/obo/CHEBI_9168 treatment http://www.ebi.ac.uk/efo/EFO_0000727 rat adipose tissue adipose tissue http://purl.obolibrary.org/obo/UBERON_0001013 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat aortic smooth muscle cells (RASMC) aortic smooth muscle cell http://purl.obolibrary.org/obo/CL_0002539 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Rat gastrocnemius muscle gastrocnemius http://purl.obolibrary.org/obo/UBERON_0001388 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat Hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat Liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Rat Raphe raphe nuclei http://purl.obolibrary.org/obo/UBERON_0004684 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat Skeletal Muscle (gas) gastrocnemius http://purl.obolibrary.org/obo/UBERON_0001388 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Rat Somatomotor Cortex primary motor cortex http://purl.obolibrary.org/obo/UBERON_0001384 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat spinal cord spinal cord http://purl.obolibrary.org/obo/UBERON_0002240 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Rat spinal cord Injury site spinal cord injury http://purl.obolibrary.org/obo/MONDO_0043797 disease http://www.ebi.ac.uk/efo/EFO_0000408 rat whole lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 rectal cancer rectal cancer http://purl.obolibrary.org/obo/MONDO_0006519 disease http://www.ebi.ac.uk/efo/EFO_0000408 Rectum rectum http://purl.obolibrary.org/obo/UBERON_0001052 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -renal biopsy kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +recurrence recurrent http://purl.obolibrary.org/obo/PATO_0000427 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Recurrent recurrent http://purl.obolibrary.org/obo/PATO_0000427 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 +reference reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +reference RNA wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +relapsing remmiting EAE experimental autoimmune encephalomyelitis http://purl.obolibrary.org/obo/MONDO_0005134 disease http://www.ebi.ac.uk/efo/EFO_0000408 +renal kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Renal cell carcinoma renal cell carcinoma http://purl.obolibrary.org/obo/MONDO_0005086 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Renal cortex cortex of kidney http://purl.obolibrary.org/obo/UBERON_0001225 organism part http://www.ebi.ac.uk/efo/EFO_0000635 renal tissue kidney http://purl.obolibrary.org/obo/UBERON_0002113 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Resistant resistant to http://purl.obolibrary.org/obo/PATO_0001178 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 resting monocyes monocyte http://purl.obolibrary.org/obo/CL_0000576 cell type http://www.ebi.ac.uk/efo/EFO_0000324 retina retina http://purl.obolibrary.org/obo/UBERON_0000966 organism part http://www.ebi.ac.uk/efo/EFO_0000635 retinal endothelial cells retinal blood vessel endothelial cell http://purl.obolibrary.org/obo/CL_0002585 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Retinal ganglion cells retinal ganglion cell http://purl.obolibrary.org/obo/CL_0000740 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +retinal organoid retina http://purl.obolibrary.org/obo/UBERON_0000966 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +retinal pigment epithelial cells retinal pigment epithelial cell http://purl.obolibrary.org/obo/CL_0002586 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Retinal Pigment Epithelium pigmented layer of retina http://purl.obolibrary.org/obo/UBERON_0001782 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +retinoblastoma retinoblastoma http://purl.obolibrary.org/obo/MONDO_0008380 disease http://www.ebi.ac.uk/efo/EFO_0000408 retinoic acid retinoic acid http://purl.obolibrary.org/obo/CHEBI_26536 treatment http://www.ebi.ac.uk/efo/EFO_0000727 rheumatoid arthritis rheumatoid arthritis http://purl.obolibrary.org/obo/MONDO_0008383 disease http://www.ebi.ac.uk/efo/EFO_0000408 Rheumatoid arthritis patient rheumatoid arthritis http://purl.obolibrary.org/obo/MONDO_0008383 disease http://www.ebi.ac.uk/efo/EFO_0000408 +right hemisphere right cerebral hemisphere http://purl.obolibrary.org/obo/UBERON_0002813 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Right Striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RNA from blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RNA from brain region tissue brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RNA from fusiform gyrus fusiform gyrus http://purl.obolibrary.org/obo/UBERON_0002766 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RNA from peripheral blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RNA from sorted brain cells brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +RPE pigmented layer of retina http://purl.obolibrary.org/obo/UBERON_0001782 organism part http://www.ebi.ac.uk/efo/EFO_0000635 RPE-choroid and retina pigmented layer of retina http://purl.obolibrary.org/obo/UBERON_0001782 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Sagittal Synostosis synostosis http://purl.obolibrary.org/obo/MONDO_0001411 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Ruptured aortic aneurysm aortic aneurysm http://purl.obolibrary.org/obo/MONDO_0005160 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Sagittal Synostosis craniosynostosis http://purl.obolibrary.org/obo/MONDO_0015469 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Saline saline http://www.ebi.ac.uk/efo/EFO_0002677 treatment http://www.ebi.ac.uk/efo/EFO_0000727 saliva saliva http://purl.obolibrary.org/obo/UBERON_0001836 organism part http://www.ebi.ac.uk/efo/EFO_0000635 salivary gland saliva-secreting gland http://purl.obolibrary.org/obo/UBERON_0001044 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Sarcoidosis sarcoidosis http://purl.obolibrary.org/obo/MONDO_0019338 disease http://www.ebi.ac.uk/efo/EFO_0000408 Sarin sarin http://purl.obolibrary.org/obo/CHEBI_75701 treatment http://www.ebi.ac.uk/efo/EFO_0000727 schizophrenia schizophrenia http://purl.obolibrary.org/obo/MONDO_0005090 disease http://www.ebi.ac.uk/efo/EFO_0000408 schizophrenia (SCZ) schizophrenia http://purl.obolibrary.org/obo/MONDO_0005090 disease http://www.ebi.ac.uk/efo/EFO_0000408 -sciatic nerve sciatic nerve http://purl.obolibrary.org/obo/UBERON_0001322 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -SD Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Schwann cells Schwann cell http://purl.obolibrary.org/obo/CL_0002573 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +SCI spinal cord injury http://purl.obolibrary.org/obo/MONDO_0043797 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Sciatic nerve sciatic nerve http://purl.obolibrary.org/obo/UBERON_0001322 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Senescent senescent http://purl.obolibrary.org/obo/PATO_0001487 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 sentinel lymph node lymph node http://purl.obolibrary.org/obo/UBERON_0000029 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Sepsis septic shock http://www.ebi.ac.uk/efo/EFO_0006834 disease http://www.ebi.ac.uk/efo/EFO_0000408 Sepsis sepsis http://purl.obolibrary.org/obo/MP_0005044 disease http://www.ebi.ac.uk/efo/EFO_0000408 +septic shock patient septic shock http://www.ebi.ac.uk/efo/EFO_0006834 disease http://www.ebi.ac.uk/efo/EFO_0000408 Septum septum http://purl.obolibrary.org/obo/UBERON_0003037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +serotype DENV-1 dengue virus type 1 http://purl.obolibrary.org/obo/NCBITaxon_11053 disease http://www.ebi.ac.uk/efo/EFO_0000408 +serous ovarian cancer ovarian serous tumor http://purl.obolibrary.org/obo/MONDO_0037255 disease http://www.ebi.ac.uk/efo/EFO_0000408 +sex (m male http://purl.obolibrary.org/obo/PATO_0000384 biological sex http://purl.obolibrary.org/obo/PATO_0000047 +SGBS Simpson-Golabi-Behmel syndrome http://purl.obolibrary.org/obo/MONDO_0010731 disease http://www.ebi.ac.uk/efo/EFO_0000408 SH-SY5Y SH-SY5Y cell http://purl.obolibrary.org/obo/CLO_0009015 cell line http://purl.obolibrary.org/obo/CLO_0000031 +sham reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +sham surgery reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +sigmoid colon sigmoid colon http://purl.obolibrary.org/obo/UBERON_0001159 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Sjögrens syndrome Sjogren syndrome http://purl.obolibrary.org/obo/MONDO_0010030 disease http://www.ebi.ac.uk/efo/EFO_0000408 skeletal muscle skeletal muscle tissue http://purl.obolibrary.org/obo/UBERON_0001134 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Skeletal muscle biopsy skeletal muscle tissue http://purl.obolibrary.org/obo/UBERON_0001134 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +skeletal muscle (vastus lateralis) vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 skin skin of body http://purl.obolibrary.org/obo/UBERON_0002097 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Skin punch biopsy skin of body http://purl.obolibrary.org/obo/UBERON_0002097 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +skin fibroblast skin fibroblast http://purl.obolibrary.org/obo/CL_0002620 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +skin fibroblasts skin fibroblast http://purl.obolibrary.org/obo/CL_0002620 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Skin punch biopsy skinpunch biopsy http://purl.obolibrary.org/obo/OBI_0002663 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +skin_tissue skin of body http://purl.obolibrary.org/obo/UBERON_0002097 organism part http://www.ebi.ac.uk/efo/EFO_0000635 skull skull http://purl.obolibrary.org/obo/UBERON_0003129 organism part http://www.ebi.ac.uk/efo/EFO_0000635 SLE systemic lupus erythematosus http://purl.obolibrary.org/obo/MONDO_0007915 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Small intestine small intestine http://purl.obolibrary.org/obo/UBERON_0002108 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Smoker smoking behavior http://www.ebi.ac.uk/efo/EFO_0004318 environmental history http://www.ebi.ac.uk/efo/EFO_0004444 -Snap-frozen microdissected mouse brain region brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +small intestine small intestine http://purl.obolibrary.org/obo/UBERON_0002108 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +smoker smoking behavior http://www.ebi.ac.uk/efo/EFO_0004318 environmental history http://www.ebi.ac.uk/efo/EFO_0004444 +Snap frozen primary breast tumor breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Soft Tissue Sarcoma soft tissue sarcoma http://purl.obolibrary.org/obo/MONDO_0018078 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Soft-tissue sarcoma soft tissue sarcoma http://purl.obolibrary.org/obo/MONDO_0018078 disease http://www.ebi.ac.uk/efo/EFO_0000408 soleus soleus muscle http://purl.obolibrary.org/obo/UBERON_0001389 organism part http://www.ebi.ac.uk/efo/EFO_0000635 soleus muscle soleus muscle http://purl.obolibrary.org/obo/UBERON_0001389 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -source material: study participant, subcutaneous adipose tissue, periumbilical area subcutaneous abdominal adipose tissue http://purl.obolibrary.org/obo/UBERON_0014455 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Somatosensory Cortex somatosensory cortex http://purl.obolibrary.org/obo/UBERON_0008930 organism part http://www.ebi.ac.uk/efo/EFO_0000635 sperm sperm http://purl.obolibrary.org/obo/CL_0000019 cell type http://www.ebi.ac.uk/efo/EFO_0000324 spinal cord spinal cord http://purl.obolibrary.org/obo/UBERON_0002240 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +spinal cord injury spinal cord injury http://purl.obolibrary.org/obo/MONDO_0043797 disease http://www.ebi.ac.uk/efo/EFO_0000408 +spinal cord tissue spinal cord http://purl.obolibrary.org/obo/UBERON_0002240 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Spinal motor neurons spinal cord motor neuron http://purl.obolibrary.org/obo/CL_0011001 cell type http://www.ebi.ac.uk/efo/EFO_0000324 spiny projection neurons pyramidal neuron http://purl.obolibrary.org/obo/CL_0000598 cell type http://www.ebi.ac.uk/efo/EFO_0000324 spleen spleen http://purl.obolibrary.org/obo/UBERON_0002106 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Spleen Cell Cultures spleen http://purl.obolibrary.org/obo/UBERON_0002106 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -sprague dawley Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Splenic B cells B cell http://purl.obolibrary.org/obo/CL_0000236 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Sprague Dawley Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 +sprague dawley rat Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Sprague Dawley rats Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 Sprague-Dawley Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 Sprague-Dawley (SD) Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 Sprague-Dawley rat Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain http://www.ebi.ac.uk/efo/EFO_0005135 @@ -587,81 +1239,145 @@ Sprague-Dawley rats Sprague Dawley http://www.ebi.ac.uk/efo/EFO_0001352 strain h sputum sputum http://purl.obolibrary.org/obo/UBERON_0007311 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Squamous cell carcinoma squamous cell carcinoma http://purl.obolibrary.org/obo/MONDO_0005096 disease http://www.ebi.ac.uk/efo/EFO_0000408 sscortex secondary somatosensory cortex http://purl.obolibrary.org/obo/UBERON_0008934 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +steatosis steatosis http://www.ebi.ac.uk/efo/EFO_0008527 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 stem cells stem cell http://purl.obolibrary.org/obo/CL_0000034 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +stomach stomach http://purl.obolibrary.org/obo/UBERON_0000945 organism part http://www.ebi.ac.uk/efo/EFO_0000635 stress environmental stress treatment http://www.ebi.ac.uk/efo/EFO_0000470 environmental history http://www.ebi.ac.uk/efo/EFO_0004444 +striatal astrocytes astrocyte http://purl.obolibrary.org/obo/CL_0000127 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +striatal tissue striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +striated muscle striated muscle tissue http://purl.obolibrary.org/obo/UBERON_0002036 organism part http://www.ebi.ac.uk/efo/EFO_0000635 striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -stroke stroke disorder http://purl.obolibrary.org/obo/MONDO_0005098 disease http://www.ebi.ac.uk/efo/EFO_0000408 -subcortical white matter white matter http://purl.obolibrary.org/obo/UBERON_0002316 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -subcutaneous adipose subcutaneous adipose tissue http://purl.obolibrary.org/obo/UBERON_0002190 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +striatum (brain) striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Stroke stroke disorder http://purl.obolibrary.org/obo/MONDO_0005098 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Subcutaneous adipose subcutaneous adipose tissue http://purl.obolibrary.org/obo/UBERON_0002190 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Subcutaneous adipose tissue subcutaneous adipose tissue http://purl.obolibrary.org/obo/UBERON_0002190 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Subcutaneous Fat subcutaneous adipose tissue http://purl.obolibrary.org/obo/UBERON_0002190 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Substantia nigra substantia nigra http://purl.obolibrary.org/obo/UBERON_0002038 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Subcutaneous White Adipose Tissue white adipose tissue http://purl.obolibrary.org/obo/UBERON_0001347 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +substantia nigra substantia nigra http://purl.obolibrary.org/obo/UBERON_0002038 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +substantia nigra pars compacta substantia nigra pars compacta http://purl.obolibrary.org/obo/UBERON_0001965 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +subventricular zone postnatal subventricular zone http://purl.obolibrary.org/obo/UBERON_0004922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Suicide suicide http://www.ebi.ac.uk/efo/EFO_0007624 disease http://www.ebi.ac.uk/efo/EFO_0000408 superior cervical ganglia (SCG) superior cervical ganglion http://purl.obolibrary.org/obo/UBERON_0001989 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +superior colliculus superior colliculus http://purl.obolibrary.org/obo/UBERON_0001945 organism part http://www.ebi.ac.uk/efo/EFO_0000635 superior frontal gyrus superior frontal gyrus http://purl.obolibrary.org/obo/UBERON_0002661 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -suprachiasmatic nucleus suprachiasmatic nucleus http://purl.obolibrary.org/obo/UBERON_0002034 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Superior Parietal Lobule superior parietal cortex http://purl.obolibrary.org/obo/UBERON_0006094 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Superior Temporal Gyrus superior temporal gyrus http://purl.obolibrary.org/obo/UBERON_0002769 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Suprachiasmatic Nucleus suprachiasmatic nucleus http://purl.obolibrary.org/obo/UBERON_0002034 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +sural nerve sural nerve http://purl.obolibrary.org/obo/UBERON_0015488 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Susceptible susceptible toward http://purl.obolibrary.org/obo/PATO_0001152 phenotype http://www.ebi.ac.uk/efo/EFO_0000651 SW620 SW620 cell http://purl.obolibrary.org/obo/CLO_0009221 cell line http://purl.obolibrary.org/obo/CLO_0000031 -Swiss CFW http://www.ebi.ac.uk/efo/EFO_0022472 strain http://www.ebi.ac.uk/efo/EFO_0005135 Swiss Webster CFW http://www.ebi.ac.uk/efo/EFO_0022472 strain http://www.ebi.ac.uk/efo/EFO_0005135 -Synovial fibroblasts culture fibroblast http://purl.obolibrary.org/obo/CL_0000057 cell type http://www.ebi.ac.uk/efo/EFO_0000324 synovial membrane synovial membrane of synovial joint http://purl.obolibrary.org/obo/UBERON_0002018 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Synovial sarcoma tumor tissue synovial sarcoma http://purl.obolibrary.org/obo/MONDO_0010434 disease http://www.ebi.ac.uk/efo/EFO_0000408 -systolic heart failure due to ischemic cardiomyopathy systolic heart failure http://purl.obolibrary.org/obo/MONDO_0006993 disease http://www.ebi.ac.uk/efo/EFO_0000408 +T cell T cell http://purl.obolibrary.org/obo/CL_0000084 cell type http://www.ebi.ac.uk/efo/EFO_0000324 T cells T cell http://purl.obolibrary.org/obo/CL_0000084 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +T-ALL T-cell adult acute lymphocytic leukemia http://purl.obolibrary.org/obo/MONDO_0003539 disease http://www.ebi.ac.uk/efo/EFO_0000408 T-ALL diagnostic sample acute T cell leukemia http://purl.obolibrary.org/obo/MONDO_0003540 disease http://www.ebi.ac.uk/efo/EFO_0000408 +T-cell lymphoblasts T cell http://purl.obolibrary.org/obo/CL_0000084 cell type http://www.ebi.ac.uk/efo/EFO_0000324 T47D T-47D cell http://purl.obolibrary.org/obo/CLO_0009251 cell line http://purl.obolibrary.org/obo/CLO_0000031 tamoxifen tamoxifen http://purl.obolibrary.org/obo/CHEBI_41774 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Taxol paclitaxel http://purl.obolibrary.org/obo/CHEBI_45863 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +TC2 Tc2 cell http://purl.obolibrary.org/obo/CL_0000918 cell type http://www.ebi.ac.uk/efo/EFO_0000324 temporal cortex temporal cortex http://purl.obolibrary.org/obo/UBERON_0016538 organism part http://www.ebi.ac.uk/efo/EFO_0000635 temporal lobe temporal lobe http://purl.obolibrary.org/obo/UBERON_0001871 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Temporal Pole temporal pole http://purl.obolibrary.org/obo/UBERON_0002576 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Temporal_Cortex temporal cortex http://purl.obolibrary.org/obo/UBERON_0016538 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +term placenta placenta http://purl.obolibrary.org/obo/UBERON_0001987 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +terminal ileum terminal ileum http://www.ebi.ac.uk/efo/EFO_0005185 organism part http://www.ebi.ac.uk/efo/EFO_0000635 testes testis http://purl.obolibrary.org/obo/UBERON_0000473 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Testis testis http://purl.obolibrary.org/obo/UBERON_0000473 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -Thalamus dorsal plus ventral thalamus http://purl.obolibrary.org/obo/UBERON_0001897 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +testis testis http://purl.obolibrary.org/obo/UBERON_0000473 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +thalamic projection neurons thalamic excitatory neuron http://purl.obolibrary.org/obo/CL_4023068 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +thalamus dorsal plus ventral thalamus http://purl.obolibrary.org/obo/UBERON_0001897 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Thigh muscle hindlimb stylopod muscle http://purl.obolibrary.org/obo/UBERON_0004252 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Thoracic spinal cord thoracic spinal cord http://purl.obolibrary.org/obo/UBERON_0003038 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +THP-1 THP-1 cell http://purl.obolibrary.org/obo/CLO_0009348 cell line http://purl.obolibrary.org/obo/CLO_0000031 +THP-1 Cells THP-1 cell http://purl.obolibrary.org/obo/CLO_0009348 cell line http://purl.obolibrary.org/obo/CLO_0000031 thymus thymus http://purl.obolibrary.org/obo/UBERON_0002370 organism part http://www.ebi.ac.uk/efo/EFO_0000635 thyroid thyroid gland http://purl.obolibrary.org/obo/UBERON_0002046 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +tibialis anterior tibialis anterior http://purl.obolibrary.org/obo/UBERON_0001385 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Tibialis anterior muscle tibialis anterior http://purl.obolibrary.org/obo/UBERON_0001385 organism part http://www.ebi.ac.uk/efo/EFO_0000635 TK6 TK6 cell http://purl.obolibrary.org/obo/CLO_0009357 cell line http://purl.obolibrary.org/obo/CLO_0000031 +Tongue tongue http://purl.obolibrary.org/obo/UBERON_0001723 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Toscani in Italia European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 total RNA total RNA http://www.ebi.ac.uk/efo/EFO_0004964 collection of material http://www.ebi.ac.uk/efo/EFO_0005066 +Total RNA from peripheral blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Total RNA from peripheral blood RNA. blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Total Superior Cervical Ganglia cervical ganglion http://purl.obolibrary.org/obo/UBERON_0001991 organism part http://www.ebi.ac.uk/efo/EFO_0000635 trabecular bone trabecular bone tissue http://purl.obolibrary.org/obo/UBERON_0002483 organism part http://www.ebi.ac.uk/efo/EFO_0000635 trachea trachea http://purl.obolibrary.org/obo/UBERON_0003126 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +trigeminal ganglia trigeminal ganglion http://purl.obolibrary.org/obo/UBERON_0001675 organism part http://www.ebi.ac.uk/efo/EFO_0000635 triple-negative breast cancer triple-negative breast carcinoma http://purl.obolibrary.org/obo/MONDO_0005494 disease http://www.ebi.ac.uk/efo/EFO_0000408 -Tuberculosis tuberculosis http://purl.obolibrary.org/obo/MONDO_0018076 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Trunk wall body wall http://purl.obolibrary.org/obo/UBERON_0000309 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +tuberculosis tuberculosis http://purl.obolibrary.org/obo/MONDO_0018076 disease http://www.ebi.ac.uk/efo/EFO_0000408 +tumor cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 +tumor breast tissue breast cancer http://purl.obolibrary.org/obo/MONDO_0007254 disease http://www.ebi.ac.uk/efo/EFO_0000408 +tumor tissue cancer http://purl.obolibrary.org/obo/MONDO_0004992 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Tumor tissue derived from lung lung cancer http://purl.obolibrary.org/obo/MONDO_0008903 disease http://www.ebi.ac.uk/efo/EFO_0000408 +Type 1 Diabetes type 1 diabetes mellitus http://purl.obolibrary.org/obo/MONDO_0005147 disease http://www.ebi.ac.uk/efo/EFO_0000408 U2OS U-2 OS cell http://purl.obolibrary.org/obo/CLO_0009454 cell line http://purl.obolibrary.org/obo/CLO_0000031 +U87 U-87 MG cell http://purl.obolibrary.org/obo/CLO_0009464 cell line http://purl.obolibrary.org/obo/CLO_0000031 +U87MG U-87 MG cell http://purl.obolibrary.org/obo/CLO_0009464 cell line http://purl.obolibrary.org/obo/CLO_0000031 U937 U937(CD59+) cell http://purl.obolibrary.org/obo/CLO_0009466 cell line http://purl.obolibrary.org/obo/CLO_0000031 umbilical cord blood umbilical cord blood http://purl.obolibrary.org/obo/UBERON_0012168 organism part http://www.ebi.ac.uk/efo/EFO_0000635 unaffected reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 Unaffected Comparison subject reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 uncomplicated dengue dengue disease http://purl.obolibrary.org/obo/MONDO_0005502 disease http://www.ebi.ac.uk/efo/EFO_0000408 undifferentiated hiPS induced pluripotent stem cell http://www.ebi.ac.uk/efo/EFO_0004905 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Undifferentiated sarcoma sarcoma http://purl.obolibrary.org/obo/MONDO_0005089 disease http://www.ebi.ac.uk/efo/EFO_0000408 +uninfected reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +uninjured reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 +unstimulated reference subject role http://purl.obolibrary.org/obo/OBI_0000220 treatment http://www.ebi.ac.uk/efo/EFO_0000727 unstimulated reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +untreated reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 uremia uremia http://purl.obolibrary.org/obo/MONDO_0007008 disease http://www.ebi.ac.uk/efo/EFO_0000408 urinary bladder urinary bladder http://purl.obolibrary.org/obo/UBERON_0001255 organism part http://www.ebi.ac.uk/efo/EFO_0000635 uterus uterus http://purl.obolibrary.org/obo/UBERON_0000995 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -vastus lateralis vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Vaccinee passive immunization http://purl.obolibrary.org/obo/OBI_0001174 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Vagal sensory ganglia superior vagus X ganglion http://purl.obolibrary.org/obo/UBERON_0005364 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +vaginal vagina http://purl.obolibrary.org/obo/UBERON_0000996 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Vastus Lateralis vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 vastus lateralis (quadriceps femoris) vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -vastus lateralis muscle vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -vehicle control control http://www.ebi.ac.uk/efo/EFO_0001461 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Vastus lateralis muscle vastus lateralis http://purl.obolibrary.org/obo/UBERON_0001379 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Veh reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +vehicle reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +vehicle control reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +vehicle(EtOH) reference substance role http://purl.obolibrary.org/obo/OBI_0000025 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Ventral dentate gyrus dentate gyrus of hippocampal formation http://purl.obolibrary.org/obo/UBERON_0001885 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ventral hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 ventral midbrain midbrain http://purl.obolibrary.org/obo/UBERON_0001891 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Ventral Striatum ventral striatum http://purl.obolibrary.org/obo/UBERON_0005403 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +ventral tegmental area ventral tegmental area http://purl.obolibrary.org/obo/UBERON_0002691 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Ventricles cardiac ventricle http://purl.obolibrary.org/obo/UBERON_0002082 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +vHC Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 VHL Clear Cell Renal Cell Carcinoma clear cell renal carcinoma http://purl.obolibrary.org/obo/MONDO_0005005 disease http://www.ebi.ac.uk/efo/EFO_0000408 visceral adipose tissue visceral abdominal adipose tissue http://purl.obolibrary.org/obo/UBERON_0014454 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +visceral fat visceral fat http://purl.obolibrary.org/obo/UBERON_0035818 organism part http://www.ebi.ac.uk/efo/EFO_0000635 visual cortex visual cortex http://purl.obolibrary.org/obo/UBERON_0000411 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -w European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +Water water http://purl.obolibrary.org/obo/CHEBI_15377 treatment http://www.ebi.ac.uk/efo/EFO_0000727 WBC leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Western European European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 White European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 +white adipose white adipose tissue http://purl.obolibrary.org/obo/UBERON_0001347 organism part http://www.ebi.ac.uk/efo/EFO_0000635 White Adipose Tissue white adipose tissue http://purl.obolibrary.org/obo/UBERON_0001347 organism part http://www.ebi.ac.uk/efo/EFO_0000635 white blood cells leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +White Europeans from North-Eastern Germany European http://purl.obolibrary.org/obo/HANCESTRO_0005 population http://purl.obolibrary.org/obo/OBI_0000181 white matter white matter http://purl.obolibrary.org/obo/UBERON_0002316 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Whole animal body proper http://purl.obolibrary.org/obo/UBERON_0013702 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole blood (WB) blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 -whole blood cells blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 +Whole Blood Cells blood cell http://purl.obolibrary.org/obo/CL_0000081 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Whole blood leukocytes leukocyte http://purl.obolibrary.org/obo/CL_0000738 cell type http://www.ebi.ac.uk/efo/EFO_0000324 Whole blood RNA blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +whole blood, healthy reference subject role http://purl.obolibrary.org/obo/OBI_0000220 disease http://www.ebi.ac.uk/efo/EFO_0000408 whole brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +whole cerebellum cerebellum http://purl.obolibrary.org/obo/UBERON_0002037 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Whole cortex cerebral cortex http://purl.obolibrary.org/obo/UBERON_0000956 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Whole embryo embryo http://purl.obolibrary.org/obo/UBERON_0000922 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Whole heart heart http://purl.obolibrary.org/obo/UBERON_0000948 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole hippocampus Ammon's horn http://purl.obolibrary.org/obo/UBERON_0001954 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole liver liver http://purl.obolibrary.org/obo/UBERON_0002107 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole lung lung http://purl.obolibrary.org/obo/UBERON_0002048 organism part http://www.ebi.ac.uk/efo/EFO_0000635 +Whole Mouse Brain brain http://purl.obolibrary.org/obo/UBERON_0000955 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole organism body proper http://purl.obolibrary.org/obo/UBERON_0013702 organism part http://www.ebi.ac.uk/efo/EFO_0000635 Whole peripheral blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole retina retina http://purl.obolibrary.org/obo/UBERON_0000966 organism part http://www.ebi.ac.uk/efo/EFO_0000635 @@ -669,8 +1385,15 @@ whole striatum striatum http://purl.obolibrary.org/obo/UBERON_0002435 organism p Whole visceral adipose tissue visceral abdominal adipose tissue http://purl.obolibrary.org/obo/UBERON_0014454 organism part http://www.ebi.ac.uk/efo/EFO_0000635 whole-blood blood http://purl.obolibrary.org/obo/UBERON_0000178 organism part http://www.ebi.ac.uk/efo/EFO_0000635 wild type wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +wild-type wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 wildtype wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 -wistar Wistar http://www.ebi.ac.uk/efo/EFO_0001342 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Wistar Wistar http://www.ebi.ac.uk/efo/EFO_0001342 strain http://www.ebi.ac.uk/efo/EFO_0005135 Wistar rat Wistar http://www.ebi.ac.uk/efo/EFO_0001342 strain http://www.ebi.ac.uk/efo/EFO_0005135 +Wistar-Kyoto Wistar-Kyoto http://www.ebi.ac.uk/efo/EFO_0001345 strain http://www.ebi.ac.uk/efo/EFO_0005135 wt wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +WT/WT wild type genotype http://www.ebi.ac.uk/efo/EFO_0005168 genotype http://www.ebi.ac.uk/efo/EFO_0000513 +xenograft xenograft http://purl.obolibrary.org/obo/OBI_0100058 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Yoruba in Ibadan Yoruban http://purl.obolibrary.org/obo/HANCESTRO_0575 population http://purl.obolibrary.org/obo/OBI_0000181 +Yoruban sample Yoruban http://purl.obolibrary.org/obo/HANCESTRO_0575 population http://purl.obolibrary.org/obo/OBI_0000181 zebularine zebularine http://purl.obolibrary.org/obo/CHEBI_46938 treatment http://www.ebi.ac.uk/efo/EFO_0000727 +Zuckerkandl organ paraaortic body http://purl.obolibrary.org/obo/UBERON_0001237 organism part http://www.ebi.ac.uk/efo/EFO_0000635 diff --git a/gemma-core/src/main/resources/ubic/gemma/model/analysis/Investigation.hbm.xml b/gemma-core/src/main/resources/ubic/gemma/model/analysis/Investigation.hbm.xml index e30bb299a6..e43a84ccad 100644 --- a/gemma-core/src/main/resources/ubic/gemma/model/analysis/Investigation.hbm.xml +++ b/gemma-core/src/main/resources/ubic/gemma/model/analysis/Investigation.hbm.xml @@ -89,7 +89,7 @@ fetch="select"> - + diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/AncovaTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/AncovaTest.java index c66d6e3e8a..7859b20b88 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/AncovaTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/AncovaTest.java @@ -463,6 +463,7 @@ public void testAncovaWithInteraction() { assertEquals( 1, r.getContrasts().size() ); ContrastResult contrast = r.getContrasts().iterator().next(); assertEquals( super.factorValueA1, contrast.getFactorValue() ); + assertNotNull( contrast.getLogFoldChange() ); assertEquals( -202.5587, contrast.getLogFoldChange(), 0.001 ); foundContrast = true; break; diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/BaseAnalyzerConfigurationTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/BaseAnalyzerConfigurationTest.java index f010841e3b..484c342053 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/BaseAnalyzerConfigurationTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/BaseAnalyzerConfigurationTest.java @@ -331,6 +331,7 @@ public void setUp() throws Exception { biomaterial3b.getBioAssaysUsedIn().add( bioAssay3b ); expressionExperiment.setBioAssays( new HashSet<>( bioAssays ) ); + expressionExperiment.setNumberOfSamples( new HashSet<>( bioAssays ).size() ); experimentalFactors = new ArrayList<>(); experimentalFactors.add( experimentalFactorA_Area ); @@ -431,6 +432,7 @@ void configureTestDataForTwoWayAnovaWithoutInteractions() throws Exception { bioAssays.remove( bioAssay3b ); expressionExperiment.setBioAssays( new HashSet<>( bioAssays ) ); + expressionExperiment.setNumberOfSamples( new HashSet<>( bioAssays ).size() ); bioAssayDimension.setBioAssays( bioAssays ); @@ -485,7 +487,9 @@ void configureVectors( List bioMaterials, String resourcePath ) thr compositeSequences.add( cs ); } - expressionExperiment.setProcessedExpressionDataVectors( new HashSet<>( vectors ) ); + Set vectorsSet = new HashSet<>( vectors ); + expressionExperiment.setProcessedExpressionDataVectors( vectorsSet ); + expressionExperiment.setNumberOfDataVectors( vectorsSet.size() ); arrayDesign.setCompositeSequences( compositeSequences ); } diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/DifferentialExpressionAnalyzerServiceTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/DifferentialExpressionAnalyzerServiceTest.java index 14215b4f26..14a8a468aa 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/DifferentialExpressionAnalyzerServiceTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/DifferentialExpressionAnalyzerServiceTest.java @@ -37,17 +37,20 @@ import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysis; import ubic.gemma.model.analysis.expression.diff.DifferentialExpressionAnalysisValueObject; import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; +import ubic.gemma.model.common.description.Characteristic; +import ubic.gemma.model.common.measurement.Measurement; +import ubic.gemma.model.common.measurement.MeasurementType; +import ubic.gemma.model.common.quantitationtype.PrimitiveType; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.bioAssay.BioAssay; import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; import ubic.gemma.model.expression.biomaterial.BioMaterial; -import ubic.gemma.model.expression.experiment.ExperimentalFactor; -import ubic.gemma.model.expression.experiment.ExpressionExperiment; -import ubic.gemma.model.expression.experiment.ExpressionExperimentDetailsValueObject; -import ubic.gemma.model.expression.experiment.ExpressionExperimentSubSet; +import ubic.gemma.model.expression.biomaterial.BioMaterialValueObject; +import ubic.gemma.model.expression.experiment.*; import ubic.gemma.persistence.service.analysis.expression.diff.DifferentialExpressionAnalysisService; import ubic.gemma.persistence.service.analysis.expression.diff.DifferentialExpressionResultService; import ubic.gemma.persistence.service.expression.bioAssayData.ProcessedExpressionDataVectorService; +import ubic.gemma.persistence.service.expression.experiment.ExperimentalDesignService; import ubic.gemma.persistence.service.expression.experiment.ExperimentalFactorService; import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentService; @@ -85,6 +88,9 @@ public class DifferentialExpressionAnalyzerServiceTest extends AbstractGeoServic @Autowired private ExpressionExperimentService expressionExperimentService = null; + @Autowired + private ExperimentalDesignService experimentalDesignService; + @Autowired private ProcessedExpressionDataVectorService processedDataVectorService; @@ -332,6 +338,59 @@ public void testWritePValuesHistogram() throws Exception { } + // See https://github.com/PavlidisLab/Gemma/issues/1034 + @Test + public void testContinuousFactor() throws Exception { + prepareGSE1611(); + + ExperimentalDesign ed = ee.getExperimentalDesign(); + // add a continuous factor. Code similar to ExperimentalDesignController.createExperimentalFactor + ExperimentalFactor ef = ExperimentalFactor.Factory.newInstance(); + ef.setType( FactorType.CONTINUOUS ); + ef.setExperimentalDesign( ed ); + ef.setName( "test" ); + ef.setDescription( "continuous" ); + Characteristic c = Characteristic.Factory.newInstance(); + c.setCategory( "test" ); + c.setValue( "testcontinuous" ); + ef.setCategory( c ); + + ed.getExperimentalFactors().add( ef ); + + experimentalDesignService.update( ed ); + + Collection result = new HashSet<>(); + int i = 0; // just fill in silly values. + Map bmToFv = new HashMap<>(); + for ( BioAssay assay : ee.getBioAssays() ) { + BioMaterial sample = assay.getSampleUsed(); + + FactorValue fv = FactorValue.Factory.newInstance(); + fv.setExperimentalFactor( ef ); + Measurement m = Measurement.Factory.newInstance( MeasurementType.ABSOLUTE, new Double( ++i ).toString(), PrimitiveType.DOUBLE ); + fv.setMeasurement( m ); + bmToFv.put( sample, fv ); + + } + expressionExperimentService.addFactorValues( ee, bmToFv ); + + ee = expressionExperimentService.thawLite( ee ); + + assertEquals( 3, ee.getExperimentalDesign().getExperimentalFactors().size() ); + + // analyze + DifferentialExpressionAnalysisConfig config = new DifferentialExpressionAnalysisConfig(); + Collection factors = ee.getExperimentalDesign().getExperimentalFactors(); + config.setFactorsToInclude( factors ); + Collection analyses = differentialExpressionAnalyzerService + .runDifferentialExpressionAnalyses( ee, config ); + assertFalse( analyses.isEmpty() ); + + // this triggers an error? + expressionDataFileService.writeDiffExArchiveFile( ee, analyses.iterator().next(), config ); + + } + private void prepareGSE1611() throws Exception { try { geoService.setGeoDomainObjectGenerator( diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/LowVarianceDataTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/LowVarianceDataTest.java index c4ba8465c0..596eaf902a 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/LowVarianceDataTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/LowVarianceDataTest.java @@ -87,7 +87,7 @@ public void checkResults( DifferentialExpressionAnalysis analysis ) { for ( DifferentialExpressionAnalysisResult r : results ) { CompositeSequence probe = r.getProbe(); - // log.info( probe.getName() + " " + r.getPvalue() ); + log.info( probe.getName() + " " + r.getPvalue() ); switch ( probe.getName() ) { case "1552338_at": @@ -96,9 +96,9 @@ public void checkResults( DifferentialExpressionAnalysis analysis ) { case "1552337_s_at": fail( "Should not have found a result for constant probe: 1552337_s_at" ); break; - case "1552391_at": - fail( "Should not have found a result for constant probe: 1552391_at" ); - break; +// case "1552391_at": +// fail( "Should not have found a result for constant probe: 1552391_at" ); +// break; default: found1 = true; break; diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/TwoWayAnovaWithInteractionTest2.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/TwoWayAnovaWithInteractionTest2.java index b86025fd22..4f25003b96 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/TwoWayAnovaWithInteractionTest2.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/expression/diff/TwoWayAnovaWithInteractionTest2.java @@ -156,6 +156,7 @@ public void test() { DifferentialExpressionAnalysis refetched = differentialExpressionAnalysisService .load( persistent.iterator().next().getId() ); + assertNotNull( refetched ); refetched = differentialExpressionAnalysisService.thaw( refetched ); for ( ExpressionAnalysisResultSet ears : refetched.getResultSets() ) { diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceTest.java index 4f8f8ea864..3d6839dd69 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/MeanVarianceServiceTest.java @@ -189,8 +189,9 @@ final public void testServiceCreateCountData() throws Exception { // so it doesn't look for soft files geoService.setGeoDomainObjectGenerator( new GeoDomainObjectGenerator() ); - if ( null != eeService.findByShortName( "GSE29006" ) ) - eeService.remove( eeService.findByShortName( "GSE29006" ) ); + ExpressionExperiment ee2 = eeService.findByShortName( "GSE29006" ); + if ( ee2 != null ) + eeService.remove( ee2 ); try { Collection results = geoService.fetchAndLoad( "GSE29006", false, false, false ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SampleCoexpressionAnalysisServiceTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SampleCoexpressionAnalysisServiceTest.java index 099fdf1ca1..d38caf391a 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SampleCoexpressionAnalysisServiceTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SampleCoexpressionAnalysisServiceTest.java @@ -47,7 +47,7 @@ public void test() { assertNull( sampleCoexpressionAnalysisService.loadBestMatrix( ee ) ); processedExpressionDataVectorService.computeProcessedExpressionData( ee ); - sampleCoexpressionAnalysisService.compute( ee ); + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); DoubleMatrix matrix = sampleCoexpressionAnalysisService.loadFullMatrix( ee ); assertNotNull( matrix ); assertTrue( sampleCoexpressionAnalysisService.hasAnalysis( ee ) ); @@ -55,7 +55,7 @@ public void test() { this.check( matrix ); // recompute ... - sampleCoexpressionAnalysisService.compute( ee ); + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); matrix = sampleCoexpressionAnalysisService.loadFullMatrix( ee ); assertNotNull( matrix ); assertTrue( sampleCoexpressionAnalysisService.hasAnalysis( ee ) ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SplitExperimentTest.java b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SplitExperimentTest.java index 7333d51443..f956f72074 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SplitExperimentTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/analysis/preprocess/SplitExperimentTest.java @@ -131,6 +131,8 @@ public void testSplitGSE17183ByOrganismPart() throws Exception { ExpressionExperiment e = eeService.thaw( ( ExpressionExperiment ) b ); // sanity checks for the clones + assertNotNull( ee.getAccession() ); + assertNotNull( e.getAccession() ); assertNotEquals( ee.getAccession().getId(), e.getAccession().getId() ); assertEquals( ee.getTaxon(), e.getTaxon() ); assertNotEquals( ee.getAuditTrail().getId(), e.getAuditTrail().getId() ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixTest.java b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixTest.java index d6a2bb084e..686c3ad0ab 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixTest.java @@ -312,7 +312,8 @@ public void testMatrixConversion() throws Exception { processedDataVectorService.computeProcessedExpressionData( newee ); File f1 = expressionDataFileService - .writeOrLocateDataFile( expressionExperimentService.load( newee.getId() ), true, true ); + .writeOrLocateProcessedDataFile( expressionExperimentService.load( newee.getId() ), true, true ) + .orElse( null ); assertNotNull( f1 ); assertTrue( f1.exists() ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtilTest.java b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtilTest.java index d0bc11059a..26dad31f09 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtilTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataDoubleMatrixUtilTest.java @@ -338,6 +338,7 @@ private ExpressionDataDoubleMatrix readTestMatrix( String shortName, TechnologyT ExpressionExperiment ee = new ExpressionExperiment(); ee.setShortName( shortName ); ee.setBioAssays( bas ); + ee.setNumberOfSamples( bas.size() ); QuantitationType qt = new QuantitationType(); return new ExpressionDataDoubleMatrix( ee, qt, matrix ); } catch ( IOException e ) { diff --git a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSortTest.java b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSortTest.java index 42cd82928e..f83b5cd088 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSortTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/datastructure/matrix/ExpressionDataMatrixColumnSortTest.java @@ -56,8 +56,8 @@ public void testOrderByExperimentalDesignB() { * Five factors. Factor4 is a measurmeent. */ - Collection factors = new HashSet<>(); - for ( int i = 0; i < 5; i++ ) { + Collection categoricalfactors = new HashSet<>(); + for ( int i = 0; i < 4; i++ ) { ExperimentalFactor ef = ExperimentalFactor.Factory.newInstance(); ef.setType( FactorType.CATEGORICAL ); ef.setName( "factor" + i ); @@ -66,31 +66,28 @@ public void testOrderByExperimentalDesignB() { } ef.setId( ( long ) i ); + // make three factor values for each factor (other than the measurement) for ( int j = 0; j < 3; j++ ) { FactorValue fv = FactorValue.Factory.newInstance(); - fv.setValue( "fv" + ( j + 1 ) * ( i + 1 ) ); + fv.setValue( "fv" + ( j + 1 ) * ( i + 1 ) + "x" + ( i + 1 ) ); fv.setId( ( long ) ( j + 1 ) * ( i + 1 ) ); fv.setExperimentalFactor( ef ); - ef.getFactorValues().add( fv ); - if ( j == 2 && i != 4 ) { + if ( j == 2 ) { fv.setValue( "control_group" ); } - - if ( i == 4 ) { - ef.setType( FactorType.CONTINUOUS ); - Measurement m = Measurement.Factory.newInstance(); - m.setId( ( long ) j * ( i + 1 ) ); - m.setValue( j + ".00" ); - m.setRepresentation( PrimitiveType.DOUBLE ); - fv.setMeasurement( m ); - } + // log.info( fv ); + ef.getFactorValues().add( fv ); } - - factors.add( ef ); } + ExperimentalFactor continuousFactor = ExperimentalFactor.Factory.newInstance(); + continuousFactor.setType( FactorType.CONTINUOUS ); + continuousFactor.setName( "measurement" ); + continuousFactor.setId( ( long ) 400 ); + Random random = new Random(); + Collection seen = new HashSet<>(); for ( int i = 0; i < 100; i++ ) { BioAssay ba = BioAssay.Factory.newInstance(); ba.setName( "ba" + i ); @@ -103,7 +100,24 @@ public void testOrderByExperimentalDesignB() { bm.setName( "bm" + i ); ba.setSampleUsed( bm ); - for ( ExperimentalFactor ef : factors ) { + if ( seen.contains( bm ) ) throw new IllegalStateException( "Duplicate biomaterial" ); + + seen.add( bm ); + + /// add the continuous factor + FactorValue contfv = FactorValue.Factory.newInstance(); + contfv.setId( i + 1924904L ); + contfv.setExperimentalFactor( continuousFactor ); + Measurement measurement = Measurement.Factory.newInstance(); + measurement.setId( ( long ) 4289 * ( i + 1 ) ); + measurement.setValue( "" + random.nextDouble() ); + measurement.setRepresentation( PrimitiveType.DOUBLE ); + contfv.setMeasurement( measurement ); + continuousFactor.getFactorValues().add( contfv ); + bm.getFactorValues().add( contfv ); + + // Add the other factors. + for ( ExperimentalFactor ef : categoricalfactors ) { /* * Note: if we use 4, then some of the biomaterials will not have a factorvalue for each factor. This is @@ -120,12 +134,35 @@ public void testOrderByExperimentalDesignB() { m++; } - if ( toUse != null ) + if ( toUse != null ) { +// Collection fvs = bm.getFactorValues(); +// for ( FactorValue fv : fvs ) { +// if ( fv.getExperimentalFactor().equals( ef ) ) { +// throw new IllegalStateException( bm + " already has a factor value for " + ef ); +// } +// } + bm.getFactorValues().add( toUse ); - // log.info( ba + " -> " + bm + " -> " + ef + " -> " + toUse ); + // log.info( ba + " -> " + bm + " -> " + ef + " -> " + toUse );} + } } } + // check that each biomaterial has only one fator value for each experimental factor +// for ( BioAssay ba : bad.getBioAssays() ) { +// BioMaterial bm = ba.getSampleUsed(); +// for ( ExperimentalFactor ef : categoricalfactors ) { +// int j = 0; +// Collection fvs = bm.getFactorValues(); +// for ( FactorValue fv : fvs ) { +// if ( fv.getExperimentalFactor().equals( ef ) ) { +// j++; +// } +// } +// assertEquals( bm + " had more than one factorvalue for " + ef, 1, j ); +// } +// } + EmptyExpressionMatrix mat = new EmptyExpressionMatrix( bad ); assertEquals( 100, mat.columns() ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoBrowserTest.java b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoBrowserTest.java index 0d084c514a..03bfad989d 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoBrowserTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoBrowserTest.java @@ -20,7 +20,7 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.junit.Before; +import org.junit.BeforeClass; import org.junit.Test; import org.junit.experimental.categories.Category; import ubic.gemma.core.loader.expression.geo.model.GeoRecord; @@ -46,8 +46,8 @@ public class GeoBrowserTest { private static final Log log = LogFactory.getLog( GeoBrowserTest.class ); - @Before - public void setUp() throws Exception { + @BeforeClass + public static void checkThatGeoIsAvailable() throws Exception { assumeThatResourceIsAvailable( "https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary.fcgi" ); } diff --git a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoTermReplacementTest.java b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoTermReplacementTest.java index bcdd697b8b..941b9e3d64 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoTermReplacementTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/GeoTermReplacementTest.java @@ -5,12 +5,13 @@ import org.apache.commons.csv.CSVFormat; import org.apache.commons.csv.CSVParser; import org.apache.commons.csv.CSVRecord; +import org.apache.commons.lang3.time.StopWatch; import org.assertj.core.api.SoftAssertions; import org.junit.Test; import org.junit.experimental.categories.Category; -import ubic.basecode.ontology.model.AnnotationProperty; import ubic.basecode.ontology.model.OntologyTerm; import ubic.basecode.ontology.providers.*; +import ubic.gemma.core.ontology.providers.GemmaOntologyService; import ubic.gemma.core.ontology.providers.MondoOntologyService; import ubic.gemma.core.ontology.providers.PatoOntologyService; import ubic.gemma.core.util.test.category.SlowTest; @@ -27,7 +28,7 @@ import java.util.stream.Collectors; import static java.util.Objects.requireNonNull; -import static org.junit.Assert.assertNotNull; +import static org.assertj.core.api.Assertions.assertThat; import static org.junit.Assume.assumeNoException; /** @@ -38,25 +39,36 @@ public class GeoTermReplacementTest { private static final List ontologies = new ArrayList<>(); + private static final Map> prefixesByOntology = new HashMap<>(); static { - addOntology( new CellLineOntologyService() ); - addOntology( new CellTypeOntologyService() ); - addOntology( new ObiService() ); - addOntology( new MondoOntologyService() ); - addOntology( new UberonOntologyService() ); - addOntology( new PatoOntologyService() ); - addOntology( new MammalianPhenotypeOntologyService() ); - // FIXME: addOntology( new ChebiOntologyService() ); - // EFO is a grab bag, so we list it last - addOntology( new ExperimentalFactorOntologyService() ); + addOntology( new GemmaOntologyService(), "http://gemma.msl.ubc.ca/ont/TGEMO_" ); + addOntology( new ObiService(), "http://purl.obolibrary.org/obo/OBI_" ); + addOntology( new PatoOntologyService(), "http://purl.obolibrary.org/obo/PATO_" ); + addOntology( new CellTypeOntologyService(), "http://purl.obolibrary.org/obo/CL_" ); + addOntology( new CellLineOntologyService(), "http://purl.obolibrary.org/obo/CLO_" ); + addOntology( new MondoOntologyService(), "http://purl.obolibrary.org/obo/MONDO_" ); + addOntology( new UberonOntologyService(), "http://purl.obolibrary.org/obo/UBERON_" ); + addOntology( new HumanPhenotypeOntologyService(), "http://purl.obolibrary.org/obo/HP_" ); + addOntology( new MammalianPhenotypeOntologyService(), "http://purl.obolibrary.org/obo/MP_" ); + addOntology( new ExperimentalFactorOntologyService(), "http://www.ebi.ac.uk/efo/", "http://purl.obolibrary.org/obo/BTO_" ); + // TODO: addOntology( new ChebiOntologyService(), "http://purl.obolibrary.org/obo/CHEBI_" ); } - private static void addOntology( OntologyService ontology ) { + private static void addOntology( OntologyService ontology, String... prefix ) { ontology.setInferenceMode( OntologyService.InferenceMode.NONE ); ontology.setSearchEnabled( false ); ontology.setProcessImports( false ); ontologies.add( ontology ); + prefixesByOntology.put( ontology, Arrays.asList( prefix ) ); + } + + /** + * Remove an ontology in order to free some memory. + */ + private static void removeOntology( OntologyService ontology ) { + ontologies.remove( ontology ); + prefixesByOntology.remove( ontology ); } @Value @@ -73,15 +85,16 @@ public void test() throws Exception { ExecutorCompletionService cs = new ExecutorCompletionService<>( Executors.newFixedThreadPool( 8 ) ); for ( OntologyService os : ontologies ) { cs.submit( () -> { + StopWatch watch = StopWatch.createStarted(); os.initialize( true, false ); + log.info( "Initialized " + os + " in " + watch.getTime() + " ms" ); return os; } ); } List records = new ArrayList<>(); try ( InputStream is = getClass().getResourceAsStream( "/ubic/gemma/core/ontology/valueStringToOntologyTermMappings.txt" ) ) { - assertNotNull( is ); - for ( CSVRecord record : CSVParser.parse( is, StandardCharsets.UTF_8, CSVFormat.TDF.withCommentMarker( '#' ) ) ) { + for ( CSVRecord record : CSVParser.parse( requireNonNull( is ), StandardCharsets.UTF_8, CSVFormat.TDF.withCommentMarker( '#' ) ) ) { String synonym = record.get( 0 ); String value = record.get( 1 ); String valueUri = record.get( 2 ); @@ -95,6 +108,10 @@ public void test() throws Exception { if ( valueUri.startsWith( "http://purl.obolibrary.org/obo/HANCESTRO_" ) ) { continue; } + // FIXME: enable GO + if ( valueUri.startsWith( "http://purl.obolibrary.org/obo/GO_" ) ) { + continue; + } if ( valueUri.startsWith( "http://purl.obolibrary.org/obo/NCBITaxon_" ) ) { continue; } @@ -104,6 +121,7 @@ public void test() throws Exception { SoftAssertions assertions = new SoftAssertions(); + // verify category URIs against EFO.factor.categories.txt Map categories; try ( BufferedReader reader = new BufferedReader( new InputStreamReader( requireNonNull( GeoTermReplacementTest.class.getResourceAsStream( "/ubic/gemma/core/ontology/EFO.factor.categories.txt" ) ) ) ) ) { categories = reader.lines() @@ -121,8 +139,22 @@ public void test() throws Exception { .containsEntry( rec.categoryUri, rec.category ); } + // verify that all term has a supported prefix + for ( Rec rec : records ) { + assertions.assertThat( prefixesByOntology.values() ) + .withFailMessage( "%s: No prefix for %s", rec.synonym, rec.valueUri ) + .flatMap( c -> c ) + .anySatisfy( prefix -> { + assertThat( rec.valueUri ).startsWith( prefix ); + } ); + } + + // fail now if possible, because the next step is going to be expensive + assertions.assertAll(); + + int numOntologies = ontologies.size(); Set seen = new HashSet<>(); - for ( int i = 0; i < ontologies.size(); i++ ) { + for ( int i = 0; i < numOntologies; i++ ) { OntologyService os; try { os = cs.take().get(); @@ -132,27 +164,23 @@ public void test() throws Exception { return; } for ( Rec rec : records ) { - // skip undeclared terms - OntologyTerm term = os.getTerm( rec.valueUri ); - if ( term == null ) { - continue; - } - // skip terms lacking a label - if ( term.getAnnotations().stream().map( AnnotationProperty::getProperty ).noneMatch( "label"::equals ) ) { - continue; - } - // CLO has a typo, ignore it - if ( "http://purl.obolibrary.org/obo/CL_0000047".equals( term.getUri() ) && "neuronal stem cell".equals( term.getLabel() ) ) { + if ( prefixesByOntology.get( os ).stream().noneMatch( rec.valueUri::startsWith ) ) { continue; } - if ( "http://purl.obolibrary.org/obo/CL_0000136".equals( term.getUri() ) && "adipocyte".equals( term.getLabel() ) ) { + OntologyTerm term = os.getTerm( rec.valueUri ); + assertions.assertThat( term ) + .withFailMessage( "%s: No term found for %s in %s", rec.synonym, rec.valueUri, os ) + .isNotNull(); + if ( term == null ) { continue; } - seen.add( rec.synonym ); assertions.assertThat( rec.value ) - .withFailMessage( "%s: Replace '%s' with '%s' %s", rec.synonym, rec.value, term.getLabel(), term.getUri() ) + .withFailMessage( "%s: Replace '%s' with '%s' from %s", rec.synonym, rec.value, term.getLabel(), os ) .isEqualTo( term.getLabel() ); + seen.add( rec.synonym ); } + assertions.assertAll(); + removeOntology( os ); } for ( Rec rec : records ) { diff --git a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/service/GeoDatasetServiceTest.java b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/service/GeoDatasetServiceTest.java index e23c3c50af..9f55f9fcc5 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/service/GeoDatasetServiceTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/loader/expression/geo/service/GeoDatasetServiceTest.java @@ -249,7 +249,8 @@ public void testFetchAndLoadGSE9048() throws Exception { ee = this.eeService.thawLite( ee ); qts = eeService.getQuantitationTypes( ee ); assertEquals( 18, qts.size() ); - File f = dataFileService.writeOrLocateDataFile( ee, true, true ); + File f = dataFileService.writeOrLocateProcessedDataFile( ee, true, true ).orElse( null ); + assertNotNull( f ); assertTrue( f.canRead() ); assertTrue( f.length() > 0 ); } @@ -277,6 +278,7 @@ public void testFetchAndLoadGSE18707() { assertEquals( 100, dataVectors.size() ); ee = eeService.findByShortName( "GSE18707" ); + assertNotNull( ee ); qts = eeService.getQuantitationTypes( ee ); @@ -367,11 +369,13 @@ public void testLoadGSE30521ExonArray() { eeService.update( ee ); geoService.updateFromGEO( "GSE30521" ); ee = eeService.load( ee.getId() ); + assertNotNull( ee ); ee = this.eeService.thawLite( ee ); - assertNotNull(ee.getPrimaryPublication()); - for(BioAssay ba : ee.getBioAssays()) { - assertTrue(!ba.getSampleUsed().getCharacteristics().isEmpty()); - for( Characteristic c : ba.getSampleUsed().getCharacteristics() ) { + assertNotNull( ee ); + assertNotNull( ee.getPrimaryPublication() ); + for ( BioAssay ba : ee.getBioAssays() ) { + assertTrue( !ba.getSampleUsed().getCharacteristics().isEmpty() ); + for ( Characteristic c : ba.getSampleUsed().getCharacteristics() ) { assertNotNull( c.getCategory() ); } } diff --git a/gemma-core/src/test/java/ubic/gemma/core/loader/util/TestUtils.java b/gemma-core/src/test/java/ubic/gemma/core/loader/util/TestUtils.java index e1fb854ea6..4f4fb14924 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/loader/util/TestUtils.java +++ b/gemma-core/src/test/java/ubic/gemma/core/loader/util/TestUtils.java @@ -7,8 +7,7 @@ import java.util.concurrent.ExecutionException; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; +import static org.junit.Assert.*; public class TestUtils { @@ -48,9 +47,11 @@ public static void assertBAs( ExpressionExperiment ee, ArrayDesign targetArrayDe for ( BioAssay ba : ee.getBioAssays() ) { assertEquals( targetArrayDesign, ba.getArrayDesignUsed() ); + assertNotNull( ba.getSequenceReadLength() ); assertEquals( 36, ba.getSequenceReadLength().intValue() ); if ( ba.getDescription().contains( accession ) ) { + assertNotNull( ba.getSequenceReadCount() ); assertEquals( readCount, ba.getSequenceReadCount().intValue() ); found = true; } diff --git a/gemma-core/src/test/java/ubic/gemma/core/ontology/OntologyLoadingTest.java b/gemma-core/src/test/java/ubic/gemma/core/ontology/OntologyLoadingTest.java index 1710c8831e..595e112856 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/ontology/OntologyLoadingTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/ontology/OntologyLoadingTest.java @@ -33,7 +33,7 @@ */ @CommonsLog @ActiveProfiles("production") -@ContextConfiguration(locations = { "classpath*:ubic/gemma/applicationContext-ontology.xml", "classpath:ubic/gemma/core/ontology/OntologyLoadingTest-context.xml" }) +@ContextConfiguration public class OntologyLoadingTest extends AbstractJUnit4SpringContextTests { @Autowired diff --git a/gemma-core/src/test/java/ubic/gemma/core/util/BuildInfoTest.java b/gemma-core/src/test/java/ubic/gemma/core/util/BuildInfoTest.java index 8b7a37df67..aaac58b95d 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/util/BuildInfoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/util/BuildInfoTest.java @@ -47,10 +47,10 @@ public void test() { } @Test - public void testFromSettings() { + public void testFromClasspath() { assumeTrue( "Make sure that Gemma is build with Maven so that version.properties is generated.", getClass().getResource( "/ubic/gemma/version.properties" ) != null ); - buildInfo = BuildInfo.fromSettings(); + buildInfo = BuildInfo.fromClasspath(); assertNotNull( buildInfo.getVersion() ); assertNotNull( buildInfo.getTimestamp() ); assertNotNull( buildInfo.getGitHash() ); diff --git a/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseDatabaseTest.java b/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseDatabaseTest.java index 6f162a62cb..c26027600d 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseDatabaseTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseDatabaseTest.java @@ -126,8 +126,8 @@ public DataSourceInitializer( DataSource dataSource ) { @Override public void afterPropertiesSet() { JdbcTestUtils.executeSqlScript( template, applicationContext.getResource( "/sql/init-acls.sql" ), false ); - JdbcTestUtils.executeSqlScript( template, applicationContext.getResource( "/sql/init-entities.sql" ), false ); - JdbcTestUtils.executeSqlScript( template, applicationContext.getResource( "/sql/init-indices.sql" ), false ); + JdbcTestUtils.executeSqlScript( template, applicationContext.getResource( "/sql/h2/init-entities.sql" ), false ); + JdbcTestUtils.executeSqlScript( template, applicationContext.getResource( "/sql/h2/init-indices.sql" ), false ); } } } diff --git a/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseSpringContextTest.java b/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseSpringContextTest.java index d4fb370c69..b4bf468d22 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseSpringContextTest.java +++ b/gemma-core/src/test/java/ubic/gemma/core/util/test/BaseSpringContextTest.java @@ -62,7 +62,7 @@ import ubic.gemma.persistence.persister.PersisterHelper; import ubic.gemma.persistence.service.common.description.ExternalDatabaseService; import ubic.gemma.persistence.service.genome.taxon.TaxonService; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; import javax.annotation.OverridingMethodsMustInvokeSuper; import javax.sql.DataSource; @@ -76,7 +76,7 @@ * * @author pavlidis */ -@ActiveProfiles(SpringProfiles.TEST) +@ActiveProfiles(EnvironmentProfiles.TEST) @Category(IntegrationTest.class) @SuppressWarnings({ "WeakerAccess", "SameParameterValue", "unused" }) // Better left as is for future convenience @ContextConfiguration(locations = { "classpath*:ubic/gemma/applicationContext-*.xml" }) diff --git a/gemma-core/src/test/java/ubic/gemma/core/util/test/PersistentDummyObjectHelper.java b/gemma-core/src/test/java/ubic/gemma/core/util/test/PersistentDummyObjectHelper.java index 89f7f2bd94..9782c616a1 100644 --- a/gemma-core/src/test/java/ubic/gemma/core/util/test/PersistentDummyObjectHelper.java +++ b/gemma-core/src/test/java/ubic/gemma/core/util/test/PersistentDummyObjectHelper.java @@ -286,6 +286,7 @@ public ExpressionExperiment getTestExpressionExperimentWithAllDependencies( Expr } ee.setBioAssays( bioAssays ); + ee.setNumberOfSamples( bioAssays.size() ); ee.setTaxon( bioAssays.iterator().next().getSampleUsed().getSourceTaxon() ); assert quantitationTypes.size() > 0; @@ -332,6 +333,7 @@ public ExpressionExperiment getTestExpressionExperimentWithAllDependencies( bool bioAssays.addAll( bioAssaysA ); bioAssays.addAll( bioAssaysB ); ee.setBioAssays( bioAssays ); + ee.setNumberOfSamples( bioAssays.size() ); ee.setTaxon( bioAssays.iterator().next().getSampleUsed().getSourceTaxon() ); log.debug( "expression experiment => design element data vectors" ); @@ -775,6 +777,7 @@ public ExpressionExperiment getTestPersistentExpressionExperiment( Taxon taxon ) ee.setShortName( RandomStringUtils.randomNumeric( PersistentDummyObjectHelper.RANDOM_STRING_LENGTH ) + "_testee" ); ee.setBioAssays( bas1 ); + ee.setNumberOfSamples( bas1.size() ); Collection allFactorValues = new HashSet<>(); diff --git a/gemma-core/src/test/java/ubic/gemma/model/genome/TaxonServiceImplTest.java b/gemma-core/src/test/java/ubic/gemma/model/genome/TaxonServiceImplTest.java index e7534fbab9..c24f82fc6c 100644 --- a/gemma-core/src/test/java/ubic/gemma/model/genome/TaxonServiceImplTest.java +++ b/gemma-core/src/test/java/ubic/gemma/model/genome/TaxonServiceImplTest.java @@ -34,6 +34,8 @@ public class TaxonServiceImplTest extends BaseSpringContextTest { /** * Test method for {@link ubic.gemma.persistence.service.genome.taxon.TaxonService#findOrCreate(Taxon)} )}. * Situation where the secondary id is treated as the primary, we must not make a new taxon! + * + * This test uses a taxon Gemma isn't using right now but this could be relevant in general. */ @Test public void testFindOrCreate() { @@ -41,7 +43,7 @@ public void testFindOrCreate() { t.setNcbiId( 559292 ); Taxon yeast = taxonService.findByCommonName( "yeast" ); - assertNotNull( yeast ); // this should be loaded automatically. + assertNotNull( yeast ); Taxon found = taxonService.findOrCreate( t ); @@ -50,9 +52,9 @@ public void testFindOrCreate() { @Test public void testLoadValueObject() { - Taxon yeast = taxonService.findByCommonName( "yeast" ); - assertNotNull( yeast ); // this should be loaded automatically. - TaxonValueObject vo = taxonService.loadValueObject( yeast ); + Taxon h = taxonService.findByCommonName( "human" ); + assertNotNull( h ); + TaxonValueObject vo = taxonService.loadValueObject( h ); assertNotNull( vo ); } diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilIntegrationTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilIntegrationTest.java index 6d6ba32f06..6a5525418e 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilIntegrationTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilIntegrationTest.java @@ -4,18 +4,22 @@ import org.junit.Before; import org.junit.Test; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; import org.springframework.security.access.AccessDeniedException; import org.springframework.security.test.context.support.WithMockUser; import org.springframework.security.test.context.support.WithSecurityContextTestExecutionListener; import org.springframework.test.context.TestExecutionListeners; import ubic.gemma.core.util.test.BaseSpringContextTest; -import ubic.gemma.persistence.util.Settings; +import ubic.gemma.model.expression.biomaterial.BioMaterial; +import ubic.gemma.model.expression.experiment.ExperimentalDesign; +import ubic.gemma.model.expression.experiment.ExpressionExperiment; +import ubic.gemma.model.expression.experiment.FactorValue; import java.io.File; import java.nio.file.Path; -import java.nio.file.Paths; import static org.assertj.core.api.Assertions.assertThat; +import static org.assertj.core.api.Assertions.assertThatThrownBy; /** * @author poirigui @@ -23,14 +27,16 @@ @TestExecutionListeners(WithSecurityContextTestExecutionListener.class) public class TableMaintenanceUtilIntegrationTest extends BaseSpringContextTest { - private static final Path GENE2CS_PATH = Paths.get( Settings.getString( "gemma.appdata.home" ), "DbReports", "gene2cs.info" ); @Autowired private TableMaintenanceUtil tableMaintenanceUtil; + @Value("${gemma.gene2cs.path}") + private Path gene2CsPath; + @Before @After public void removeGene2CsStatusFileAndDirectory() { - File f = GENE2CS_PATH.toFile(); + File f = gene2CsPath.toFile(); if ( f.exists() ) { assertThat( f.delete() ).isTrue(); // also remove the parent folder @@ -42,7 +48,7 @@ public void removeGene2CsStatusFileAndDirectory() { @WithMockUser(authorities = "GROUP_AGENT") public void testWhenUserIsAgent() { tableMaintenanceUtil.updateGene2CsEntries(); - assertThat( GENE2CS_PATH ).exists(); + assertThat( gene2CsPath ).exists(); } @Test(expected = AccessDeniedException.class) @@ -55,6 +61,12 @@ public void testWhenUserIsAnonymous() { @WithMockUser(authorities = "GROUP_AGENT") public void testUpdateExpressionExperiment2CharacteristicEntries() { tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries(); + tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries( ExpressionExperiment.class ); + tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries( BioMaterial.class ); + tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries( ExperimentalDesign.class ); + assertThatThrownBy( () -> { + tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries( FactorValue.class ); + } ).isInstanceOf( IllegalArgumentException.class ); } @Test(expected = AccessDeniedException.class) @@ -62,4 +74,10 @@ public void testUpdateEE2CAsUser() { this.runAsAnonymous(); tableMaintenanceUtil.updateExpressionExperiment2CharacteristicEntries(); } + + @Test + @WithMockUser(authorities = "GROUP_AGENT") + public void testUpdateExpressionExperiment2ArrayDesignEntries() { + tableMaintenanceUtil.updateExpressionExperiment2ArrayDesignEntries(); + } } diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilTest.java index 2cd28fe1d3..9b17dc9166 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/TableMaintenanceUtilTest.java @@ -7,16 +7,16 @@ import org.junit.Before; import org.junit.Test; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; +import org.springframework.core.convert.ConversionService; +import org.springframework.format.support.DefaultFormattingConversionService; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests; +import ubic.gemma.core.util.test.TestPropertyPlaceholderConfigurer; import ubic.gemma.model.common.description.DatabaseType; import ubic.gemma.model.common.description.ExternalDatabase; -import ubic.gemma.model.expression.biomaterial.BioMaterial; -import ubic.gemma.model.expression.experiment.ExperimentalDesign; -import ubic.gemma.model.expression.experiment.ExpressionExperiment; -import ubic.gemma.model.expression.experiment.FactorValue; import ubic.gemma.persistence.model.Gene2CsStatus; import ubic.gemma.persistence.service.common.auditAndSecurity.AuditEventService; import ubic.gemma.persistence.service.common.description.ExternalDatabaseService; @@ -28,6 +28,7 @@ import java.io.ObjectOutputStream; import java.nio.file.Files; import java.nio.file.Path; +import java.nio.file.Paths; import java.util.Date; import static org.assertj.core.api.Assertions.assertThat; @@ -40,6 +41,22 @@ public class TableMaintenanceUtilTest extends AbstractJUnit4SpringContextTests { @TestComponent static class TableMaintenanceUtilTestContextConfiguration { + @Bean + public static TestPropertyPlaceholderConfigurer propertyPlaceholderConfigurer() throws IOException { + Path gene2csInfoPath = Files.createTempDirectory( "DBReport" ).resolve( "gene2cs.info" ); + return new TestPropertyPlaceholderConfigurer( "gemma.gene2cs.path=" + gene2csInfoPath, "gemma.admin.email=gemma" ); + } + + /** + * Needed to convert {@link String} to {@link Path}. + */ + @Bean + public ConversionService conversionService() { + DefaultFormattingConversionService service = new DefaultFormattingConversionService(); + service.addConverter( String.class, Path.class, source -> Paths.get( ( String ) source ) ); + return service; + } + @Bean public TableMaintenanceUtil tableMaintenanceUtil() { return new TableMaintenanceUtilImpl(); @@ -78,14 +95,15 @@ public AuditEventService auditEventService() { @Autowired private MailEngine mailEngine; + @Value("${gemma.gene2cs.path}") + private Path gene2csInfoPath; + private final ExternalDatabase gene2csDatabaseEntry = ExternalDatabase.Factory.newInstance( "gene2cs", DatabaseType.OTHER ); private Session session; private SQLQuery query; - private Path gene2csInfoPath; - @Before public void setUp() throws IOException { when( externalDatabaseService.findByNameWithAuditTrail( "gene2cs" ) ).thenReturn( gene2csDatabaseEntry ); @@ -93,8 +111,6 @@ public void setUp() throws IOException { session = mock( Session.class ); when( session.createSQLQuery( any() ) ).thenReturn( query ); when( sessionFactory.getCurrentSession() ).thenReturn( session ); - gene2csInfoPath = Files.createTempDirectory( "DBReport" ).resolve( "gene2cs.info" ); - tableMaintenanceUtil.setGene2CsInfoPath( gene2csInfoPath ); } @After diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoTest.java index 8d733e8dba..0898893727 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionAnalysisDaoTest.java @@ -10,11 +10,13 @@ import ubic.gemma.model.analysis.expression.diff.*; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.designElement.CompositeSequence; +import ubic.gemma.model.expression.experiment.ExperimentalFactor; import ubic.gemma.model.expression.experiment.FactorValue; import ubic.gemma.model.genome.Taxon; import ubic.gemma.persistence.util.TestComponent; import java.util.ArrayList; +import java.util.Collections; import java.util.List; import static org.junit.Assert.*; @@ -123,6 +125,20 @@ public void testCreateAnalysisWithoutContrasts() { } } + @Test + public void testFindByFactor() { + ExperimentalFactor ef = new ExperimentalFactor(); + ef.setId( 1L ); + differentialExpressionAnalysisDao.findByFactor( ef ); + } + + @Test + public void testFindByFactors() { + ExperimentalFactor ef = new ExperimentalFactor(); + ef.setId( 1L ); + differentialExpressionAnalysisDao.findByFactors( Collections.singleton( ef ) ); + } + private DifferentialExpressionAnalysis createAnalysis( int numResultSets, int numResults, int numContrasts ) { DifferentialExpressionAnalysis analysis = new DifferentialExpressionAnalysis(); List probes = createPlatform( numResults ); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoTest.java new file mode 100644 index 0000000000..d0b9326506 --- /dev/null +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/analysis/expression/diff/DifferentialExpressionResultDaoTest.java @@ -0,0 +1,60 @@ +package ubic.gemma.persistence.service.analysis.expression.diff; + +import org.hibernate.SessionFactory; +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.test.context.ContextConfiguration; +import ubic.gemma.core.util.test.BaseDatabaseTest; +import ubic.gemma.model.analysis.expression.diff.ExpressionAnalysisResultSet; +import ubic.gemma.model.genome.Gene; +import ubic.gemma.persistence.util.TestComponent; + +import java.util.Collections; + +import static org.mockito.Mockito.mock; + +@ContextConfiguration +public class DifferentialExpressionResultDaoTest extends BaseDatabaseTest { + + @Configuration + @TestComponent + static class DifferentialExpressionResultDaoTestContextConfiguration extends BaseDatabaseTestContextConfiguration { + + @Bean + public DifferentialExpressionResultDao differentialExpressionResultDao( SessionFactory sessionFactory ) { + return new DifferentialExpressionResultDaoImpl( sessionFactory, mock() ); + } + } + + @Autowired + private DifferentialExpressionResultDao differentialExpressionResultDao; + + @Test + public void testFindByGene() { + Gene gene = new Gene(); + sessionFactory.getCurrentSession().persist( gene ); + differentialExpressionResultDao.findByGene( gene ); + } + + @Test + public void testFindByGeneAndExperimentAnalyzed() { + Gene gene = new Gene(); + sessionFactory.getCurrentSession().persist( gene ); + differentialExpressionResultDao.findByGeneAndExperimentAnalyzed( gene, Collections.singleton( 1L ) ); + } + + @Test + public void findByExperimentAnalyzed() { + differentialExpressionResultDao.findByExperimentAnalyzed( Collections.singleton( 1L ), 0.0001, 100 ); + } + + + @Test + public void testFindInResultSets() { + ExpressionAnalysisResultSet rs = new ExpressionAnalysisResultSet(); + sessionFactory.getCurrentSession().persist( rs ); + differentialExpressionResultDao.findInResultSet( rs, 0.0001, 100, 10 ); + } +} \ No newline at end of file diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/common/description/CharacteristicDaoImplTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/common/description/CharacteristicDaoImplTest.java index ad817a45b7..50d19bcc2d 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/common/description/CharacteristicDaoImplTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/common/description/CharacteristicDaoImplTest.java @@ -12,6 +12,8 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; +import org.springframework.core.convert.ConversionService; +import org.springframework.format.support.DefaultFormattingConversionService; import org.springframework.security.acls.domain.BasePermission; import org.springframework.security.acls.model.MutableAcl; import org.springframework.security.acls.model.MutableAclService; @@ -25,6 +27,7 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.TestExecutionListeners; import ubic.gemma.core.util.test.BaseDatabaseTest; +import ubic.gemma.core.util.test.TestPropertyPlaceholderConfigurer; import ubic.gemma.model.analysis.Investigation; import ubic.gemma.model.association.Gene2GOAssociation; import ubic.gemma.model.common.Identifiable; @@ -38,6 +41,10 @@ import ubic.gemma.persistence.util.TestComponent; import javax.annotation.Nullable; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; import java.util.*; import static org.assertj.core.api.Assertions.assertThat; @@ -51,6 +58,22 @@ public class CharacteristicDaoImplTest extends BaseDatabaseTest { @TestComponent static class CharacteristicDaoImplContextConfiguration extends BaseDatabaseTestContextConfiguration { + @Bean + public static TestPropertyPlaceholderConfigurer propertyPlaceholderConfigurer() throws IOException { + Path gene2csInfoPath = Files.createTempDirectory( "DBReport" ).resolve( "gene2cs.info" ); + return new TestPropertyPlaceholderConfigurer( "gemma.gene2cs.path=" + gene2csInfoPath, "gemma.admin.email=gemma" ); + } + + /** + * Needed to convert {@link String} to {@link Path}. + */ + @Bean + public ConversionService conversionService() { + DefaultFormattingConversionService service = new DefaultFormattingConversionService(); + service.addConverter( String.class, Path.class, source -> Paths.get( ( String ) source ) ); + return service; + } + @Bean public CharacteristicDao characteristicDao( SessionFactory sessionFactory ) { return new CharacteristicDaoImpl( sessionFactory ); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoTest.java index 0fa9a44a62..cceb9951a4 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/ProcessedExpressionDataVectorDaoTest.java @@ -69,15 +69,6 @@ public void setUp() { RandomExpressionDataMatrixUtils.setSeed( 123L ); } - @Test - public void testFind() { - ArrayDesign ad = new ArrayDesign(); - ad.setId( 1L ); - QuantitationType qt = new QuantitationType(); - qt.setId( 1L ); - assertThat( processedExpressionDataVectorDao.find( ad, qt ) ).isEmpty(); - } - @Test @WithMockUser public void testCreateProcessedDataVectors() throws QuantitationMismatchException { @@ -177,6 +168,7 @@ public void testGetProcessedVectors() { vectors.add( vector ); } ee.setProcessedExpressionDataVectors( vectors ); + ee.setNumberOfDataVectors( vectors.size() ); session.persist( ee ); session.flush(); session.clear(); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/RawAndProcessedExpressionDataVectorDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/RawAndProcessedExpressionDataVectorDaoTest.java index 8e2fc221cc..1d2a0f30ff 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/RawAndProcessedExpressionDataVectorDaoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/bioAssayData/RawAndProcessedExpressionDataVectorDaoTest.java @@ -9,7 +9,6 @@ import org.springframework.context.annotation.Configuration; import org.springframework.test.context.ContextConfiguration; import ubic.gemma.core.util.test.BaseDatabaseTest; -import ubic.gemma.model.common.auditAndSecurity.AuditTrail; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.bioAssayData.BioAssayDimension; import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; @@ -21,7 +20,8 @@ import java.util.Collections; -import static org.junit.Assert.*; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNull; import static org.mockito.Mockito.*; @ContextConfiguration @@ -94,6 +94,7 @@ public void testRemoveByCompositeSequence() { pv.setExpressionExperiment( ee ); ee.setRawExpressionDataVectors( Collections.singleton( ev ) ); ee.setProcessedExpressionDataVectors( Collections.singleton( pv ) ); + ee.setNumberOfDataVectors( 1 ); sessionFactory.getCurrentSession().persist( ee ); assertEquals( 2, rawAndProcessedExpressionDataVectorDao.findByExpressionExperiment( ee ).size() ); assertEquals( 2, rawAndProcessedExpressionDataVectorDao.removeByCompositeSequence( cs ) ); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoTest.java index b16b40e92c..9fcc9181bf 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExperimentalFactorDaoTest.java @@ -28,7 +28,6 @@ static class ExperimentalFactorServiceTestContextConfiguration extends BaseDatab public ExperimentalFactorDao experimentalFactorDao( SessionFactory sessionFactory ) { return new ExperimentalFactorDaoImpl( sessionFactory ); } - } @Autowired diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoTest.java index 38ba47506b..db387a4607 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/service/expression/experiment/ExpressionExperimentDaoTest.java @@ -16,11 +16,14 @@ import org.springframework.test.context.TestExecutionListeners; import ubic.gemma.core.util.test.BaseDatabaseTest; import ubic.gemma.model.common.description.Characteristic; +import ubic.gemma.model.common.quantitationtype.*; import ubic.gemma.model.expression.arrayDesign.ArrayDesign; import ubic.gemma.model.expression.bioAssay.BioAssay; +import ubic.gemma.model.expression.bioAssayData.BioAssayDimension; import ubic.gemma.model.expression.bioAssayData.ProcessedExpressionDataVector; import ubic.gemma.model.expression.bioAssayData.RawExpressionDataVector; import ubic.gemma.model.expression.biomaterial.BioMaterial; +import ubic.gemma.model.expression.designElement.CompositeSequence; import ubic.gemma.model.expression.experiment.ExperimentalDesign; import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.model.genome.Taxon; @@ -73,8 +76,10 @@ public void testThawTransientEntity() { ba.setSampleUsed( new BioMaterial() ); ba.setArrayDesignUsed( new ArrayDesign() ); ee.setBioAssays( Collections.singleton( ba ) ); + ee.setNumberOfSamples( 1 ); ee.setRawExpressionDataVectors( Collections.singleton( new RawExpressionDataVector() ) ); ee.setProcessedExpressionDataVectors( Collections.singleton( new ProcessedExpressionDataVector() ) ); + ee.setNumberOfDataVectors( 1 ); expressionExperimentDao.thaw( ee ); expressionExperimentDao.thawBioAssays( ee ); expressionExperimentDao.thawWithoutVectors( ee ); @@ -386,6 +391,65 @@ public void testRemoveExperimentWithSharedBioMaterial() { assertTrue( bm.getBioAssaysUsedIn().contains( ba2 ) ); } + @Test + public void removeWithBioAssayDimension() { + Taxon taxon = new Taxon(); + sessionFactory.getCurrentSession().persist( taxon ); + ArrayDesign arrayDesign = new ArrayDesign(); + arrayDesign.setPrimaryTaxon( taxon ); + CompositeSequence cs1 = CompositeSequence.Factory.newInstance( "test", arrayDesign ); + arrayDesign.getCompositeSequences().add( cs1 ); + sessionFactory.getCurrentSession().persist( arrayDesign ); + BioMaterial bm = new BioMaterial(); + bm.setSourceTaxon( taxon ); + sessionFactory.getCurrentSession().persist( bm ); + BioAssay ba1 = new BioAssay(); + ba1.setArrayDesignUsed( arrayDesign ); + ba1.setSampleUsed( bm ); + bm.getBioAssaysUsedIn().add( ba1 ); + ExpressionExperiment ee1 = new ExpressionExperiment(); + ee1.getBioAssays().add( ba1 ); + // create quantitations + QuantitationType qt = new QuantitationType(); + qt.setGeneralType( GeneralType.QUANTITATIVE ); + qt.setType( StandardQuantitationType.AMOUNT ); + qt.setRepresentation( PrimitiveType.DOUBLE ); + qt.setScale( ScaleType.COUNT ); + ee1.getQuantitationTypes().add( qt ); + BioAssayDimension bad = new BioAssayDimension(); + bad.getBioAssays().add( ba1 ); + sessionFactory.getCurrentSession().persist( bad ); + RawExpressionDataVector vector = new RawExpressionDataVector(); + vector.setExpressionExperiment( ee1 ); + vector.setDesignElement( cs1 ); + vector.setQuantitationType( qt ); + vector.setBioAssayDimension( bad ); + vector.setData( new byte[0] ); + ee1.getRawExpressionDataVectors().add( vector ); + sessionFactory.getCurrentSession().persist( ee1 ); + + ee1 = reload( ee1 ); + expressionExperimentDao.remove( ee1 ); + sessionFactory.getCurrentSession().flush(); + assertNull( sessionFactory.getCurrentSession().get( BioAssayDimension.class, bad.getId() ) ); + } + + @Test + public void testGetAllAnnotations() { + ExpressionExperiment ee = new ExpressionExperiment(); + sessionFactory.getCurrentSession().persist( ee ); + expressionExperimentDao.getAllAnnotations( ee ); + } + + @Test + public void testGetAnnotationsByLevel() { + ExpressionExperiment ee = new ExpressionExperiment(); + sessionFactory.getCurrentSession().persist( ee ); + expressionExperimentDao.getExperimentAnnotations( ee ); + expressionExperimentDao.getBioMaterialAnnotations( ee ); + expressionExperimentDao.getExperimentalDesignAnnotations( ee ); + } + private ExpressionExperiment reload( ExpressionExperiment e ) { sessionFactory.getCurrentSession().flush(); sessionFactory.getCurrentSession().evict( e ); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/util/AsyncSingletonFactoryTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/util/AsyncSingletonFactoryTest.java index c0f975e1bd..ac030118ef 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/util/AsyncSingletonFactoryTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/util/AsyncSingletonFactoryTest.java @@ -68,7 +68,7 @@ public void testGetBeanAndGetBeanAsync() throws Exception { public void testGetBeanThenCancel() throws Exception { MyServiceFactory factory = beanFactory.getBean( MyServiceFactory.class ); Future> myServiceFuture = Executors.newSingleThreadExecutor().submit( factory::getObject ); - Thread.sleep( 10 ); + Thread.sleep( 20 ); Assert.assertTrue( factory.isInitialized() ); Assert.assertTrue( myServiceFuture.isDone() ); Assert.assertFalse( myServiceFuture.get().isDone() ); diff --git a/gemma-core/src/test/java/ubic/gemma/persistence/util/SettingsConfigTest.java b/gemma-core/src/test/java/ubic/gemma/persistence/util/SettingsConfigTest.java index 79d7fa28d9..fa4a42dfb3 100644 --- a/gemma-core/src/test/java/ubic/gemma/persistence/util/SettingsConfigTest.java +++ b/gemma-core/src/test/java/ubic/gemma/persistence/util/SettingsConfigTest.java @@ -18,7 +18,7 @@ import static org.assertj.core.api.Assertions.assertThat; import static org.junit.Assert.*; -@ActiveProfiles(SpringProfiles.TEST) +@ActiveProfiles(EnvironmentProfiles.TEST) @ContextConfiguration public class SettingsConfigTest extends AbstractJUnit4SpringContextTests { diff --git a/gemma-core/src/test/resources/sql/init-entities.sql b/gemma-core/src/test/resources/sql/h2/init-entities.sql similarity index 94% rename from gemma-core/src/test/resources/sql/init-entities.sql rename to gemma-core/src/test/resources/sql/h2/init-entities.sql index d7e6abc6cd..fb4ff2c786 100644 --- a/gemma-core/src/test/resources/sql/init-entities.sql +++ b/gemma-core/src/test/resources/sql/h2/init-entities.sql @@ -11,7 +11,6 @@ insert into CONTACT (ID, class, NAME, DESCRIPTION, EMAIL, LAST_NAME, USER_NAME, values (1, 'User', 'admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -- denormalized table joining genes and compositeSequences; maintained by TableMaintenanceUtil. -drop table if exists GENE2CS; create table GENE2CS ( GENE BIGINT not null, @@ -26,7 +25,8 @@ alter table GENE2CS alter table GENE2CS add constraint GENE2CS_GENE_FKC foreign key (GENE) references CHROMOSOME_FEATURE (ID) on update cascade on delete cascade; -drop table if exists EXPRESSION_EXPERIMENT2CHARACTERISTIC; +-- this table is created in the hibernate schema +drop table EXPRESSION_EXPERIMENT2CHARACTERISTIC; create table EXPRESSION_EXPERIMENT2CHARACTERISTIC ( ID bigint, @@ -41,7 +41,7 @@ create table EXPRESSION_EXPERIMENT2CHARACTERISTIC EXPRESSION_EXPERIMENT_FK bigint, ACL_IS_AUTHENTICATED_ANONYMOUSLY_MASK int not null default 0, LEVEL varchar(255), - primary key (ID, EXPRESSION_EXPERIMENT_FK, LEVEL) + primary key (ID, EXPRESSION_EXPERIMENT_FK) ); alter table EXPRESSION_EXPERIMENT2CHARACTERISTIC @@ -55,7 +55,6 @@ create index EE2C_VALUE_URI_VALUE on EXPRESSION_EXPERIMENT2CHARACTERISTIC (VALUE create index EE2C_CATEGORY_URI_CATEGORY_VALUE_URI_VALUE on EXPRESSION_EXPERIMENT2CHARACTERISTIC (CATEGORY_URI, CATEGORY, VALUE_URI, `VALUE`); create index EE2C_LEVEL on EXPRESSION_EXPERIMENT2CHARACTERISTIC (LEVEL); -drop table if exists EXPRESSION_EXPERIMENT2ARRAY_DESIGN; create table EXPRESSION_EXPERIMENT2ARRAY_DESIGN ( EXPRESSION_EXPERIMENT_FK bigint not null, diff --git a/gemma-core/src/test/resources/sql/init-indices.sql b/gemma-core/src/test/resources/sql/h2/init-indices.sql similarity index 100% rename from gemma-core/src/test/resources/sql/init-indices.sql rename to gemma-core/src/test/resources/sql/h2/init-indices.sql diff --git a/gemma-core/src/test/resources/ubic/gemma/core/ontology/OntologyLoadingTest-context.xml b/gemma-core/src/test/resources/ubic/gemma/core/ontology/OntologyLoadingTest-context.xml index e68339e0a5..5c1137998a 100644 --- a/gemma-core/src/test/resources/ubic/gemma/core/ontology/OntologyLoadingTest-context.xml +++ b/gemma-core/src/test/resources/ubic/gemma/core/ontology/OntologyLoadingTest-context.xml @@ -2,6 +2,7 @@ + diff --git a/gemma-groovy-support/pom.xml b/gemma-groovy-support/pom.xml index 5cdda87b09..7be89bd33e 100644 --- a/gemma-groovy-support/pom.xml +++ b/gemma-groovy-support/pom.xml @@ -6,7 +6,7 @@ gemma gemma - 1.31.1 + 1.31.2 gemma-groovy-support diff --git a/gemma-groovy-support/src/main/groovy/ubic/gemma/groovy/framework/SpringSupport.groovy b/gemma-groovy-support/src/main/groovy/ubic/gemma/groovy/framework/SpringSupport.groovy index ff803f3b2c..59b831c5fb 100644 --- a/gemma-groovy-support/src/main/groovy/ubic/gemma/groovy/framework/SpringSupport.groovy +++ b/gemma-groovy-support/src/main/groovy/ubic/gemma/groovy/framework/SpringSupport.groovy @@ -5,7 +5,7 @@ import org.springframework.context.ApplicationContext import org.springframework.context.ConfigurableApplicationContext import org.springframework.security.core.context.SecurityContextHolder import ubic.gemma.persistence.util.SpringContextUtil -import ubic.gemma.persistence.util.SpringProfiles +import ubic.gemma.persistence.util.EnvironmentProfiles /** * Class for creation of a spring context. Example usage: @@ -25,9 +25,9 @@ class SpringSupport { /** * Available profiles for initializing a new {@link SpringSupport}. */ - public static final String PRODUCTION = SpringProfiles.PRODUCTION, - DEV = SpringProfiles.DEV, - TEST = SpringProfiles.TEST; + public static final String PRODUCTION = EnvironmentProfiles.PRODUCTION, + DEV = EnvironmentProfiles.DEV, + TEST = EnvironmentProfiles.TEST; private final ApplicationContext ctx diff --git a/gemma-rest/pom.xml b/gemma-rest/pom.xml index 8cfd126058..6a4cf4e2a0 100644 --- a/gemma-rest/pom.xml +++ b/gemma-rest/pom.xml @@ -5,7 +5,7 @@ gemma gemma - 1.31.1 + 1.31.2 4.0.0 diff --git a/gemma-rest/src/main/java/ubic/gemma/rest/DatasetsWebService.java b/gemma-rest/src/main/java/ubic/gemma/rest/DatasetsWebService.java index 5ccf907947..6cbc923844 100644 --- a/gemma-rest/src/main/java/ubic/gemma/rest/DatasetsWebService.java +++ b/gemma-rest/src/main/java/ubic/gemma/rest/DatasetsWebService.java @@ -122,6 +122,8 @@ public class DatasetsWebService { private DatasetArgService datasetArgService; @Autowired private GeneArgService geneArgService; + @Autowired + private QuantitationTypeArgService quantitationTypeArgService; @Autowired private HttpServletRequest request; @@ -750,19 +752,15 @@ public Response getDatasetExpression( // Params: content = @Content(mediaType = MediaType.APPLICATION_JSON, schema = @Schema(implementation = ResponseErrorObject.class))) }) public Response getDatasetProcessedExpression( @PathParam("dataset") DatasetArg datasetArg ) { ExpressionExperiment ee = datasetArgService.getEntity( datasetArg ); - QuantitationType qt = expressionExperimentService.getMaskedPreferredQuantitationType( ee ); - if ( qt == null ) { + if ( !expressionExperimentService.hasProcessedExpressionData( ee ) ) { throw new NotFoundException( String.format( "No preferred quantitation type could be for found processed expression data data of %s.", ee ) ); } - StreamingOutput stream = ( output ) -> expressionDataFileService.writeProcessedExpressionData( ee, qt, new OutputStreamWriter( output ) ); + StreamingOutput stream = ( output ) -> expressionDataFileService.writeProcessedExpressionData( ee, new OutputStreamWriter( output ) ); return Response.ok( stream ) .header( "Content-Disposition", String.format( "attachment; filename=%d_%s_expmat.unfilt.data.txt", ee.getId(), ee.getShortName() ) ) .build(); } - @Autowired - private QuantitationTypeArgService quantitationTypeArgService; - /** * Retrieve raw expression data. *

@@ -998,7 +996,7 @@ public ResponseDataObject> getDatase private Response outputDataFile( ExpressionExperiment ee, boolean filter ) throws FilteringException, IOException { ee = expressionExperimentService.thawLite( ee ); - File file = expressionDataFileService.writeOrLocateDataFile( ee, false, filter ); + File file = expressionDataFileService.writeOrLocateProcessedDataFile( ee, false, filter ).orElse( null ); return this.outputFile( file, DatasetsWebService.ERROR_DATA_FILE_NOT_AVAILABLE, ee.getShortName() ); } @@ -1008,7 +1006,7 @@ private Response outputDesignFile( ExpressionExperiment ee ) throws IOException return this.outputFile( file, DatasetsWebService.ERROR_DESIGN_FILE_NOT_AVAILABLE, ee.getShortName() ); } - private Response outputFile( File file, String error, String shortName ) throws IOException { + private Response outputFile( @Nullable File file, String error, String shortName ) throws IOException { if ( file == null || !file.exists() ) { throw new NotFoundException( String.format( error, shortName ) ); } diff --git a/gemma-rest/src/main/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4Provider.java b/gemma-rest/src/main/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4Provider.java index ad387e1e98..b88c3ac192 100644 --- a/gemma-rest/src/main/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4Provider.java +++ b/gemma-rest/src/main/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4Provider.java @@ -63,7 +63,7 @@ public class GoogleAnalytics4Provider implements AnalyticsProvider, Initializing debugEndpoint = "https://www.google-analytics.com/debug/mp/collect?api_secret={apiSecret}&measurement_id={measurementId}"; private final RestTemplate restTemplate; - private final ScheduledExecutorService taskExecutor; + private final ScheduledExecutorService taskExecutor = Executors.newSingleThreadScheduledExecutor(); private final String measurementId; private final String apiSecret; private long resolutionMillis = DEFAULT_RESOLUTION_MILLIS; @@ -82,23 +82,21 @@ public class GoogleAnalytics4Provider implements AnalyticsProvider, Initializing * Create a new Google Analytics 4 provider. * * @param restTemplate a REST template for performing requests with the collect API - * @param taskExecutor a task executor for running scheduled flush tasks * @param measurementId a measurement ID which may be empty * @param apiSecret an API secret, must be non-empty if measurementId is supplied */ - public GoogleAnalytics4Provider( RestTemplate restTemplate, ScheduledExecutorService taskExecutor, String measurementId, String apiSecret ) { + public GoogleAnalytics4Provider( RestTemplate restTemplate, String measurementId, String apiSecret ) { Assert.isTrue( StringUtils.isBlank( measurementId ) || !StringUtils.isBlank( apiSecret ) ); this.restTemplate = restTemplate; - this.taskExecutor = taskExecutor; this.measurementId = measurementId; this.apiSecret = apiSecret; } /** - * @see #GoogleAnalytics4Provider(RestTemplate, ScheduledExecutorService, String, String) + * @see #GoogleAnalytics4Provider(RestTemplate, String, String) */ public GoogleAnalytics4Provider( String measurementId, String apiSecret ) { - this( new RestTemplate(), new ScheduledThreadPoolExecutor( 1 ), measurementId, apiSecret ); + this( new RestTemplate(), measurementId, apiSecret ); } diff --git a/gemma-rest/src/main/resources/restapidocs/index.jsp b/gemma-rest/src/main/resources/restapidocs/index.jsp index 45aa3d8b0b..07ecd4d01a 100644 --- a/gemma-rest/src/main/resources/restapidocs/index.jsp +++ b/gemma-rest/src/main/resources/restapidocs/index.jsp @@ -10,10 +10,10 @@

diff --git a/gemma-rest/src/test/java/ubic/gemma/rest/DatasetsWebServiceTest.java b/gemma-rest/src/test/java/ubic/gemma/rest/DatasetsWebServiceTest.java index eb6734077a..b160160c72 100644 --- a/gemma-rest/src/test/java/ubic/gemma/rest/DatasetsWebServiceTest.java +++ b/gemma-rest/src/test/java/ubic/gemma/rest/DatasetsWebServiceTest.java @@ -373,15 +373,25 @@ public void testGetDatasetQuantitationTypes() { @Test public void testGetDatasetProcessedExpression() throws IOException { - QuantitationType qt = QuantitationType.Factory.newInstance(); - when( expressionExperimentService.getMaskedPreferredQuantitationType( ee ) ) - .thenReturn( qt ); + when( expressionExperimentService.hasProcessedExpressionData( eq( ee ) ) ).thenReturn( true ); assertThat( target( "/datasets/1/data/processed" ).request().get() ) .hasStatus( Response.Status.OK ) .hasMediaTypeCompatibleWith( MediaType.APPLICATION_JSON_TYPE ) .hasEncoding( "gzip" ); - verify( expressionExperimentService ).getMaskedPreferredQuantitationType( ee ); - verify( expressionDataFileService ).writeProcessedExpressionData( eq( ee ), eq( qt ), any() ); + verify( expressionExperimentService ).hasProcessedExpressionData( eq( ee ) ); + verify( expressionDataFileService ).writeProcessedExpressionData( eq( ee ), any() ); + } + + @Test + public void testGetDatasetProcessedExpressionWhenNoProcessedVectorsExist() throws IOException { + when( expressionExperimentService.hasProcessedExpressionData( eq( ee ) ) ).thenReturn( false ); + assertThat( target( "/datasets/1/data/processed" ).request().get() ) + .hasStatus( Response.Status.NOT_FOUND ) + .hasMediaTypeCompatibleWith( MediaType.APPLICATION_JSON_TYPE ); + verify( expressionExperimentService ).load( 1L ); + verify( expressionExperimentService ).hasProcessedExpressionData( eq( ee ) ); + verifyNoMoreInteractions( expressionExperimentService ); + verifyNoInteractions( expressionDataFileService ); } @Test diff --git a/gemma-rest/src/test/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4ProviderTest.java b/gemma-rest/src/test/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4ProviderTest.java index 1ef73ca490..868ab6c844 100644 --- a/gemma-rest/src/test/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4ProviderTest.java +++ b/gemma-rest/src/test/java/ubic/gemma/rest/analytics/ga4/GoogleAnalytics4ProviderTest.java @@ -15,7 +15,10 @@ import java.util.ArrayList; import java.util.Collection; import java.util.Date; -import java.util.concurrent.*; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.concurrent.Future; +import java.util.concurrent.TimeUnit; import static org.assertj.core.api.Assertions.assertThatThrownBy; import static ubic.gemma.rest.util.Assertions.assertThat; @@ -32,7 +35,7 @@ public void setUp() { log.info( String.format( "\nURL: %s\nPayload: %s", request.getURI(), new String( body, StandardCharsets.UTF_8 ) ) ); return execution.execute( request, body ); } ); - provider = new GoogleAnalytics4Provider( restTemplate, new ScheduledThreadPoolExecutor( 1 ), "test", "test" ); + provider = new GoogleAnalytics4Provider( restTemplate, "test", "test" ); provider.afterPropertiesSet(); provider.setDebug( true ); ThreadLocal clientId = ThreadLocal.withInitial( () -> RandomStringUtils.randomNumeric( 10 ) + "." + RandomStringUtils.randomNumeric( 10 ) ); diff --git a/gemma-rest/src/test/java/ubic/gemma/rest/util/BaseJerseyTest.java b/gemma-rest/src/test/java/ubic/gemma/rest/util/BaseJerseyTest.java index 60cd2c0230..1e3ede1f8e 100644 --- a/gemma-rest/src/test/java/ubic/gemma/rest/util/BaseJerseyTest.java +++ b/gemma-rest/src/test/java/ubic/gemma/rest/util/BaseJerseyTest.java @@ -18,7 +18,7 @@ import org.springframework.test.context.web.WebAppConfiguration; import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.support.GenericWebApplicationContext; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; import javax.ws.rs.core.Application; @@ -27,7 +27,7 @@ * Spring components. * @author poirigui */ -@ActiveProfiles({ "web", SpringProfiles.TEST }) +@ActiveProfiles({ "web", EnvironmentProfiles.TEST }) @RunWith(SpringJUnit4ClassRunner.class) @WebAppConfiguration public abstract class BaseJerseyTest extends JerseyTest implements InitializingBean { diff --git a/gemma-web/pom.xml b/gemma-web/pom.xml index 3782c721b2..c04e695de2 100644 --- a/gemma-web/pom.xml +++ b/gemma-web/pom.xml @@ -3,7 +3,7 @@ gemma gemma - 1.31.1 + 1.31.2 4.0.0 gemma-web @@ -13,6 +13,9 @@ Gemma + + ${project.basedir}/src/test/resources + WEB-INF ${project.basedir}/src/main/webapp/WEB-INF diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/common/description/bibref/BibliographicReferenceControllerImpl.java b/gemma-web/src/main/java/ubic/gemma/web/controller/common/description/bibref/BibliographicReferenceControllerImpl.java index 28d4b10095..c8e9fb0f39 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/common/description/bibref/BibliographicReferenceControllerImpl.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/common/description/bibref/BibliographicReferenceControllerImpl.java @@ -249,14 +249,9 @@ public ModelAndView showAllForExperiments( HttpServletRequest request, HttpServl } CitationValueObject cvo = CitationValueObject.convert2CitationValueObject( entry.getValue() ); if ( !citationToEEs.containsKey( cvo ) ) { - citationToEEs.put( cvo, new ArrayList() ); + citationToEEs.put( cvo, new ArrayList<>() ); } - ExpressionExperiment ee = entry.getKey(); - ee.setBioAssays( null ); - ee.setAccession( null ); - ee.setExperimentalDesign( null ); - citationToEEs.get( cvo ).add( new ExpressionExperimentValueObject( ee ) ); - + citationToEEs.get( cvo ).add( new ExpressionExperimentValueObject( entry.getKey(), true, true ) ); } return new ModelAndView( "bibRefAllExperiments" ).addObject( "citationToEEs", citationToEEs ); diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/arrayDesign/ArrayDesignControllerImpl.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/arrayDesign/ArrayDesignControllerImpl.java index 3ac611f0c6..f3a11edaa7 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/arrayDesign/ArrayDesignControllerImpl.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/arrayDesign/ArrayDesignControllerImpl.java @@ -320,7 +320,6 @@ public Collection getDesignSummaries( ArrayDesi public ArrayDesignValueObjectExt getDetails( Long id ) { ArrayDesign arrayDesign = this.getADSafely( id ); - log.info( "Loading details of " + arrayDesign ); ArrayDesignValueObject vo = arrayDesignService.loadValueObject( arrayDesign ); if ( vo == null ) { @@ -343,7 +342,6 @@ public ArrayDesignValueObjectExt getDetails( Long id ) { if ( result.getIsAffymetrixAltCdf() ) result.setAlternative( new ArrayDesignValueObject( arrayDesign.getAlternativeTo() ) ); - log.info( "Finished loading details of " + arrayDesign ); return result; } diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DEDVController.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DEDVController.java index 1fa4d27219..ccf62ba1cc 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DEDVController.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DEDVController.java @@ -47,6 +47,7 @@ import ubic.gemma.persistence.service.analysis.expression.diff.DifferentialExpressionResultService; import ubic.gemma.persistence.service.expression.bioAssayData.ProcessedExpressionDataVectorService; import ubic.gemma.persistence.service.expression.designElement.CompositeSequenceService; +import ubic.gemma.persistence.service.expression.experiment.ExperimentalFactorService; import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentService; import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentSubSetService; import ubic.gemma.persistence.util.EntityUtils; @@ -54,6 +55,7 @@ import ubic.gemma.web.controller.visualization.VisualizationValueObject; import ubic.gemma.web.view.TextView; +import javax.annotation.Nullable; import javax.servlet.http.HttpServletRequest; import java.util.*; import java.util.Map.Entry; @@ -89,6 +91,8 @@ public class DEDVController { private ProcessedExpressionDataVectorService processedExpressionDataVectorService; @Autowired private SVDService svdService; + @Autowired + private ExperimentalFactorService experimentalFactorService; /** * Assign colour lists (queues actually) to factors. The idea is that every factor value will get a colour assigned @@ -402,10 +406,12 @@ public VisualizationValueObject[] getDEDVForDiffExVisualizationByExperiment( Lon * * @param resultSetId The resultset we're specifically interested. Note that this is what is used to choose the * vectors, since it could be a subset of an experiment. + * @param givenThreshold + * @param primaryFactorID If non-null, the factor to use for sorting the samples before other factors are considered * @return collection of visualization value objects */ public VisualizationValueObject[] getDEDVForDiffExVisualizationByThreshold( Long resultSetId, - Double givenThreshold ) { + Double givenThreshold, @Nullable Long primaryFactorID ) { if ( resultSetId == null ) { throw new IllegalArgumentException( "The resultSetId parameter cannot be null" ); @@ -422,8 +428,14 @@ public VisualizationValueObject[] getDEDVForDiffExVisualizationByThreshold( Long .getDiffExVectors( resultSetId, threshold, MAX_RESULTS_TO_RETURN ); // at this point the dedvs are reduced down to the subset we need to visualize + ExperimentalFactor primaryFactor = this.experimentalFactorService.load( primaryFactorID ); + + if ( primaryFactor == null ) { + throw new IllegalArgumentException( "No factor found for id=" + primaryFactorID ); + } + Map>> layouts = experimentalDesignVisualizationService - .sortVectorDataByDesign( dedvs ); + .sortVectorDataByDesign( dedvs, primaryFactor ); return makeVisCollection( dedvs, null, null, layouts ); } diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DesignMatrixRowValueObject.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DesignMatrixRowValueObject.java index ac9ab0d69b..de52a3c529 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DesignMatrixRowValueObject.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/DesignMatrixRowValueObject.java @@ -23,10 +23,7 @@ import ubic.gemma.core.analysis.preprocess.batcheffects.BatchInfoPopulationServiceImpl; import ubic.gemma.model.expression.bioAssay.BioAssay; import ubic.gemma.model.expression.biomaterial.BioMaterial; -import ubic.gemma.model.expression.experiment.ExperimentalFactor; -import ubic.gemma.model.expression.experiment.ExpressionExperiment; -import ubic.gemma.model.expression.experiment.FactorValue; -import ubic.gemma.model.expression.experiment.FactorValueUtils; +import ubic.gemma.model.expression.experiment.*; import ubic.gemma.persistence.util.FactorValueVector; import java.io.Serializable; @@ -148,17 +145,20 @@ public static final class Factory { /** * @param expressionExperiment ee * @param removeBatchFactor if true, any factor(s) that look like "batch information" will be ignored. + * @param removeContinuous if true, any factor(s) that are continuous will be ignored. If you don't set this to true, you will get a row for each assay. * @return collection */ public static Collection getDesignMatrix( ExpressionExperiment expressionExperiment, - boolean removeBatchFactor ) { + boolean removeBatchFactor, boolean removeContinuous ) { Collection factors = expressionExperiment.getExperimentalDesign() .getExperimentalFactors(); for ( Iterator iterator = factors.iterator(); iterator.hasNext(); ) { ExperimentalFactor experimentalFactor = iterator.next(); - if ( BatchInfoPopulationServiceImpl.isBatchFactor( experimentalFactor ) ) { + if ( removeBatchFactor && BatchInfoPopulationServiceImpl.isBatchFactor( experimentalFactor ) ) { + iterator.remove(); + } else if ( removeContinuous && experimentalFactor.getType().equals( FactorType.CONTINUOUS ) ) { iterator.remove(); } } diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExperimentalDesignController.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExperimentalDesignController.java index ccc6316eb9..d7d59648ad 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExperimentalDesignController.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExperimentalDesignController.java @@ -218,8 +218,10 @@ public void createExperimentalFactor( EntityDelegator e, Exp fv.setExperimentalFactor( ef ); Statement s = Statement.Factory.newInstance(); - s.setCategory( ef.getCategory().getCategory() ); - s.setCategoryUri( ef.getCategory().getCategoryUri() ); + if ( ef.getCategory() != null ) { + s.setCategory( ef.getCategory().getCategory() ); + s.setCategoryUri( ef.getCategory().getCategoryUri() ); + } s.setSubject( cvo.getValue() ); s.setSubjectUri( cvo.getValueUri() ); // can be null fv.getCharacteristics().add( s ); diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentController.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentController.java index dd0235362f..f253745fb5 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentController.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentController.java @@ -27,6 +27,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.i18n.LocaleContextHolder; import org.springframework.security.access.AccessDeniedException; +import org.springframework.security.access.annotation.Secured; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; @@ -233,6 +234,7 @@ public void clearFromCaches( Long eeId ) { /** * Exposed for AJAX calls. */ + @Secured("GROUP_USER") public String deleteById( Long id ) { if ( id == null ) return null; RemoveExpressionExperimentTask task = new RemoveExpressionExperimentTask( new TaskCommand( id ) ); @@ -381,7 +383,7 @@ public Collection getDesignMatrixRows( EntityDelegat throw new IllegalArgumentException( "A non-null experiment ID must be supplied." ); } ExpressionExperiment ee = getExperimentById( e.getId(), true ); - return DesignMatrixRowValueObject.Factory.getDesignMatrix( ee, true ); // ignore "batch" + return DesignMatrixRowValueObject.Factory.getDesignMatrix( ee, true, true ); // ignore "batch" and continuous. } /** @@ -790,6 +792,7 @@ public Collection loadStatusSummaries( L * @return string */ @SuppressWarnings("UnusedReturnValue") // AJAX method - Possibly used in JS + @Secured("GROUP_USER") public String removePrimaryPublication( Long eeId ) { RemovePubMed task = new RemovePubMed( new TaskCommand( eeId ) ); return taskRunningService.submitTask( task ); @@ -1058,6 +1061,7 @@ public ExpressionExperimentDetailsValueObject updateBasics( UpdateEEDetailsComma * @return string */ @SuppressWarnings("UnusedReturnValue") // AJAX method - possibly used in JS + @Secured("GROUP_USER") public String updatePubMed( Long eeId, String pubmedId ) { UpdatePubMedCommand command = new UpdatePubMedCommand( eeId ); command.setPubmedId( pubmedId ); @@ -1536,7 +1540,7 @@ private List returnNeedsAttention( Colle private void updateCorrelationMatrixFile( Long id ) { ExpressionExperiment ee = getExperimentById( id, true ); try { - sampleCoexpressionAnalysisService.compute( ee ); + sampleCoexpressionAnalysisService.compute( ee, sampleCoexpressionAnalysisService.prepare( ee ) ); } catch ( Exception e ) { auditTrailService.addUpdateEvent( ee, FailedSampleCorrelationAnalysisEvent.class, null, e ); throw e; diff --git a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentDataFetchController.java b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentDataFetchController.java index e1d63dca5d..4830d8fd2f 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentDataFetchController.java +++ b/gemma-web/src/main/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentDataFetchController.java @@ -250,7 +250,8 @@ public TaskResult call() { "No data available (either due to lack of authorization, or use of an invalid entity identifier)" ); } - File f = expressionDataFileService.writeOrLocateCoexpressionDataFile( ee, false ); + File f = expressionDataFileService.writeOrLocateCoexpressionDataFile( ee, false ) + .orElseThrow( () -> new IllegalStateException( "There is no coexpression data for " + ee ) ); watch.stop(); log.debug( "Finished getting co-expression file; done in " + watch.getTime() + " milliseconds" ); @@ -347,11 +348,11 @@ public TaskResult call() { else { if ( qType != null ) { log.debug( "Using quantitation type to create matrix." ); - f = expressionDataFileService.writeOrLocateDataFile( qType, false ); + f = expressionDataFileService.writeOrLocateRawExpressionDataFile( ee, qType, false ); } else { try { - f = expressionDataFileService.writeOrLocateDataFile( ee, false, filtered ); + f = expressionDataFileService.writeOrLocateProcessedDataFile( ee, false, filtered ).orElse( null ); } catch ( FilteringException e ) { throw new IllegalStateException( "The expression experiment data matrix could not be filtered for " + ee + ".", e ); } @@ -364,10 +365,10 @@ public TaskResult call() { else if ( usedFormat.equals( "json" ) ) { if ( qType != null ) { - f = expressionDataFileService.writeOrLocateJSONDataFile( qType, false ); + f = expressionDataFileService.writeOrLocateJSONRawExpressionDataFile( ee, qType, false ); } else { try { - f = expressionDataFileService.writeOrLocateJSONDataFile( ee, false, filtered ); + f = expressionDataFileService.writeOrLocateJSONProcessedExpressionDataFile( ee, false, filtered ).orElse( null ); } catch ( FilteringException e ) { throw new IllegalStateException( "The expression experiment data matrix could not be filtered for " + ee + ".", e ); } diff --git a/gemma-web/src/main/java/ubic/gemma/web/listener/StartupListener.java b/gemma-web/src/main/java/ubic/gemma/web/listener/StartupListener.java index 0f49e3571f..3711983d58 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/listener/StartupListener.java +++ b/gemma-web/src/main/java/ubic/gemma/web/listener/StartupListener.java @@ -29,7 +29,7 @@ import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.support.WebApplicationContextUtils; import ubic.gemma.persistence.util.Settings; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; import ubic.gemma.web.util.Constants; import javax.servlet.ServletContext; @@ -133,11 +133,11 @@ private void lintConfiguration() { private static final String JAWR_DEBUG_ON_SYSTEM_PROPERTY = "net.jawr.debug.on"; /** - * Set the net.jawr.debug.on system property to true if the current profile is {@link SpringProfiles#DEV} and no + * Set the net.jawr.debug.on system property to true if the current profile is {@link EnvironmentProfiles#DEV} and no * value has been explicitly set by the user. */ private void configureJawr( ApplicationContext ctx ) { - if ( ctx.getEnvironment().acceptsProfiles( SpringProfiles.DEV ) + if ( ctx.getEnvironment().acceptsProfiles( EnvironmentProfiles.DEV ) && System.getProperty( JAWR_DEBUG_ON_SYSTEM_PROPERTY ) == null ) { log.info( String.format( "Enabling debug mode for JAWR by setting %s=true.", JAWR_DEBUG_ON_SYSTEM_PROPERTY ) ); System.setProperty( JAWR_DEBUG_ON_SYSTEM_PROPERTY, "true" ); diff --git a/gemma-web/src/main/java/ubic/gemma/web/taglib/expression/experiment/ExperimentQCTag.java b/gemma-web/src/main/java/ubic/gemma/web/taglib/expression/experiment/ExperimentQCTag.java index 1bdb9d4456..71b22c8464 100644 --- a/gemma-web/src/main/java/ubic/gemma/web/taglib/expression/experiment/ExperimentQCTag.java +++ b/gemma-web/src/main/java/ubic/gemma/web/taglib/expression/experiment/ExperimentQCTag.java @@ -67,7 +67,7 @@ public String getQChtml() { */ buf.append( "
" ); - buf.append( "" ); + buf.append( "
" ); buf.append( "" + "" diff --git a/gemma-web/src/main/resources/messages.properties b/gemma-web/src/main/resources/messages.properties index 9958733590..fd0e38bfe8 100644 --- a/gemma-web/src/main/resources/messages.properties +++ b/gemma-web/src/main/resources/messages.properties @@ -18,6 +18,8 @@ errorPage.heading=There was an error processing your request 415.title=Unsupported Media Type 403.title=Access Denied 403.message=You are not authorized to access this page. If you believe this is an error, please contact the webmaster. You might try returning to the home page. +501.title=Not Implemented +501.message=The page you requested is not implemented. You might try returning to the home page. 503.title=Service Unavailable 503.message=The page you requested is not available. You might try returning to the home page. diff --git a/gemma-web/src/main/resources/ubic/gemma/applicationContext-schedule.xml b/gemma-web/src/main/resources/ubic/gemma/applicationContext-schedule.xml index 429fe20470..094e1d6eb5 100644 --- a/gemma-web/src/main/resources/ubic/gemma/applicationContext-schedule.xml +++ b/gemma-web/src/main/resources/ubic/gemma/applicationContext-schedule.xml @@ -23,7 +23,9 @@ - + + + @@ -31,46 +33,128 @@ + + + + + + - + + + + + + + - + + + + + + + - + + + + + + + - + + + + + + + - + + + + + + + - + + + + ubic.gemma.model.expression.experiment.ExpressionExperiment + + + + + + + + + + + + + + + + + ubic.gemma.model.expression.biomaterial.BioMaterial + + + + + + + + + + + + + + + + + ubic.gemma.model.expression.experiment.ExperimentalDesign + + - + + @@ -98,45 +182,4 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/gemma-web/src/main/resources/ubic/gemma/applicationContext-security.xml b/gemma-web/src/main/resources/ubic/gemma/applicationContext-security.xml index 9cf2131686..a05ab4680f 100644 --- a/gemma-web/src/main/resources/ubic/gemma/applicationContext-security.xml +++ b/gemma-web/src/main/resources/ubic/gemma/applicationContext-security.xml @@ -64,6 +64,14 @@ + + + + + + + + diff --git a/gemma-web/src/main/webapp/common/meta.jsp b/gemma-web/src/main/webapp/common/meta.jsp index 0fe4de1642..7590c3c945 100644 --- a/gemma-web/src/main/webapp/common/meta.jsp +++ b/gemma-web/src/main/webapp/common/meta.jsp @@ -11,6 +11,8 @@ + + diff --git a/gemma-web/src/main/webapp/error.jsp b/gemma-web/src/main/webapp/error.jsp index f25709c7b2..66705e1df2 100644 --- a/gemma-web/src/main/webapp/error.jsp +++ b/gemma-web/src/main/webapp/error.jsp @@ -31,6 +31,9 @@ If you can, avoid producing error this way and prefer raising an exception that <%@ include file="/pages/error/500.jsp" %> + + <%@ include file="/pages/error/501.jsp" %> +

Unsupported Status Code

diff --git a/gemma-web/src/main/webapp/images/logo/ubc-logo-2018-crest-blue-rgb72.jpg b/gemma-web/src/main/webapp/images/logo/ubc-logo-2018-crest-blue-rgb72.jpg new file mode 100755 index 0000000000..790c68aafa Binary files /dev/null and b/gemma-web/src/main/webapp/images/logo/ubc-logo-2018-crest-blue-rgb72.jpg differ diff --git a/gemma-web/src/main/webapp/pages/error/501.jsp b/gemma-web/src/main/webapp/pages/error/501.jsp new file mode 100644 index 0000000000..3ac6ed5ef7 --- /dev/null +++ b/gemma-web/src/main/webapp/pages/error/501.jsp @@ -0,0 +1,15 @@ +<%@ include file="/common/taglibs.jsp" %> + +<fmt:message key="501.title"/> + +
+

+

+ + + + + +

+ <%@ include file="/common/exception.jsp" %> +
diff --git a/gemma-web/src/main/webapp/pages/frontPageSlideShowShowOff.jsp b/gemma-web/src/main/webapp/pages/frontPageSlideShowShowOff.jsp deleted file mode 100644 index a8e4fd5b4a..0000000000 --- a/gemma-web/src/main/webapp/pages/frontPageSlideShowShowOff.jsp +++ /dev/null @@ -1,50 +0,0 @@ -<%-- jshowoff.css is included in the bundle --%> -
-

- Database of curated and re-analyzed gene expression studies -

-
- -
-
- Gemma provides data, experimental design annotations, - and differential expression analysis results for thousands of microarray and RNA-seq experiments. - We re-analyze raw data from public sources (primarily NCBI GEO), - annotate experimental conditions, conduct quality control and compute differential expression using standardized procedures. - We have especially good coverage of experiments relevant to the nervous system. - See the documentation for more information. - Gemma was and developed and is maintained by the Pavlidis group - at UBC. -
- -
- <%-- Width here needs to be enough to fit the labels at left and right edges --%> - <%-- A pie chart representing proportion of taxa among Gemma datasets.--%> - Example of a dataset view - <%-- An overlay of a human on top of its section of the pie chart. - An overlay of a mouse on top of its section of the pie chart.--%> - - <%--
--%> -
-
-
-<%-- ---%> diff --git a/gemma-web/src/main/webapp/pages/home.jsp b/gemma-web/src/main/webapp/pages/home.jsp index dc06bde7de..e68914cba3 100755 --- a/gemma-web/src/main/webapp/pages/home.jsp +++ b/gemma-web/src/main/webapp/pages/home.jsp @@ -1,3 +1,4 @@ +<%--@elvariable id="appConfig" type="java.util.List"--%> <%@ include file="/common/taglibs.jsp" %> Home @@ -5,33 +6,7 @@ <%-- --%> - -<%@ include file="/pages/frontPageSlideShowShowOff.jsp" %> - -
- <%@ include file="/common/messages.jsp" %> -
- +<%-- jshowoff.css is included in the bundle --%> +
+

+ Database of curated and re-analyzed gene expression studies +

+
-
+
+
+
+ Gemma provides data, experimental design annotations, and differential expression analysis results for + thousands + of microarray and RNA-seq experiments. We re-analyze raw data from public sources (primarily NCBI GEO), + annotate experimental conditions, conduct quality control and compute differential expression using + standardized + procedures. We have especially good coverage of experiments relevant to the nervous system. See the documentation for more information. + Gemma was and developed and is maintained by the Pavlidis + group at UBC. +
-
-
- <%--
--%> + <%-- Width here needs to be enough to fit the labels at left and right edges --%> + <%-- A pie chart representing proportion of taxa among Gemma datasets.--%> +
+ Example of a dataset view overlaid with a heatmap of top differentially expressed probes. + <%-- An overlay of a human on top of its section of the pie chart. + An overlay of a mouse on top of its section of the pie chart.--%> + + <%--
--%> + +
+
+
+
+<%-- +--%> + +<%@ include file="/common/messages.jsp" %> + +
+
+
-
-
-

- Convenient programmatic access to Gemma's data and analyses is available via the - software packages gemma.R - (R/Bioconductor) + <%--

--%> +
+
+

+ Convenient programmatic access to Gemma's data and analyses is available via the software packages + gemma.R (R/Bioconductor) and gemmapy (Python).

- - Bioconductor Logo - - - PyPi Logo - +
-
-

- We invite you to try out the new Gemma +

+

+ We invite you to try out the new Gemma Browser, our new interface for exploring and searching Gemma's data holdings. It's still in beta, and more features and improvements are planned, but we'd love to hear your feedback.

- - + A screenshot of the new Gemma Browser. - -
-
-
-

Questions? Feel free to reach out.

-
- - +

Questions? Feel free to reach out.

- + \ No newline at end of file diff --git a/gemma-web/src/main/webapp/scripts/api/annotation/BioMaterialEditor.js b/gemma-web/src/main/webapp/scripts/api/annotation/BioMaterialEditor.js index abf3fe699b..20019fb8b9 100755 --- a/gemma-web/src/main/webapp/scripts/api/annotation/BioMaterialEditor.js +++ b/gemma-web/src/main/webapp/scripts/api/annotation/BioMaterialEditor.js @@ -39,7 +39,7 @@ Ext.extend( Gemma.BioMaterialEditor, Ext.Panel, { ExperimentalDesignController.getExperimentalFactors( this.expressionExperiment, function( factorData ) { config = { factors : factorData, - bioMaterials : data + bioMaterials : data // BM Value objects. }; Ext.apply( config, this.originalConfig ); @@ -63,6 +63,7 @@ Ext.extend( Gemma.BioMaterialEditor, Ext.Panel, { * @memberOf Gemma.BioMaterialEditor */ init : function() { + var loadMaskTarget = this.el !== null ? this.el : Ext.getBody(); this.loadMask = new Ext.LoadMask( loadMaskTarget, { @@ -216,6 +217,7 @@ Gemma.BioMaterialGrid = Ext.extend( Gemma.GemmaGridPanel, { continue; } + // column header columns.push( { id : "char" + category.hashCode(), header : category + " (raw characteristic)", @@ -223,7 +225,7 @@ Gemma.BioMaterialGrid = Ext.extend( Gemma.GemmaGridPanel, { dataIndex : "char" + category.hashCode(), width : 120, tooltip : category + ": A non-constant Biomaterial characteristic displayed for reference purposes.", - sortable : true + sortable : true, } ); } @@ -541,8 +543,9 @@ Gemma.BioMaterialGrid = Ext.extend( Gemma.GemmaGridPanel, { if ( !this.characteristics.hasOwnProperty( c ) ) { continue; } + var cval = bmvo.characteristicValues[c]; - if ( cval ) { + if ( cval ) { data[i].push( cval ); } else { data[i].push( "" ); // shouldn't happen if we picked useful characteristics well. diff --git a/gemma-web/src/main/webapp/scripts/api/dwrServices.js b/gemma-web/src/main/webapp/scripts/api/dwrServices.js index 3b2fda13b4..0778eb1ae4 100755 --- a/gemma-web/src/main/webapp/scripts/api/dwrServices.js +++ b/gemma-web/src/main/webapp/scripts/api/dwrServices.js @@ -7,440 +7,440 @@ * See analytics.jsp for definition of googleAnalyticsTrackPageviewIfConfigured(). * */ -if (typeof dwr === 'undefined') { +if ( typeof dwr === 'undefined' ) { var dwr = {}; } -if (typeof dwr.engine === 'undefined') { +if ( typeof dwr.engine === 'undefined' ) { dwr.engine = {}; } // ==================================================================================== -if (typeof AnnotationController === 'undefined') { +if ( typeof AnnotationController === 'undefined' ) { var AnnotationController = {}; } AnnotationController._path = ctxBasePath + '/dwr'; -AnnotationController.findTerm = function (p0, p1, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'findTerm', p0, p1, callback); +AnnotationController.findTerm = function( p0, p1, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'findTerm', p0, p1, callback ); }; -AnnotationController.createExperimentTag = function (p0, p1, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'createExperimentTag', p0, p1, callback); +AnnotationController.createExperimentTag = function( p0, p1, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'createExperimentTag', p0, p1, callback ); }; -AnnotationController.removeExperimentTag = function (p0, p1, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'removeExperimentTag', p0, p1, callback); +AnnotationController.removeExperimentTag = function( p0, p1, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'removeExperimentTag', p0, p1, callback ); }; -AnnotationController.createBioMaterialTag = function (p0, p1, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'createBioMaterialTag', p0, p1, callback); +AnnotationController.createBioMaterialTag = function( p0, p1, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'createBioMaterialTag', p0, p1, callback ); }; -AnnotationController.getCategoryTerms = function (callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'getCategoryTerms', callback); +AnnotationController.getCategoryTerms = function( callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'getCategoryTerms', callback ); }; -AnnotationController.getRelationTerms = function (callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'getRelationTerms', callback); +AnnotationController.getRelationTerms = function( callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'getRelationTerms', callback ); }; -AnnotationController.removeBioMaterialTag = function (p0, p1, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'removeBioMaterialTag', p0, p1, callback); +AnnotationController.removeBioMaterialTag = function( p0, p1, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'removeBioMaterialTag', p0, p1, callback ); }; -AnnotationController.reinitializeOntologyIndices = function (callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'reinitializeOntologyIndices', callback); +AnnotationController.reinitializeOntologyIndices = function( callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'reinitializeOntologyIndices', callback ); }; -AnnotationController.validateTags = function (p0, callback) { - dwr.engine._execute(AnnotationController._path, 'AnnotationController', 'validateTags', p0, callback); +AnnotationController.validateTags = function( p0, callback ) { + dwr.engine._execute( AnnotationController._path, 'AnnotationController', 'validateTags', p0, callback ); }; // ==================================================================================== -if (typeof ArrayDesignController === 'undefined') { +if ( typeof ArrayDesignController === 'undefined' ) { var ArrayDesignController = {}; } ArrayDesignController._path = ctxBasePath + '/dwr'; -ArrayDesignController.remove = function (p0, callback) { - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'remove', p0, callback); +ArrayDesignController.remove = function( p0, callback ) { + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'remove', p0, callback ); }; -ArrayDesignController.getDetails = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/getDetails"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'getDetails', p0, callback); +ArrayDesignController.getDetails = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/getDetails" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'getDetails', p0, callback ); }; -ArrayDesignController.getArrayDesigns = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/getArrayDesigns"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'getArrayDesigns', p0, p1, p2, callback); +ArrayDesignController.getArrayDesigns = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/getArrayDesigns" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'getArrayDesigns', p0, p1, p2, callback ); }; -ArrayDesignController.loadArrayDesignsForShowAll = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/loadArrayDesignsForShowAll"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'loadArrayDesignsForShowAll', p0, - callback); +ArrayDesignController.loadArrayDesignsForShowAll = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/loadArrayDesignsForShowAll" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'loadArrayDesignsForShowAll', p0, + callback ); }; -ArrayDesignController.addAlternateName = function (p0, p1, callback) { - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'addAlternateName', p0, p1, callback); +ArrayDesignController.addAlternateName = function( p0, p1, callback ) { + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'addAlternateName', p0, p1, callback ); }; -ArrayDesignController.getCsSummaries = function (p0, callback) { - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'getCsSummaries', p0, callback); +ArrayDesignController.getCsSummaries = function( p0, callback ) { + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'getCsSummaries', p0, callback ); }; -ArrayDesignController.getReportHtml = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/getReportHtml"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'getReportHtml', p0, callback); +ArrayDesignController.getReportHtml = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/getReportHtml" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'getReportHtml', p0, callback ); }; -ArrayDesignController.updateReport = function (p0, callback) { - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'updateReport', p0, callback); +ArrayDesignController.updateReport = function( p0, callback ) { + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'updateReport', p0, callback ); }; -ArrayDesignController.getSummaryForArrayDesign = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/getSummaryForArrayDesign"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'getSummaryForArrayDesign', p0, callback); +ArrayDesignController.getSummaryForArrayDesign = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/getSummaryForArrayDesign" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'getSummaryForArrayDesign', p0, callback ); }; -ArrayDesignController.loadArrayDesignsSummary = function (callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignController/loadArrayDesignsSummary"); - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'loadArrayDesignsSummary', callback); +ArrayDesignController.loadArrayDesignsSummary = function( callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignController/loadArrayDesignsSummary" ); + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'loadArrayDesignsSummary', callback ); }; -ArrayDesignController.updateReportById = function (p0, callback) { - dwr.engine._execute(ArrayDesignController._path, 'ArrayDesignController', 'updateReportById', p0, callback); +ArrayDesignController.updateReportById = function( p0, callback ) { + dwr.engine._execute( ArrayDesignController._path, 'ArrayDesignController', 'updateReportById', p0, callback ); }; // ==================================================================================== -if (typeof ArrayDesignRepeatScanController === 'undefined') { +if ( typeof ArrayDesignRepeatScanController === 'undefined' ) { var ArrayDesignRepeatScanController = {}; } ArrayDesignRepeatScanController._path = ctxBasePath + '/dwr'; -ArrayDesignRepeatScanController.run = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ArrayDesignRepeatScanController/run"); - dwr.engine._execute(ArrayDesignRepeatScanController._path, 'ArrayDesignRepeatScanController', 'run', p0, callback); +ArrayDesignRepeatScanController.run = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ArrayDesignRepeatScanController/run" ); + dwr.engine._execute( ArrayDesignRepeatScanController._path, 'ArrayDesignRepeatScanController', 'run', p0, callback ); }; // ==================================================================================== -if (typeof AuditController === 'undefined') { +if ( typeof AuditController === 'undefined' ) { var AuditController = {}; } AuditController._path = ctxBasePath + '/dwr'; -AuditController.addAuditEvent = function (p0, p1, p2, p3, callback) { - dwr.engine._execute(AuditController._path, 'AuditController', 'addAuditEvent', p0, p1, p2, p3, callback); +AuditController.addAuditEvent = function( p0, p1, p2, p3, callback ) { + dwr.engine._execute( AuditController._path, 'AuditController', 'addAuditEvent', p0, p1, p2, p3, callback ); }; -AuditController.getEvents = function (p0, callback) { - dwr.engine._execute(AuditController._path, 'AuditController', 'getEvents', p0, callback); +AuditController.getEvents = function( p0, callback ) { + dwr.engine._execute( AuditController._path, 'AuditController', 'getEvents', p0, callback ); }; // ==================================================================================== -if (typeof BatchInfoFetchController === 'undefined') { +if ( typeof BatchInfoFetchController === 'undefined' ) { var BatchInfoFetchController = {}; } BatchInfoFetchController._path = ctxBasePath + '/dwr'; -BatchInfoFetchController.run = function (p0, callback) { - dwr.engine._execute(BatchInfoFetchController._path, 'BatchInfoFetchController', 'run', p0, callback); +BatchInfoFetchController.run = function( p0, callback ) { + dwr.engine._execute( BatchInfoFetchController._path, 'BatchInfoFetchController', 'run', p0, callback ); }; // ==================================================================================== -if (typeof BibliographicReferenceController === 'undefined') { +if ( typeof BibliographicReferenceController === 'undefined' ) { var BibliographicReferenceController = {}; } BibliographicReferenceController._path = ctxBasePath + '/dwr'; -BibliographicReferenceController.update = function (p0, callback) { - dwr.engine._execute(BibliographicReferenceController._path, 'BibliographicReferenceController', 'update', p0, - callback); -}; -BibliographicReferenceController.browse = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/BibliographicReferenceController/browse"); - dwr.engine._execute(BibliographicReferenceController._path, 'BibliographicReferenceController', 'browse', p0, - callback); -}; -BibliographicReferenceController.load = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/BibliographicReferenceController/load"); - dwr.engine._execute(BibliographicReferenceController._path, 'BibliographicReferenceController', 'load', p0, - callback); -}; -BibliographicReferenceController.search = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/BibliographicReferenceController/search"); - dwr.engine._execute(BibliographicReferenceController._path, 'BibliographicReferenceController', 'search', p0, - callback); -}; -BibliographicReferenceController.loadFromPubmedID = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/BibliographicReferenceController/loadFromPubmedID"); - dwr.engine._execute(BibliographicReferenceController._path, 'BibliographicReferenceController', 'loadFromPubmedID', - p0, callback); +BibliographicReferenceController.update = function( p0, callback ) { + dwr.engine._execute( BibliographicReferenceController._path, 'BibliographicReferenceController', 'update', p0, + callback ); +}; +BibliographicReferenceController.browse = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/BibliographicReferenceController/browse" ); + dwr.engine._execute( BibliographicReferenceController._path, 'BibliographicReferenceController', 'browse', p0, + callback ); +}; +BibliographicReferenceController.load = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/BibliographicReferenceController/load" ); + dwr.engine._execute( BibliographicReferenceController._path, 'BibliographicReferenceController', 'load', p0, + callback ); +}; +BibliographicReferenceController.search = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/BibliographicReferenceController/search" ); + dwr.engine._execute( BibliographicReferenceController._path, 'BibliographicReferenceController', 'search', p0, + callback ); +}; +BibliographicReferenceController.loadFromPubmedID = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/BibliographicReferenceController/loadFromPubmedID" ); + dwr.engine._execute( BibliographicReferenceController._path, 'BibliographicReferenceController', 'loadFromPubmedID', + p0, callback ); }; // ==================================================================================== -if (typeof BioAssayController === 'undefined') { +if ( typeof BioAssayController === 'undefined' ) { var BioAssayController = {}; } BioAssayController._path = ctxBasePath + '/dwr'; -BioAssayController.markOutlier = function (p0, callback) { - dwr.engine._execute(BioAssayController._path, 'BioAssayController', 'markOutlier', p0, callback); +BioAssayController.markOutlier = function( p0, callback ) { + dwr.engine._execute( BioAssayController._path, 'BioAssayController', 'markOutlier', p0, callback ); }; -BioAssayController.unmarkOutlier = function (p0, callback) { - dwr.engine._execute(BioAssayController._path, 'BioAssayController', 'unmarkOutlier', p0, callback); +BioAssayController.unmarkOutlier = function( p0, callback ) { + dwr.engine._execute( BioAssayController._path, 'BioAssayController', 'unmarkOutlier', p0, callback ); }; -BioAssayController.getBioAssays = function (p0, callback) { - dwr.engine._execute(BioAssayController._path, 'BioAssayController', 'getBioAssays', p0, callback); +BioAssayController.getBioAssays = function( p0, callback ) { + dwr.engine._execute( BioAssayController._path, 'BioAssayController', 'getBioAssays', p0, callback ); }; // BioAssayController.getIdentifiedOutliers = function( p0, callback ) { // dwr.engine._execute( BioAssayController._path, 'BioAssayController', 'getIdentifiedOutliers', p0, callback ); // }; // ==================================================================================== -if (typeof BioMaterialController === 'undefined') { +if ( typeof BioMaterialController === 'undefined' ) { var BioMaterialController = {}; } BioMaterialController._path = ctxBasePath + '/dwr'; -BioMaterialController.getAnnotation = function (p0, callback) { - dwr.engine._execute(BioMaterialController._path, 'BioMaterialController', 'getAnnotation', p0, callback); +BioMaterialController.getAnnotation = function( p0, callback ) { + dwr.engine._execute( BioMaterialController._path, 'BioMaterialController', 'getAnnotation', p0, callback ); }; -BioMaterialController.getFactorValues = function (p0, callback) { - dwr.engine._execute(BioMaterialController._path, 'BioMaterialController', 'getFactorValues', p0, callback); +BioMaterialController.getFactorValues = function( p0, callback ) { + dwr.engine._execute( BioMaterialController._path, 'BioMaterialController', 'getFactorValues', p0, callback ); }; -BioMaterialController.getBioMaterials = function (p0, callback) { - dwr.engine._execute(BioMaterialController._path, 'BioMaterialController', 'getBioMaterials', p0, callback); +BioMaterialController.getBioMaterials = function( p0, callback ) { + dwr.engine._execute( BioMaterialController._path, 'BioMaterialController', 'getBioMaterials', p0, callback ); }; -BioMaterialController.addFactorValueTo = function (p0, p1, callback) { - dwr.engine._execute(BioMaterialController._path, 'BioMaterialController', 'addFactorValueTo', p0, p1, callback); +BioMaterialController.addFactorValueTo = function( p0, p1, callback ) { + dwr.engine._execute( BioMaterialController._path, 'BioMaterialController', 'addFactorValueTo', p0, p1, callback ); }; // ==================================================================================== -if (typeof CharacteristicBrowserController === 'undefined') { +if ( typeof CharacteristicBrowserController === 'undefined' ) { var CharacteristicBrowserController = {}; } CharacteristicBrowserController._path = ctxBasePath + '/dwr'; -CharacteristicBrowserController.findCharacteristics = function (p0, callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', - 'findCharacteristics', p0, callback); +CharacteristicBrowserController.findCharacteristics = function( p0, callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', + 'findCharacteristics', p0, callback ); }; -CharacteristicBrowserController.findCharacteristicsCustom = function (p0, p1, p2, p3, p4, p5, p6, p7, callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', - 'findCharacteristicsCustom', p0, p1, p2, p3, p4, p5, p6, p7, callback); +CharacteristicBrowserController.findCharacteristicsCustom = function( p0, p1, p2, p3, p4, p5, p6, p7, callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', + 'findCharacteristicsCustom', p0, p1, p2, p3, p4, p5, p6, p7, callback ); }; -CharacteristicBrowserController.removeCharacteristics = function (p0, callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', - 'removeCharacteristics', p0, callback); +CharacteristicBrowserController.removeCharacteristics = function( p0, callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', + 'removeCharacteristics', p0, callback ); }; -CharacteristicBrowserController.updateCharacteristics = function (p0, callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', - 'updateCharacteristics', p0, callback); +CharacteristicBrowserController.updateCharacteristics = function( p0, callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', + 'updateCharacteristics', p0, callback ); }; -CharacteristicBrowserController.browse = function (p0, callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', 'browse', p0, - callback); +CharacteristicBrowserController.browse = function( p0, callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', 'browse', p0, + callback ); }; -CharacteristicBrowserController.count = function (callback) { - dwr.engine._execute(CharacteristicBrowserController._path, 'CharacteristicBrowserController', 'count', callback); +CharacteristicBrowserController.count = function( callback ) { + dwr.engine._execute( CharacteristicBrowserController._path, 'CharacteristicBrowserController', 'count', callback ); }; // ==================================================================================== -if (typeof CompositeSequenceController === 'undefined') { +if ( typeof CompositeSequenceController === 'undefined' ) { var CompositeSequenceController = {}; } CompositeSequenceController._path = ctxBasePath + '/dwr'; -CompositeSequenceController.search = function (p0, p1, callback) { - dwr.engine._execute(CompositeSequenceController._path, 'CompositeSequenceController', 'search', p0, p1, callback); +CompositeSequenceController.search = function( p0, p1, callback ) { + dwr.engine._execute( CompositeSequenceController._path, 'CompositeSequenceController', 'search', p0, p1, callback ); }; -CompositeSequenceController.getCsSummaries = function (p0, callback) { - dwr.engine._execute(CompositeSequenceController._path, 'CompositeSequenceController', 'getCsSummaries', p0, - callback); +CompositeSequenceController.getCsSummaries = function( p0, callback ) { + dwr.engine._execute( CompositeSequenceController._path, 'CompositeSequenceController', 'getCsSummaries', p0, + callback ); }; -CompositeSequenceController.getGeneCsSummaries = function (p0, callback) { - dwr.engine._execute(CompositeSequenceController._path, 'CompositeSequenceController', 'getGeneCsSummaries', p0, - callback); +CompositeSequenceController.getGeneCsSummaries = function( p0, callback ) { + dwr.engine._execute( CompositeSequenceController._path, 'CompositeSequenceController', 'getGeneCsSummaries', p0, + callback ); }; -CompositeSequenceController.getGeneMappingSummary = function (p0, callback) { - dwr.engine._execute(CompositeSequenceController._path, 'CompositeSequenceController', 'getGeneMappingSummary', p0, - callback); +CompositeSequenceController.getGeneMappingSummary = function( p0, callback ) { + dwr.engine._execute( CompositeSequenceController._path, 'CompositeSequenceController', 'getGeneMappingSummary', p0, + callback ); }; // ==================================================================================== -if (typeof IndexService === 'undefined') { +if ( typeof IndexService === 'undefined' ) { var IndexService = {}; } IndexService._path = ctxBasePath + '/dwr'; -IndexService.index = function (p0, callback) { - dwr.engine._execute(IndexService._path, 'IndexService', 'index', p0, callback); +IndexService.index = function( p0, callback ) { + dwr.engine._execute( IndexService._path, 'IndexService', 'index', p0, callback ); }; // ==================================================================================== -if (typeof DEDVController === 'undefined') { +if ( typeof DEDVController === 'undefined' ) { var DEDVController = {}; } DEDVController._path = ctxBasePath + '/dwr'; -DEDVController.getDEDV = function (p0, p1, callback) { - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDV', p0, p1, callback); +DEDVController.getDEDV = function( p0, p1, callback ) { + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDV', p0, p1, callback ); }; -DEDVController.getDEDVForCoexpressionVisualization = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForCoexpressionVisualization"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForCoexpressionVisualization', p0, p1, p2, - callback); +DEDVController.getDEDVForCoexpressionVisualization = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForCoexpressionVisualization" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForCoexpressionVisualization', p0, p1, p2, + callback ); }; -DEDVController.getDEDVForDiffExVisualization = function (p0, p1, p2, p3, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForDiffExVisualization"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualization', p0, p1, p2, p3, - callback); +DEDVController.getDEDVForDiffExVisualization = function( p0, p1, p2, p3, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForDiffExVisualization" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualization', p0, p1, p2, p3, + callback ); }; -DEDVController.getDEDVForVisualization = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForVisualization"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForVisualization', p0, p1, callback); +DEDVController.getDEDVForVisualization = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForVisualization" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForVisualization', p0, p1, callback ); }; -DEDVController.getDEDVForDiffExVisualizationByThreshold = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForDiffExVisualizationByThreshold"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualizationByThreshold', p0, p1, - callback); +DEDVController.getDEDVForDiffExVisualizationByThreshold = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForDiffExVisualizationByThreshold" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualizationByThreshold', p0, p1, p2, + callback ); }; -DEDVController.getDEDVForPcaVisualization = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForPcaVisualization"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForPcaVisualization', p0, p1, p2, callback); +DEDVController.getDEDVForPcaVisualization = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForPcaVisualization" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForPcaVisualization', p0, p1, p2, callback ); }; -DEDVController.getDEDVForDiffExVisualizationByExperiment = function (p0, p1, p2, p3, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DEDVController/getDEDVForDiffExVisualizationByExperiment"); - dwr.engine._execute(DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualizationByExperiment', p0, p1, - p2, p3, callback); +DEDVController.getDEDVForDiffExVisualizationByExperiment = function( p0, p1, p2, p3, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DEDVController/getDEDVForDiffExVisualizationByExperiment" ); + dwr.engine._execute( DEDVController._path, 'DEDVController', 'getDEDVForDiffExVisualizationByExperiment', p0, p1, + p2, p3, callback ); }; // ==================================================================================== -if (typeof DifferentialExpressionAnalysisController === 'undefined') { +if ( typeof DifferentialExpressionAnalysisController === 'undefined' ) { var DifferentialExpressionAnalysisController = {}; } DifferentialExpressionAnalysisController._path = ctxBasePath + '/dwr'; -DifferentialExpressionAnalysisController.run = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionAnalysisController/run"); - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'run', p0, callback); -}; -DifferentialExpressionAnalysisController.determineAnalysisType = function (p0, callback) { - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'determineAnalysisType', p0, callback); -}; -DifferentialExpressionAnalysisController.runCustom = function (p0, p1, p2, p3, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionAnalysisController/runCutom"); - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'runCustom', p0, p1, p2, p3, callback); -}; -DifferentialExpressionAnalysisController.remove = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionAnalysisController/remove"); - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'remove', p0, p1, callback); -}; -DifferentialExpressionAnalysisController.redo = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionAnalysisController/redo"); - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'redo', p0, p1, callback); -}; -DifferentialExpressionAnalysisController.refreshStats = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionAnalysisController/refreshStats"); - dwr.engine._execute(DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', - 'refreshStats', p0, p1, callback); +DifferentialExpressionAnalysisController.run = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionAnalysisController/run" ); + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'run', p0, callback ); +}; +DifferentialExpressionAnalysisController.determineAnalysisType = function( p0, callback ) { + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'determineAnalysisType', p0, callback ); +}; +DifferentialExpressionAnalysisController.runCustom = function( p0, p1, p2, p3, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionAnalysisController/runCutom" ); + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'runCustom', p0, p1, p2, p3, callback ); +}; +DifferentialExpressionAnalysisController.remove = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionAnalysisController/remove" ); + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'remove', p0, p1, callback ); +}; +DifferentialExpressionAnalysisController.redo = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionAnalysisController/redo" ); + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'redo', p0, p1, callback ); +}; +DifferentialExpressionAnalysisController.refreshStats = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionAnalysisController/refreshStats" ); + dwr.engine._execute( DifferentialExpressionAnalysisController._path, 'DifferentialExpressionAnalysisController', + 'refreshStats', p0, p1, callback ); }; // ==================================================================================== -if (typeof DifferentialExpressionSearchController === 'undefined') { +if ( typeof DifferentialExpressionSearchController === 'undefined' ) { var DifferentialExpressionSearchController = {}; } DifferentialExpressionSearchController._path = ctxBasePath + '/dwr'; -DifferentialExpressionSearchController.getDifferentialExpression = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionSearchController/getDifferentialExpression"); - dwr.engine._execute(DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', - 'getDifferentialExpression', p0, p1, p2, callback); +DifferentialExpressionSearchController.getDifferentialExpression = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionSearchController/getDifferentialExpression" ); + dwr.engine._execute( DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', + 'getDifferentialExpression', p0, p1, p2, callback ); }; -DifferentialExpressionSearchController.getDifferentialExpressionWithoutBatch = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionSearchController/getDifferentialExpressionWithoutBatch"); - dwr.engine._execute(DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', - 'getDifferentialExpressionWithoutBatch', p0, p1, p2, callback); +DifferentialExpressionSearchController.getDifferentialExpressionWithoutBatch = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionSearchController/getDifferentialExpressionWithoutBatch" ); + dwr.engine._execute( DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', + 'getDifferentialExpressionWithoutBatch', p0, p1, p2, callback ); }; -DifferentialExpressionSearchController.getFactors = function (p0, callback) { - dwr.engine._execute(DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', - 'getFactors', p0, callback); +DifferentialExpressionSearchController.getFactors = function( p0, callback ) { + dwr.engine._execute( DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', + 'getFactors', p0, callback ); }; -DifferentialExpressionSearchController.scheduleDiffExpSearchTask = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DifferentialExpressionSearchController/scheduleDiffExpSearchTask"); - dwr.engine._execute(DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', - 'scheduleDiffExpSearchTask', p0, p1, p2, callback); +DifferentialExpressionSearchController.scheduleDiffExpSearchTask = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DifferentialExpressionSearchController/scheduleDiffExpSearchTask" ); + dwr.engine._execute( DifferentialExpressionSearchController._path, 'DifferentialExpressionSearchController', + 'scheduleDiffExpSearchTask', p0, p1, p2, callback ); }; // ==================================================================================== -if (typeof DiffExMetaAnalyzerController === 'undefined') { +if ( typeof DiffExMetaAnalyzerController === 'undefined' ) { var DiffExMetaAnalyzerController = {}; } DiffExMetaAnalyzerController._path = ctxBasePath + '/dwr'; -DiffExMetaAnalyzerController.analyzeResultSets = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DiffExMetaAnalyzerController/analyzeResultSets"); - dwr.engine._execute(DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'analyzeResultSets', p0, - callback); -}; -DiffExMetaAnalyzerController.findDetailMetaAnalysisById = function (p0, callback) { - dwr.engine._execute(DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', - 'findDetailMetaAnalysisById', p0, callback); -}; -DiffExMetaAnalyzerController.loadAllMetaAnalyses = function (callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DiffExMetaAnalyzerController/loadAllMetaAnalyses"); - dwr.engine._execute(DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'loadAllMetaAnalyses', - callback); -}; -DiffExMetaAnalyzerController.removeMetaAnalysis = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DiffExMetaAnalyzerController/removeMetaAnalysis"); - dwr.engine._execute(DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'removeMetaAnalysis', p0, - callback); -}; -DiffExMetaAnalyzerController.saveResultSets = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/DiffExMetaAnalyzerController/saveResultSets"); - dwr.engine._execute(DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'saveResultSets', p0, p1, - p2, callback); +DiffExMetaAnalyzerController.analyzeResultSets = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DiffExMetaAnalyzerController/analyzeResultSets" ); + dwr.engine._execute( DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'analyzeResultSets', p0, + callback ); +}; +DiffExMetaAnalyzerController.findDetailMetaAnalysisById = function( p0, callback ) { + dwr.engine._execute( DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', + 'findDetailMetaAnalysisById', p0, callback ); +}; +DiffExMetaAnalyzerController.loadAllMetaAnalyses = function( callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DiffExMetaAnalyzerController/loadAllMetaAnalyses" ); + dwr.engine._execute( DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'loadAllMetaAnalyses', + callback ); +}; +DiffExMetaAnalyzerController.removeMetaAnalysis = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DiffExMetaAnalyzerController/removeMetaAnalysis" ); + dwr.engine._execute( DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'removeMetaAnalysis', p0, + callback ); +}; +DiffExMetaAnalyzerController.saveResultSets = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/DiffExMetaAnalyzerController/saveResultSets" ); + dwr.engine._execute( DiffExMetaAnalyzerController._path, 'DiffExMetaAnalyzerController', 'saveResultSets', p0, p1, + p2, callback ); }; // ==================================================================================== -if (typeof ExperimentalDesignController === 'undefined') { +if ( typeof ExperimentalDesignController === 'undefined' ) { var ExperimentalDesignController = {}; } ExperimentalDesignController._path = ctxBasePath + '/dwr'; -ExperimentalDesignController.updateBioMaterials = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/updateBioMaterials"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'updateBioMaterials', p0, - callback); -}; -ExperimentalDesignController.getFactorValues = function (p0, callback) { - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'getFactorValues', p0, - callback); -}; -ExperimentalDesignController.getExperimentalFactors = function (p0, callback) { - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'getExperimentalFactors', - p0, callback); -}; -ExperimentalDesignController.getBioMaterials = function (p0, callback) { - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'getBioMaterials', p0, - callback); -}; -ExperimentalDesignController.getBioMaterialCharacteristicCategories = function (p0, callback) { - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'getBioMaterialCharacteristicCategories', p0, - callback); -}; -ExperimentalDesignController.createDesignFromFile = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/createDesignFromFile"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'createDesignFromFile', p0, - p1, callback); -}; -ExperimentalDesignController.createExperimentalFactor = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/createExperimentalFactor"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'createExperimentalFactor', - p0, p1, callback); -}; -ExperimentalDesignController.createFactorValue = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/createFactorValue"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'createFactorValue', p0, - callback); -}; -ExperimentalDesignController.createFactorValueCharacteristic = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/createFactorValueCharacteristic"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'createFactorValueCharacteristic', p0, p1, callback); -}; -ExperimentalDesignController.deleteExperimentalFactors = function (pO, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/deleteExperimentalFactors"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'deleteExperimentalFactors', pO, p1, callback); -}; -ExperimentalDesignController.deleteFactorValueCharacteristics = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/deleteFactorValueCharacteristics"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'deleteFactorValueCharacteristics', p0, callback); -}; -ExperimentalDesignController.deleteFactorValues = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/deleteFactorValues"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', 'deleteFactorValues', p0, - p1, callback); -}; -ExperimentalDesignController.getFactorValuesWithCharacteristics = function (p0, callback) { - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'getFactorValuesWithCharacteristics', p0, callback); -}; -ExperimentalDesignController.updateExperimentalFactors = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/updateExperimentalFactors"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'updateExperimentalFactors', p0, callback); -}; -ExperimentalDesignController.updateFactorValueCharacteristics = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExperimentalDesignController/updateFactorValueCharacteristics"); - dwr.engine._execute(ExperimentalDesignController._path, 'ExperimentalDesignController', - 'updateFactorValueCharacteristics', p0, callback); +ExperimentalDesignController.updateBioMaterials = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/updateBioMaterials" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'updateBioMaterials', p0, + callback ); +}; +ExperimentalDesignController.getFactorValues = function( p0, callback ) { + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'getFactorValues', p0, + callback ); +}; +ExperimentalDesignController.getExperimentalFactors = function( p0, callback ) { + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'getExperimentalFactors', + p0, callback ); +}; +ExperimentalDesignController.getBioMaterials = function( p0, callback ) { + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'getBioMaterials', p0, + callback ); +}; +ExperimentalDesignController.getBioMaterialCharacteristicCategories = function( p0, callback ) { + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'getBioMaterialCharacteristicCategories', p0, + callback ); +}; +ExperimentalDesignController.createDesignFromFile = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/createDesignFromFile" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'createDesignFromFile', p0, + p1, callback ); +}; +ExperimentalDesignController.createExperimentalFactor = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/createExperimentalFactor" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'createExperimentalFactor', + p0, p1, callback ); +}; +ExperimentalDesignController.createFactorValue = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/createFactorValue" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'createFactorValue', p0, + callback ); +}; +ExperimentalDesignController.createFactorValueCharacteristic = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/createFactorValueCharacteristic" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'createFactorValueCharacteristic', p0, p1, callback ); +}; +ExperimentalDesignController.deleteExperimentalFactors = function( pO, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/deleteExperimentalFactors" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'deleteExperimentalFactors', pO, p1, callback ); +}; +ExperimentalDesignController.deleteFactorValueCharacteristics = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/deleteFactorValueCharacteristics" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'deleteFactorValueCharacteristics', p0, callback ); +}; +ExperimentalDesignController.deleteFactorValues = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/deleteFactorValues" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'deleteFactorValues', p0, + p1, callback ); +}; +ExperimentalDesignController.getFactorValuesWithCharacteristics = function( p0, callback ) { + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'getFactorValuesWithCharacteristics', p0, callback ); +}; +ExperimentalDesignController.updateExperimentalFactors = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/updateExperimentalFactors" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'updateExperimentalFactors', p0, callback ); +}; +ExperimentalDesignController.updateFactorValueCharacteristics = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExperimentalDesignController/updateFactorValueCharacteristics" ); + dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', + 'updateFactorValueCharacteristics', p0, callback ); }; ExperimentalDesignController.markFactorValuesAsNeedsAttention = function( p0, p1, callback ) { dwr.engine._execute( ExperimentalDesignController._path, 'ExperimentalDesignController', 'markFactorValuesAsNeedsAttention', @@ -451,128 +451,128 @@ ExperimentalDesignController.clearFactorValuesNeedsAttention = function( p0, p1, p0, p1, callback ); }; // ==================================================================================== -if (typeof ExpressionDataFileUploadController === 'undefined') { +if ( typeof ExpressionDataFileUploadController === 'undefined' ) { var ExpressionDataFileUploadController = {}; } ExpressionDataFileUploadController._path = ctxBasePath + '/dwr'; -ExpressionDataFileUploadController.load = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionDataFileUploadController/load"); - dwr.engine._execute(ExpressionDataFileUploadController._path, 'ExpressionDataFileUploadController', 'load', p0, - callback); +ExpressionDataFileUploadController.load = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionDataFileUploadController/load" ); + dwr.engine._execute( ExpressionDataFileUploadController._path, 'ExpressionDataFileUploadController', 'load', p0, + callback ); }; -ExpressionDataFileUploadController.validate = function (p0, callback) { - dwr.engine._execute(ExpressionDataFileUploadController._path, 'ExpressionDataFileUploadController', 'validate', p0, - callback); +ExpressionDataFileUploadController.validate = function( p0, callback ) { + dwr.engine._execute( ExpressionDataFileUploadController._path, 'ExpressionDataFileUploadController', 'validate', p0, + callback ); }; // ==================================================================================== -if (typeof ExpressionExperimentController === 'undefined') { +if ( typeof ExpressionExperimentController === 'undefined' ) { var ExpressionExperimentController = {}; } ExpressionExperimentController._path = ctxBasePath + '/dwr'; -ExpressionExperimentController.getAnnotation = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'getAnnotation', p0, - callback); -}; -ExpressionExperimentController.find = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/find"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'find', p0, p1, - callback); -}; -ExpressionExperimentController.searchExpressionExperiments = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/searchExpressionExperiments"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'searchExpressionExperiments', p0, callback); -}; -ExpressionExperimentController.getAllTaxonExperimentGroup = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'getAllTaxonExperimentGroup', p0, callback); -}; -ExpressionExperimentController.searchExperimentsAndExperimentGroups = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/searchExperimentsAndExperimentGroups"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'searchExperimentsAndExperimentGroups', p0, p1, callback); -}; -ExpressionExperimentController.getDescription = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'getDescription', p0, - callback); -}; -ExpressionExperimentController.getFactorValues = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'getFactorValues', p0, - callback); -}; -ExpressionExperimentController.getExperimentalFactors = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/getExperimentalFactors"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'getExperimentalFactors', p0, callback); -}; -ExpressionExperimentController.updateReport = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/updateReport"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateReport', p0, - callback); -}; -ExpressionExperimentController.updatePubMed = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/updatePubMed"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'updatePubMed', p0, p1, - callback); -}; -ExpressionExperimentController.deleteById = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/deleteById"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'deleteById', p0, - callback); -}; -ExpressionExperimentController.getDesignMatrixRows = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/getDesignMatrixRows"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'getDesignMatrixRows', - p0, callback); -}; -ExpressionExperimentController.loadExpressionExperimentDetails = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadExpressionExperimentDetails?" - + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadExpressionExperimentDetails', p0, callback); -}; -ExpressionExperimentController.loadQuantitationTypes = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadQuantitationTypes?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadQuantitationTypes', p0, callback); -}; -ExpressionExperimentController.loadExpressionExperiments = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadExpressionExperiments?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadExpressionExperiments', p0, callback); -}; -ExpressionExperimentController.loadDetailedExpressionExperiments = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadDetailedExpressionExperiments?" - + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadDetailedExpressionExperiments', p0, callback); +ExpressionExperimentController.getAnnotation = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'getAnnotation', p0, + callback ); +}; +ExpressionExperimentController.find = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/find" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'find', p0, p1, + callback ); +}; +ExpressionExperimentController.searchExpressionExperiments = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/searchExpressionExperiments" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'searchExpressionExperiments', p0, callback ); +}; +ExpressionExperimentController.getAllTaxonExperimentGroup = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'getAllTaxonExperimentGroup', p0, callback ); +}; +ExpressionExperimentController.searchExperimentsAndExperimentGroups = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/searchExperimentsAndExperimentGroups" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'searchExperimentsAndExperimentGroups', p0, p1, callback ); +}; +ExpressionExperimentController.getDescription = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'getDescription', p0, + callback ); +}; +ExpressionExperimentController.getFactorValues = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'getFactorValues', p0, + callback ); +}; +ExpressionExperimentController.getExperimentalFactors = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/getExperimentalFactors" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'getExperimentalFactors', p0, callback ); +}; +ExpressionExperimentController.updateReport = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/updateReport" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateReport', p0, + callback ); +}; +ExpressionExperimentController.updatePubMed = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/updatePubMed" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'updatePubMed', p0, p1, + callback ); +}; +ExpressionExperimentController.deleteById = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/deleteById" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'deleteById', p0, + callback ); +}; +ExpressionExperimentController.getDesignMatrixRows = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/getDesignMatrixRows" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'getDesignMatrixRows', + p0, callback ); +}; +ExpressionExperimentController.loadExpressionExperimentDetails = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadExpressionExperimentDetails?" + + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadExpressionExperimentDetails', p0, callback ); +}; +ExpressionExperimentController.loadQuantitationTypes = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadQuantitationTypes?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadQuantitationTypes', p0, callback ); +}; +ExpressionExperimentController.loadExpressionExperiments = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadExpressionExperiments?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadExpressionExperiments', p0, callback ); +}; +ExpressionExperimentController.loadDetailedExpressionExperiments = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadDetailedExpressionExperiments?" + + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadDetailedExpressionExperiments', p0, callback ); }; -ExpressionExperimentController.loadExperimentsForPlatform = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadExperimentsForPlatform?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadExperimentsForPlatform', p0, callback); +ExpressionExperimentController.loadExperimentsForPlatform = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadExperimentsForPlatform?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadExperimentsForPlatform', p0, callback ); }; -ExpressionExperimentController.loadStatusSummaries = function (p0, p1, p2, p3, p4, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/loadStatusSummaries"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'loadStatusSummaries', - p0, p1, p2, p3, p4, callback); -}; -ExpressionExperimentController.removePrimaryPublication = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/removePrimaryPublication?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'removePrimaryPublication', p0, callback); -}; -ExpressionExperimentController.updateAllReports = function (callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/updateAllReports"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateAllReports', - callback); -}; -ExpressionExperimentController.updateBasics = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/updateBasics"); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateBasics', p0, - callback); +ExpressionExperimentController.loadStatusSummaries = function( p0, p1, p2, p3, p4, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/loadStatusSummaries" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'loadStatusSummaries', + p0, p1, p2, p3, p4, callback ); +}; +ExpressionExperimentController.removePrimaryPublication = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/removePrimaryPublication?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'removePrimaryPublication', p0, callback ); +}; +ExpressionExperimentController.updateAllReports = function( callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/updateAllReports" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateAllReports', + callback ); +}; +ExpressionExperimentController.updateBasics = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/updateBasics" ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'updateBasics', p0, + callback ); }; // ExpressionExperimentController.clearFromCaches = function(p0, callback ) { // dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', @@ -582,738 +582,738 @@ ExpressionExperimentController.updateBasics = function (p0, callback) { // dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', // 'updateBioMaterialMapping', callback); // } -ExpressionExperimentController.unmatchAllBioAssays = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/unmatchAllBioAssays?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'unmatchAllBioAssays', - p0, callback); -}; -ExpressionExperimentController.canCurrentUserEditExperiment = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'canCurrentUserEditExperiment', p0, callback); -}; -ExpressionExperimentController.browse = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/browse?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'browse', p0, callback); -}; -ExpressionExperimentController.browseSpecificIds = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/browseSpecificIds?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'browseSpecificIds', - p0, p1, callback); +ExpressionExperimentController.unmatchAllBioAssays = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/unmatchAllBioAssays?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'unmatchAllBioAssays', + p0, callback ); +}; +ExpressionExperimentController.canCurrentUserEditExperiment = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'canCurrentUserEditExperiment', p0, callback ); +}; +ExpressionExperimentController.browse = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/browse?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'browse', p0, callback ); +}; +ExpressionExperimentController.browseSpecificIds = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/browseSpecificIds?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'browseSpecificIds', + p0, p1, callback ); }; -ExpressionExperimentController.browseByTaxon = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentController/browseByTaxon?" + p0); - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', 'browseByTaxon', p0, - p1, callback); +ExpressionExperimentController.browseByTaxon = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentController/browseByTaxon?" + p0 ); + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', 'browseByTaxon', p0, + p1, callback ); }; -ExpressionExperimentController.loadCountsForDataSummaryTable = function (callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadCountsForDataSummaryTable', callback); +ExpressionExperimentController.loadCountsForDataSummaryTable = function( callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadCountsForDataSummaryTable', callback ); }; -ExpressionExperimentController.loadExpressionExperimentsWithQcIssues = function (callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'loadExpressionExperimentsWithQcIssues', callback); +ExpressionExperimentController.loadExpressionExperimentsWithQcIssues = function( callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'loadExpressionExperimentsWithQcIssues', callback ); }; -ExpressionExperimentController.recalculateBatchConfound = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'recalculateBatchConfound', p0, callback); +ExpressionExperimentController.recalculateBatchConfound = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'recalculateBatchConfound', p0, callback ); }; -ExpressionExperimentController.recalculateBatchEffect = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'recalculateBatchEffect', p0, callback); +ExpressionExperimentController.recalculateBatchEffect = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'recalculateBatchEffect', p0, callback ); }; -ExpressionExperimentController.runGeeq = function (p0, p1, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'runGeeq', p0, p1, callback); +ExpressionExperimentController.runGeeq = function( p0, p1, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'runGeeq', p0, p1, callback ); }; -ExpressionExperimentController.setGeeqManualSettings = function (p0, p1, callback) { - dwr.engine._execute(ExpressionExperimentController._path, 'ExpressionExperimentController', - 'setGeeqManualSettings', p0, p1, callback); +ExpressionExperimentController.setGeeqManualSettings = function( p0, p1, callback ) { + dwr.engine._execute( ExpressionExperimentController._path, 'ExpressionExperimentController', + 'setGeeqManualSettings', p0, p1, callback ); }; // ==================================================================================== -if (typeof ExpressionExperimentDataFetchController === 'undefined') { +if ( typeof ExpressionExperimentDataFetchController === 'undefined' ) { var ExpressionExperimentDataFetchController = {}; } ExpressionExperimentDataFetchController._path = ctxBasePath + '/dwr'; -ExpressionExperimentDataFetchController.getDataFile = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentDataFetchController/getDataFile?" + p0); - dwr.engine._execute(ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', - 'getDataFile', p0, callback); -}; -ExpressionExperimentDataFetchController.getMetadataFiles = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', - 'getMetadataFiles', p0, callback); -}; -ExpressionExperimentDataFetchController.getDiffExpressionDataFile = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentDataFetchController/getDiffExpressionDataFile?" - + p0); - dwr.engine._execute(ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', - 'getDiffExpressionDataFile', p0, callback); -}; -ExpressionExperimentDataFetchController.getCoExpressionDataFile = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentDataFetchController/getCoExpressionDataFile?" - + p0); - dwr.engine._execute(ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', - 'getCoExpressionDataFile', p0, callback); +ExpressionExperimentDataFetchController.getDataFile = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentDataFetchController/getDataFile?" + p0 ); + dwr.engine._execute( ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', + 'getDataFile', p0, callback ); +}; +ExpressionExperimentDataFetchController.getMetadataFiles = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', + 'getMetadataFiles', p0, callback ); +}; +ExpressionExperimentDataFetchController.getDiffExpressionDataFile = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentDataFetchController/getDiffExpressionDataFile?" + + p0 ); + dwr.engine._execute( ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', + 'getDiffExpressionDataFile', p0, callback ); +}; +ExpressionExperimentDataFetchController.getCoExpressionDataFile = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentDataFetchController/getCoExpressionDataFile?" + + p0 ); + dwr.engine._execute( ExpressionExperimentDataFetchController._path, 'ExpressionExperimentDataFetchController', + 'getCoExpressionDataFile', p0, callback ); }; // ==================================================================================== -if (typeof ExpressionExperimentLoadController === 'undefined') { +if ( typeof ExpressionExperimentLoadController === 'undefined' ) { var ExpressionExperimentLoadController = {}; } ExpressionExperimentLoadController._path = ctxBasePath + '/dwr'; -ExpressionExperimentLoadController.load = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentLoadController._path, 'ExpressionExperimentLoadController', 'load', p0, - callback); +ExpressionExperimentLoadController.load = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentLoadController._path, 'ExpressionExperimentLoadController', 'load', p0, + callback ); }; // ==================================================================================== -if (typeof ExpressionExperimentSetController === 'undefined') { +if ( typeof ExpressionExperimentSetController === 'undefined' ) { var ExpressionExperimentSetController = {}; } ExpressionExperimentSetController._path = ctxBasePath + '/dwr'; -ExpressionExperimentSetController.remove = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/remove?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'remove', p0, - callback); -}; -ExpressionExperimentSetController.create = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/create?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'create', p0, - callback); -}; -ExpressionExperimentSetController.update = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/update?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'update', p0, - callback); -}; -ExpressionExperimentSetController.updateNameDesc = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/updateNameDesc?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'updateNameDesc', - p0, callback); -}; -ExpressionExperimentSetController.updateMembers = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/updateMembers?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'updateMembers', - p0, p1, callback); -}; -ExpressionExperimentSetController.loadAll = function (callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/loadAll"); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'loadAll', - callback); -}; -ExpressionExperimentSetController.load = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/load?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'load', p0, - callback); -}; -ExpressionExperimentSetController.loadByName = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/ExpressionExperimentSetController/loadByName?" + p0); - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'loadByName', p0, - callback); -}; -ExpressionExperimentSetController.removeUserAndSessionGroups = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'removeUserAndSessionGroups', p0, callback); -}; -ExpressionExperimentSetController.addUserAndSessionGroups = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'addUserAndSessionGroups', p0, callback); -}; -ExpressionExperimentSetController.addSessionGroups = function (p0, p1, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'addSessionGroups', p0, p1, callback); -}; -ExpressionExperimentSetController.addSessionGroup = function (p0, p1, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'addSessionGroup', p0, p1, callback); -}; -ExpressionExperimentSetController.updateUserAndSessionGroups = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'updateUserAndSessionGroups', p0, callback); -}; -ExpressionExperimentSetController.updateSessionGroups = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'updateSessionGroups', p0, callback); -}; -ExpressionExperimentSetController.loadAllUserAndSessionGroups = function (callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'loadAllUserAndSessionGroups', callback); -}; -ExpressionExperimentSetController.loadAllSessionGroups = function (callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'loadAllSessionGroups', callback); +ExpressionExperimentSetController.remove = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/remove?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'remove', p0, + callback ); +}; +ExpressionExperimentSetController.create = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/create?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'create', p0, + callback ); +}; +ExpressionExperimentSetController.update = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/update?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'update', p0, + callback ); +}; +ExpressionExperimentSetController.updateNameDesc = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/updateNameDesc?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'updateNameDesc', + p0, callback ); +}; +ExpressionExperimentSetController.updateMembers = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/updateMembers?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'updateMembers', + p0, p1, callback ); +}; +ExpressionExperimentSetController.loadAll = function( callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/loadAll" ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'loadAll', + callback ); +}; +ExpressionExperimentSetController.load = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/load?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'load', p0, + callback ); +}; +ExpressionExperimentSetController.loadByName = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/ExpressionExperimentSetController/loadByName?" + p0 ); + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', 'loadByName', p0, + callback ); +}; +ExpressionExperimentSetController.removeUserAndSessionGroups = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'removeUserAndSessionGroups', p0, callback ); +}; +ExpressionExperimentSetController.addUserAndSessionGroups = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'addUserAndSessionGroups', p0, callback ); +}; +ExpressionExperimentSetController.addSessionGroups = function( p0, p1, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'addSessionGroups', p0, p1, callback ); +}; +ExpressionExperimentSetController.addSessionGroup = function( p0, p1, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'addSessionGroup', p0, p1, callback ); +}; +ExpressionExperimentSetController.updateUserAndSessionGroups = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'updateUserAndSessionGroups', p0, callback ); +}; +ExpressionExperimentSetController.updateSessionGroups = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'updateSessionGroups', p0, callback ); +}; +ExpressionExperimentSetController.loadAllUserAndSessionGroups = function( callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'loadAllUserAndSessionGroups', callback ); +}; +ExpressionExperimentSetController.loadAllSessionGroups = function( callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'loadAllSessionGroups', callback ); }; // ExpressionExperimentSetController.getExperimentsInSetBySessionId = function( p0, callback ) { // dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', // 'getExperimentsInSetBySessionId', p0, callback ); // }; -ExpressionExperimentSetController.getExperimentIdsInSet = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'getExperimentIdsInSet', p0, callback); +ExpressionExperimentSetController.getExperimentIdsInSet = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'getExperimentIdsInSet', p0, callback ); }; -ExpressionExperimentSetController.getExperimentsInSet = function (p0, p1, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'getExperimentsInSet', p0, p1, callback); +ExpressionExperimentSetController.getExperimentsInSet = function( p0, p1, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'getExperimentsInSet', p0, p1, callback ); }; -ExpressionExperimentSetController.canCurrentUserEditGroup = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', - 'canCurrentUserEditGroup', p0, callback); +ExpressionExperimentSetController.canCurrentUserEditGroup = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentSetController._path, 'ExpressionExperimentSetController', + 'canCurrentUserEditGroup', p0, callback ); }; // ==================================================================================== -if (typeof ExpressionExperimentReportGenerationController === 'undefined') { +if ( typeof ExpressionExperimentReportGenerationController === 'undefined' ) { var ExpressionExperimentReportGenerationController = {}; } ExpressionExperimentReportGenerationController._path = ctxBasePath + '/dwr'; -ExpressionExperimentReportGenerationController.run = function (p0, callback) { - dwr.engine._execute(ExpressionExperimentReportGenerationController._path, - 'ExpressionExperimentReportGenerationController', 'run', p0, callback); +ExpressionExperimentReportGenerationController.run = function( p0, callback ) { + dwr.engine._execute( ExpressionExperimentReportGenerationController._path, + 'ExpressionExperimentReportGenerationController', 'run', p0, callback ); }; -ExpressionExperimentReportGenerationController.runAll = function (callback) { - dwr.engine._execute(ExpressionExperimentReportGenerationController._path, - 'ExpressionExperimentReportGenerationController', 'runAll', callback); +ExpressionExperimentReportGenerationController.runAll = function( callback ) { + dwr.engine._execute( ExpressionExperimentReportGenerationController._path, + 'ExpressionExperimentReportGenerationController', 'runAll', callback ); }; // ==================================================================================== -if (typeof CoexpressionSearchController === 'undefined') { +if ( typeof CoexpressionSearchController === 'undefined' ) { var CoexpressionSearchController = {}; } CoexpressionSearchController._path = ctxBasePath + '/dwr'; -CoexpressionSearchController.doSearch = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/CoexpressionSearchController/doSearch"); - dwr.engine._execute(CoexpressionSearchController._path, 'CoexpressionSearchController', 'doSearch', p0, callback); -}; -CoexpressionSearchController.doSearchQuickComplete = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/CoexpressionSearchController/doSearchQuickComplete"); - dwr.engine._execute(CoexpressionSearchController._path, 'CoexpressionSearchController', 'doSearchQuickComplete', - p0, p1, callback); +CoexpressionSearchController.doSearch = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/CoexpressionSearchController/doSearch" ); + dwr.engine._execute( CoexpressionSearchController._path, 'CoexpressionSearchController', 'doSearch', p0, callback ); +}; +CoexpressionSearchController.doSearchQuickComplete = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/CoexpressionSearchController/doSearchQuickComplete" ); + dwr.engine._execute( CoexpressionSearchController._path, 'CoexpressionSearchController', 'doSearchQuickComplete', + p0, p1, callback ); }; -CoexpressionSearchController.doBackgroundCoexSearch = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/CoexpressionSearchController/doBackgroundCoexSearch"); - dwr.engine._execute(CoexpressionSearchController._path, 'CoexpressionSearchController', 'doBackgroundCoexSearch', - p0, callback); +CoexpressionSearchController.doBackgroundCoexSearch = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/CoexpressionSearchController/doBackgroundCoexSearch" ); + dwr.engine._execute( CoexpressionSearchController._path, 'CoexpressionSearchController', 'doBackgroundCoexSearch', + p0, callback ); }; // ==================================================================================== -if (typeof FileUploadController === 'undefined') { +if ( typeof FileUploadController === 'undefined' ) { var FileUploadController = {}; } FileUploadController._path = ctxBasePath + '/dwr'; -FileUploadController.upload = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/FileUploadController/upload"); - dwr.engine._execute(FileUploadController._path, 'FileUploadController', 'upload', p0, callback); +FileUploadController.upload = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/FileUploadController/upload" ); + dwr.engine._execute( FileUploadController._path, 'FileUploadController', 'upload', p0, callback ); }; -FileUploadController.getUploadStatus = function (callback) { - dwr.engine._execute(FileUploadController._path, 'FileUploadController', 'getUploadStatus', callback); +FileUploadController.getUploadStatus = function( callback ) { + dwr.engine._execute( FileUploadController._path, 'FileUploadController', 'getUploadStatus', callback ); }; // ==================================================================================== -if (typeof GeneController === 'undefined') { +if ( typeof GeneController === 'undefined' ) { var GeneController = {}; } GeneController._path = ctxBasePath + '/dwr'; -GeneController.getProducts = function (p0, callback) { +GeneController.getProducts = function( p0, callback ) { // Not used? - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/getProducts"); - dwr.engine._execute(GeneController._path, 'GeneController', 'getProducts', p0, callback); + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/getProducts" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'getProducts', p0, callback ); }; -GeneController.findGOTerms = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/findGOTerms"); - dwr.engine._execute(GeneController._path, 'GeneController', 'findGOTerms', p0, callback); +GeneController.findGOTerms = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/findGOTerms" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'findGOTerms', p0, callback ); }; -GeneController.loadGeneDetails = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/loadGeneDetails"); - dwr.engine._execute(GeneController._path, 'GeneController', 'loadGeneDetails', p0, callback); +GeneController.loadGeneDetails = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/loadGeneDetails" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'loadGeneDetails', p0, callback ); }; -GeneController.loadGeneEvidence = function (p0, p1, p2, p3, p4, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/loadGeneEvidence"); - dwr.engine._execute(GeneController._path, 'GeneController', 'loadGeneEvidence', p0, p1, p2, p3, p4, callback); +GeneController.loadGeneEvidence = function( p0, p1, p2, p3, p4, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/loadGeneEvidence" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'loadGeneEvidence', p0, p1, p2, p3, p4, callback ); }; -GeneController.loadAllenBrainImages = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/loadAllenBrainImages"); - dwr.engine._execute(GeneController._path, 'GeneController', 'loadAllenBrainImages', p0, callback); +GeneController.loadAllenBrainImages = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/loadAllenBrainImages" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'loadAllenBrainImages', p0, callback ); }; -GeneController.getGeneABALink = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneController/getGeneABALink"); - dwr.engine._execute(GeneController._path, 'GeneController', 'getGeneABALink', p0, callback); +GeneController.getGeneABALink = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneController/getGeneABALink" ); + dwr.engine._execute( GeneController._path, 'GeneController', 'getGeneABALink', p0, callback ); }; // ==================================================================================== -if (typeof GenePickerController === 'undefined') { +if ( typeof GenePickerController === 'undefined' ) { var GenePickerController = {}; } GenePickerController._path = ctxBasePath + '/dwr'; -GenePickerController.getGenes = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/getGenes"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getGenes', p0, callback); +GenePickerController.getGenes = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/getGenes" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getGenes', p0, callback ); }; -GenePickerController.getGenesByGOId = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/getGenesByGOId"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getGenesByGOId', p0, p1, callback); +GenePickerController.getGenesByGOId = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/getGenesByGOId" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getGenesByGOId', p0, p1, callback ); }; -GenePickerController.searchGenes = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/searchGenes"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchGenes', p0, p1, callback); +GenePickerController.searchGenes = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/searchGenes" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchGenes', p0, p1, callback ); }; -GenePickerController.searchGenesAndGeneGroups = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/searchGenesAndGeneGroups"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchGenesAndGeneGroups', p0, p1, - callback); +GenePickerController.searchGenesAndGeneGroups = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/searchGenesAndGeneGroups" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchGenesAndGeneGroups', p0, p1, + callback ); }; -GenePickerController.searchGenesAndGeneGroupsGetIds = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/searchGenesAndGeneGroupsGetIds"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchGenesAndGeneGroupsGetIds', p0, p1, - callback); +GenePickerController.searchGenesAndGeneGroupsGetIds = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/searchGenesAndGeneGroupsGetIds" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchGenesAndGeneGroupsGetIds', p0, p1, + callback ); }; -GenePickerController.searchGenesWithNCBIId = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GenePickerController/searchGenesWithNCBIId"); - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchGenesWithNCBIId', p0, p1, callback); +GenePickerController.searchGenesWithNCBIId = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GenePickerController/searchGenesWithNCBIId" ); + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchGenesWithNCBIId', p0, p1, callback ); }; -GenePickerController.getTaxa = function (callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getTaxa', callback); +GenePickerController.getTaxa = function( callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getTaxa', callback ); }; -GenePickerController.getTaxaWithGenes = function (callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getTaxaWithGenes', callback); +GenePickerController.getTaxaWithGenes = function( callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getTaxaWithGenes', callback ); }; -GenePickerController.getTaxaWithDatasets = function (callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getTaxaWithDatasets', callback); +GenePickerController.getTaxaWithDatasets = function( callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getTaxaWithDatasets', callback ); }; -GenePickerController.getTaxaWithArrays = function (callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getTaxaWithArrays', callback); +GenePickerController.getTaxaWithArrays = function( callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getTaxaWithArrays', callback ); }; -GenePickerController.getTaxaWithEvidence = function (callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getTaxaWithEvidence', callback); +GenePickerController.getTaxaWithEvidence = function( callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getTaxaWithEvidence', callback ); }; -GenePickerController.searchMultipleGenes = function (p0, p1, callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchMultipleGenes', p0, p1, callback); +GenePickerController.searchMultipleGenes = function( p0, p1, callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchMultipleGenes', p0, p1, callback ); }; /** * @param {Array} * @param {Number} * @param {Function} */ -GenePickerController.searchMultipleGenesGetMap = function (p0, p1, callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'searchMultipleGenesGetMap', p0, p1, - callback); +GenePickerController.searchMultipleGenesGetMap = function( p0, p1, callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'searchMultipleGenesGetMap', p0, p1, + callback ); }; -GenePickerController.getGeneSetByGOId = function (p0, p1, callback) { - dwr.engine._execute(GenePickerController._path, 'GenePickerController', 'getGeneSetByGOId', p0, p1, callback); +GenePickerController.getGeneSetByGOId = function( p0, p1, callback ) { + dwr.engine._execute( GenePickerController._path, 'GenePickerController', 'getGeneSetByGOId', p0, p1, callback ); }; // ==================================================================================== -if (typeof GeoRecordBrowserController === 'undefined') { +if ( typeof GeoRecordBrowserController === 'undefined' ) { var GeoRecordBrowserController = {}; } GeoRecordBrowserController._path = ctxBasePath + '/dwr'; -GeoRecordBrowserController.browse = function (p0, p1, p2, callback) { - dwr.engine._execute(GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'browse', p0, p1, p2, callback); +GeoRecordBrowserController.browse = function( p0, p1, p2, callback ) { + dwr.engine._execute( GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'browse', p0, p1, p2, callback ); }; -GeoRecordBrowserController.getDetails = function (p0, callback) { - dwr.engine._execute(GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'getDetails', p0, callback); +GeoRecordBrowserController.getDetails = function( p0, callback ) { + dwr.engine._execute( GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'getDetails', p0, callback ); }; -GeoRecordBrowserController.toggleUsability = function (p0, callback) { +GeoRecordBrowserController.toggleUsability = function( p0, callback ) { dwr.engine - ._execute(GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'toggleUsability', p0, callback); + ._execute( GeoRecordBrowserController._path, 'GeoRecordBrowserController', 'toggleUsability', p0, callback ); }; // ==================================================================================== -if (typeof SecurityController === 'undefined') { +if ( typeof SecurityController === 'undefined' ) { var SecurityController = {}; } SecurityController._path = ctxBasePath + '/dwr'; -SecurityController.createGroup = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/createGroup"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'createGroup', p0, callback); +SecurityController.createGroup = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/createGroup" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'createGroup', p0, callback ); }; -SecurityController.deleteGroup = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/deleteGroup"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'deleteGroup', p0, callback); +SecurityController.deleteGroup = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/deleteGroup" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'deleteGroup', p0, callback ); }; -SecurityController.getAvailableGroups = function (callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getAvailableGroups', callback); +SecurityController.getAvailableGroups = function( callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getAvailableGroups', callback ); }; -SecurityController.getAvailableSids = function (callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getAvailableSids', callback); +SecurityController.getAvailableSids = function( callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getAvailableSids', callback ); }; -SecurityController.getUsersData = function (p0, p1, callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getUsersData', p0, p1, callback); +SecurityController.getUsersData = function( p0, p1, callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getUsersData', p0, p1, callback ); }; -SecurityController.getSecurityInfo = function (p0, callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getSecurityInfo', p0, callback); +SecurityController.getSecurityInfo = function( p0, callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getSecurityInfo', p0, callback ); }; -SecurityController.addUserToGroup = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/addUserToGroup"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'addUserToGroup', p0, p1, callback); +SecurityController.addUserToGroup = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/addUserToGroup" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'addUserToGroup', p0, p1, callback ); }; -SecurityController.removeUsersFromGroup = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/removeUsersFromGroup"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'removeUsersFromGroup', p0, p1, callback); +SecurityController.removeUsersFromGroup = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/removeUsersFromGroup" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'removeUsersFromGroup', p0, p1, callback ); }; -SecurityController.makeGroupReadable = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/makeGroupReadable"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'makeGroupReadable', p0, p1, callback); +SecurityController.makeGroupReadable = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/makeGroupReadable" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'makeGroupReadable', p0, p1, callback ); }; -SecurityController.makeGroupWriteable = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/makeGroupWriteable"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'makeGroupWriteable', p0, p1, callback); +SecurityController.makeGroupWriteable = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/makeGroupWriteable" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'makeGroupWriteable', p0, p1, callback ); }; -SecurityController.makePrivate = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/makePrivate"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'makePrivate', p0, callback); +SecurityController.makePrivate = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/makePrivate" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'makePrivate', p0, callback ); }; -SecurityController.makePublic = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/makePublic"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'makePublic', p0, callback); +SecurityController.makePublic = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/makePublic" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'makePublic', p0, callback ); }; -SecurityController.removeGroupWriteable = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/removeGroupWriteable"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'removeGroupWriteable', p0, p1, callback); +SecurityController.removeGroupWriteable = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/removeGroupWriteable" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'removeGroupWriteable', p0, p1, callback ); }; -SecurityController.removeGroupReadable = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/removeGroupReadable"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'removeGroupReadable', p0, p1, callback); +SecurityController.removeGroupReadable = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/removeGroupReadable" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'removeGroupReadable', p0, p1, callback ); }; -SecurityController.updatePermissions = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/updatePermissions"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'updatePermissions', p0, callback); +SecurityController.updatePermissions = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/updatePermissions" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'updatePermissions', p0, callback ); }; -SecurityController.updatePermission = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SecurityController/updatePermission"); - dwr.engine._execute(SecurityController._path, 'SecurityController', 'updatePermission', p0, callback); +SecurityController.updatePermission = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SecurityController/updatePermission" ); + dwr.engine._execute( SecurityController._path, 'SecurityController', 'updatePermission', p0, callback ); }; -SecurityController.getGroupMembers = function (p0, callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getGroupMembers', p0, callback); +SecurityController.getGroupMembers = function( p0, callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getGroupMembers', p0, callback ); }; -SecurityController.getAvailablePrincipalSids = function (callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getAvailablePrincipalSids', callback); +SecurityController.getAvailablePrincipalSids = function( callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getAvailablePrincipalSids', callback ); }; -SecurityController.getAuthenticatedUserNames = function (callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getAuthenticatedUserNames', callback); +SecurityController.getAuthenticatedUserNames = function( callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getAuthenticatedUserNames', callback ); }; -SecurityController.getAuthenticatedUserCount = function (callback) { - dwr.engine._execute(SecurityController._path, 'SecurityController', 'getAuthenticatedUserCount', callback); +SecurityController.getAuthenticatedUserCount = function( callback ) { + dwr.engine._execute( SecurityController._path, 'SecurityController', 'getAuthenticatedUserCount', callback ); }; // ============================================================================== -if (typeof GeneSetController === 'undefined') { +if ( typeof GeneSetController === 'undefined' ) { var GeneSetController = {}; } GeneSetController._path = ctxBasePath + '/dwr'; -GeneSetController.getGenesInGroup = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getGenesInGroup', p0, p1, callback); +GeneSetController.getGenesInGroup = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getGenesInGroup', p0, p1, callback ); }; -GeneSetController.getGenesIdsInGroup = function (p0, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getGeneIdsInGroup', p0, callback); +GeneSetController.getGenesIdsInGroup = function( p0, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getGeneIdsInGroup', p0, callback ); }; -GeneSetController.load = function (p0, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'load', p0, callback); +GeneSetController.load = function( p0, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'load', p0, callback ); }; -GeneSetController.getGeneSetsByGOId = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getGeneSetsByGO', p0, p1, callback); +GeneSetController.getGeneSetsByGOId = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getGeneSetsByGO', p0, p1, callback ); }; -GeneSetController.update = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/update"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'update', p0, callback); +GeneSetController.update = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/update" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'update', p0, callback ); }; -GeneSetController.updateNameDesc = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/updateNameDesc"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'updateNameDesc', p0, callback); +GeneSetController.updateNameDesc = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/updateNameDesc" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'updateNameDesc', p0, callback ); }; -GeneSetController.updateMembers = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/updateMembers"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'updateMembers', p0, p1, callback); +GeneSetController.updateMembers = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/updateMembers" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'updateMembers', p0, p1, callback ); }; -GeneSetController.updateSessionGroups = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/updateSessionGroups"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'updateSessionGroups', p0, callback); +GeneSetController.updateSessionGroups = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/updateSessionGroups" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'updateSessionGroups', p0, callback ); }; -GeneSetController.updateSessionGroup = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/updateSessionGroup"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'updateSessionGroup', p0, callback); +GeneSetController.updateSessionGroup = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/updateSessionGroup" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'updateSessionGroup', p0, callback ); }; -GeneSetController.updateUserAndSessionGroups = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/updateUserAndSessionGroups"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'updateUserAndSessionGroups', p0, callback); +GeneSetController.updateUserAndSessionGroups = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/updateUserAndSessionGroups" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'updateUserAndSessionGroups', p0, callback ); }; -GeneSetController.create = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/create"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'create', p0, callback); +GeneSetController.create = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/create" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'create', p0, callback ); }; -GeneSetController.addSessionGroups = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'addSessionGroups', p0, p1, callback); +GeneSetController.addSessionGroups = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'addSessionGroups', p0, p1, callback ); }; -GeneSetController.addSessionGroup = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'addSessionGroup', p0, p1, callback); +GeneSetController.addSessionGroup = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'addSessionGroup', p0, p1, callback ); }; -GeneSetController.addUserAndSessionGroups = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/addUserAndSessionGroups"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'addUserAndSessionGroups', p0, callback); +GeneSetController.addUserAndSessionGroups = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/addUserAndSessionGroups" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'addUserAndSessionGroups', p0, callback ); }; -GeneSetController.remove = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/remove"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'remove', p0, callback); +GeneSetController.remove = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/remove" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'remove', p0, callback ); }; -GeneSetController.removeSessionGroups = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/removeSessionGroups"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'removeSessionGroups', p0, callback); +GeneSetController.removeSessionGroups = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/removeSessionGroups" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'removeSessionGroups', p0, callback ); }; -GeneSetController.removeUserAndSessionGroups = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/removeUserAndSessionGroups"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'removeUserAndSessionGroups', p0, callback); +GeneSetController.removeUserAndSessionGroups = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/removeUserAndSessionGroups" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'removeUserAndSessionGroups', p0, callback ); }; -GeneSetController.getUsersGeneGroups = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getUsersGeneGroups', p0, p1, callback); +GeneSetController.getUsersGeneGroups = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getUsersGeneGroups', p0, p1, callback ); }; -GeneSetController.getUserSessionGeneGroups = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getUserSessionGeneGroups', p0, p1, callback); +GeneSetController.getUserSessionGeneGroups = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getUserSessionGeneGroups', p0, p1, callback ); }; -GeneSetController.getUserAndSessionGeneGroups = function (p0, p1, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'getUserAndSessionGeneGroups', p0, p1, callback); +GeneSetController.getUserAndSessionGeneGroups = function( p0, p1, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'getUserAndSessionGeneGroups', p0, p1, callback ); }; -GeneSetController.findGeneSetsByGene = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/findGeneSetsByGene"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'findGeneSetsByGene', p0, callback); +GeneSetController.findGeneSetsByGene = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/findGeneSetsByGene" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'findGeneSetsByGene', p0, callback ); }; -GeneSetController.findGeneSetsByName = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/GeneSetController/findGeneSetsByName"); - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'findGeneSetsByName', p0, p1, callback); +GeneSetController.findGeneSetsByName = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/GeneSetController/findGeneSetsByName" ); + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'findGeneSetsByName', p0, p1, callback ); }; -GeneSetController.canCurrentUserEditGroup = function (p0, callback) { - dwr.engine._execute(GeneSetController._path, 'GeneSetController', 'canCurrentUserEditGroup', p0, callback); +GeneSetController.canCurrentUserEditGroup = function( p0, callback ) { + dwr.engine._execute( GeneSetController._path, 'GeneSetController', 'canCurrentUserEditGroup', p0, callback ); }; // ==================================================================================== -if (typeof SystemMonitorController === 'undefined') { +if ( typeof SystemMonitorController === 'undefined' ) { var SystemMonitorController = {}; } SystemMonitorController._path = ctxBasePath + '/dwr'; -SystemMonitorController.getHibernateStatus = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'getHibernateStatus', callback); +SystemMonitorController.getHibernateStatus = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'getHibernateStatus', callback ); }; -SystemMonitorController.getCacheStatus = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'getCacheStatus', callback); +SystemMonitorController.getCacheStatus = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'getCacheStatus', callback ); }; -SystemMonitorController.clearCache = function (p0, callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'clearCache', p0, callback); +SystemMonitorController.clearCache = function( p0, callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'clearCache', p0, callback ); }; -SystemMonitorController.clearAllCaches = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'clearAllCaches', callback); +SystemMonitorController.clearAllCaches = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'clearAllCaches', callback ); }; -SystemMonitorController.enableStatistics = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'enableStatistics', callback); +SystemMonitorController.enableStatistics = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'enableStatistics', callback ); }; -SystemMonitorController.disableStatistics = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'disableStatistics', callback); +SystemMonitorController.disableStatistics = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'disableStatistics', callback ); }; -SystemMonitorController.resetHibernateStatus = function (callback) { - dwr.engine._execute(SystemMonitorController._path, 'SystemMonitorController', 'resetHibernateStatus', callback); +SystemMonitorController.resetHibernateStatus = function( callback ) { + dwr.engine._execute( SystemMonitorController._path, 'SystemMonitorController', 'resetHibernateStatus', callback ); }; // ==================================================================================== -if (typeof LinkAnalysisController === 'undefined') { +if ( typeof LinkAnalysisController === 'undefined' ) { var LinkAnalysisController = {}; } LinkAnalysisController._path = ctxBasePath + '/dwr'; -LinkAnalysisController.run = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/LinkAnalysisController/run"); - dwr.engine._execute(LinkAnalysisController._path, 'LinkAnalysisController', 'run', p0, callback); +LinkAnalysisController.run = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/LinkAnalysisController/run" ); + dwr.engine._execute( LinkAnalysisController._path, 'LinkAnalysisController', 'run', p0, callback ); }; // ==================================================================================== -if (typeof PreprocessController === 'undefined') { +if ( typeof PreprocessController === 'undefined' ) { var PreprocessController = {}; } PreprocessController._path = ctxBasePath + '/dwr'; -PreprocessController.run = function (p0, callback) { - dwr.engine._execute(PreprocessController._path, - 'PreprocessController', 'run', p0, callback); +PreprocessController.run = function( p0, callback ) { + dwr.engine._execute( PreprocessController._path, + 'PreprocessController', 'run', p0, callback ); }; -PreprocessController.diagnostics = function (p0, callback) { - dwr.engine._execute(PreprocessController._path, - 'PreprocessController', 'diagnostics', p0, callback); +PreprocessController.diagnostics = function( p0, callback ) { + dwr.engine._execute( PreprocessController._path, + 'PreprocessController', 'diagnostics', p0, callback ); }; // ==================================================================================== -if (typeof ProgressStatusService === 'undefined') { +if ( typeof ProgressStatusService === 'undefined' ) { var ProgressStatusService = {}; } ProgressStatusService._path = ctxBasePath + '/dwr'; -ProgressStatusService.getProgressStatus = function (p0, callback) { - dwr.engine._execute(ProgressStatusService._path, 'ProgressStatusService', 'getProgressStatus', p0, callback); +ProgressStatusService.getProgressStatus = function( p0, callback ) { + dwr.engine._execute( ProgressStatusService._path, 'ProgressStatusService', 'getProgressStatus', p0, callback ); }; -ProgressStatusService.getSubmittedTask = function (p0, callback) { - dwr.engine._execute(ProgressStatusService._path, 'ProgressStatusService', 'getSubmittedTask', p0, callback); +ProgressStatusService.getSubmittedTask = function( p0, callback ) { + dwr.engine._execute( ProgressStatusService._path, 'ProgressStatusService', 'getSubmittedTask', p0, callback ); }; -ProgressStatusService.cancelJob = function (p0, callback) { - dwr.engine._execute(ProgressStatusService._path, 'ProgressStatusService', 'cancelJob', p0, callback); +ProgressStatusService.cancelJob = function( p0, callback ) { + dwr.engine._execute( ProgressStatusService._path, 'ProgressStatusService', 'cancelJob', p0, callback ); }; -ProgressStatusService.addEmailAlert = function (p0, callback) { - dwr.engine._execute(ProgressStatusService._path, 'ProgressStatusService', 'addEmailAlert', p0, callback); +ProgressStatusService.addEmailAlert = function( p0, callback ) { + dwr.engine._execute( ProgressStatusService._path, 'ProgressStatusService', 'addEmailAlert', p0, callback ); }; -ProgressStatusService.getSubmittedTasks = function (callback) { - dwr.engine._execute(ProgressStatusService._path, 'ProgressStatusService', 'getSubmittedTasks', callback); +ProgressStatusService.getSubmittedTasks = function( callback ) { + dwr.engine._execute( ProgressStatusService._path, 'ProgressStatusService', 'getSubmittedTasks', callback ); }; // ==================================================================================== -if (typeof TwoChannelMissingValueController === 'undefined') { +if ( typeof TwoChannelMissingValueController === 'undefined' ) { var TwoChannelMissingValueController = {}; } TwoChannelMissingValueController._path = ctxBasePath + '/dwr'; -TwoChannelMissingValueController.run = function (p0, callback) { +TwoChannelMissingValueController.run = function( p0, callback ) { dwr.engine - ._execute(TwoChannelMissingValueController._path, 'TwoChannelMissingValueController', 'run', p0, callback); + ._execute( TwoChannelMissingValueController._path, 'TwoChannelMissingValueController', 'run', p0, callback ); }; -TwoChannelMissingValueController.run = function (p0, callback) { +TwoChannelMissingValueController.run = function( p0, callback ) { dwr.engine - ._execute(TwoChannelMissingValueController._path, 'TwoChannelMissingValueController', 'run', p0, callback); + ._execute( TwoChannelMissingValueController._path, 'TwoChannelMissingValueController', 'run', p0, callback ); }; // ==================================================================================== -if (typeof SvdController === 'undefined') { +if ( typeof SvdController === 'undefined' ) { var SvdController = {}; } SvdController._path = ctxBasePath + '/dwr'; -SvdController.run = function (p0, callback) { - dwr.engine._execute(SvdController._path, 'SvdController', 'run', p0, callback); +SvdController.run = function( p0, callback ) { + dwr.engine._execute( SvdController._path, 'SvdController', 'run', p0, callback ); }; // ==================================================================================== -if (typeof SearchService === 'undefined') { +if ( typeof SearchService === 'undefined' ) { var SearchService = {}; } SearchService._path = ctxBasePath + '/dwr'; -SearchService.ajaxSearch = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/SearchService/search"); - dwr.engine._execute(SearchService._path, 'SearchService', 'ajaxSearch', p0, callback); +SearchService.ajaxSearch = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/SearchService/search" ); + dwr.engine._execute( SearchService._path, 'SearchService', 'ajaxSearch', p0, callback ); }; // ==================================================================================== -if (typeof TaskCompletionController === 'undefined') { +if ( typeof TaskCompletionController === 'undefined' ) { var TaskCompletionController = {}; } TaskCompletionController._path = ctxBasePath + '/dwr'; -TaskCompletionController.checkResult = function (p0, callback) { - dwr.engine._execute(TaskCompletionController._path, 'TaskCompletionController', 'checkResult', p0, callback); +TaskCompletionController.checkResult = function( p0, callback ) { + dwr.engine._execute( TaskCompletionController._path, 'TaskCompletionController', 'checkResult', p0, callback ); }; // ==================================================================================== -if (typeof FeedReader === 'undefined') { +if ( typeof FeedReader === 'undefined' ) { var FeedReader = {}; } FeedReader._path = ctxBasePath + '/dwr'; -FeedReader.getLatestNews = function (callback) { - dwr.engine._execute(FeedReader._path, 'FeedReader', 'getLatestNews', callback); +FeedReader.getLatestNews = function( callback ) { + dwr.engine._execute( FeedReader._path, 'FeedReader', 'getLatestNews', callback ); }; // ==================================================================================== -if (typeof UserListController === 'undefined') { +if ( typeof UserListController === 'undefined' ) { var UserListController = {}; } UserListController._path = ctxBasePath + '/dwr'; -UserListController.getUsers = function (callback) { - dwr.engine._execute(UserListController._path, 'UserListController', 'getUsers', callback); +UserListController.getUsers = function( callback ) { + dwr.engine._execute( UserListController._path, 'UserListController', 'getUsers', callback ); }; -UserListController.saveUser = function (p0, callback) { - dwr.engine._execute(UserListController._path, 'UserListController', 'saveUser', p0, callback); +UserListController.saveUser = function( p0, callback ) { + dwr.engine._execute( UserListController._path, 'UserListController', 'saveUser', p0, callback ); }; // ===================================================================================== -if (typeof LinkOutController === 'undefined') { +if ( typeof LinkOutController === 'undefined' ) { var LinkOutController = {}; } LinkOutController._path = ctxBasePath + '/dwr'; -LinkOutController.getAllenBrainAtlasLink = function (p0, callback) { - dwr.engine._execute(LinkOutController._path, 'LinkOutController', 'getAllenBrainAtlasLink', p0, callback); +LinkOutController.getAllenBrainAtlasLink = function( p0, callback ) { + dwr.engine._execute( LinkOutController._path, 'LinkOutController', 'getAllenBrainAtlasLink', p0, callback ); }; // ===================================================================================== -if (typeof PhenotypeController === 'undefined') { +if ( typeof PhenotypeController === 'undefined' ) { var PhenotypeController = {}; } PhenotypeController._path = ctxBasePath + '/dwr'; -PhenotypeController.findEvidenceByFilters = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/findEvidenceByFilters"); +PhenotypeController.findEvidenceByFilters = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/findEvidenceByFilters" ); dwr.engine - ._execute(PhenotypeController._path, 'PhenotypeController', 'findEvidenceByFilters', p0, p1, p2, callback); + ._execute( PhenotypeController._path, 'PhenotypeController', 'findEvidenceByFilters', p0, p1, p2, callback ); }; -PhenotypeController.findCandidateGenes = function (p0, p1, p2, p3, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/findCandidateGenes"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findCandidateGenes', p0, p1, p2, p3, - callback); +PhenotypeController.findCandidateGenes = function( p0, p1, p2, p3, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/findCandidateGenes" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findCandidateGenes', p0, p1, p2, p3, + callback ); }; -PhenotypeController.findExperimentCategory = function (callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findExperimentCategory', callback); +PhenotypeController.findExperimentCategory = function( callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findExperimentCategory', callback ); }; -PhenotypeController.calculateExternalDatabasesStatistics = function (callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/calculateExternalDatabasesStatistics"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'calculateExternalDatabasesStatistics', - callback); +PhenotypeController.calculateExternalDatabasesStatistics = function( callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/calculateExternalDatabasesStatistics" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'calculateExternalDatabasesStatistics', + callback ); }; -PhenotypeController.findExperimentOntologyValue = function (p0, p1, p2, callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findExperimentOntologyValue', p0, p1, p2, - callback); +PhenotypeController.findExperimentOntologyValue = function( p0, p1, p2, callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findExperimentOntologyValue', p0, p1, p2, + callback ); }; -PhenotypeController.findEvidenceOwners = function (callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findEvidenceOwners', callback); +PhenotypeController.findEvidenceOwners = function( callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findEvidenceOwners', callback ); }; -PhenotypeController.loadAllPhenotypesByTree = function (p0, p1, p2, callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'loadAllPhenotypesByTree', p0, p1, p2, - callback); +PhenotypeController.loadAllPhenotypesByTree = function( p0, p1, p2, callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'loadAllPhenotypesByTree', p0, p1, p2, + callback ); }; -PhenotypeController.searchOntologyForPhenotypes = function (p0, p1, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/searchOntologyForPhenotypes"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'searchOntologyForPhenotypes', p0, p1, - callback); +PhenotypeController.searchOntologyForPhenotypes = function( p0, p1, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/searchOntologyForPhenotypes" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'searchOntologyForPhenotypes', p0, p1, + callback ); }; -PhenotypeController.findBibliographicReference = function (p0, p1, callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findBibliographicReference', p0, p1, - callback); +PhenotypeController.findBibliographicReference = function( p0, p1, callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findBibliographicReference', p0, p1, + callback ); }; -PhenotypeController.processPhenotypeAssociationForm = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/processPhenotypeAssociationForm"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'processPhenotypeAssociationForm', p0, - callback); +PhenotypeController.processPhenotypeAssociationForm = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/processPhenotypeAssociationForm" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'processPhenotypeAssociationForm', p0, + callback ); }; -PhenotypeController.validatePhenotypeAssociationForm = function (p0, callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'validatePhenotypeAssociationForm', p0, - callback); +PhenotypeController.validatePhenotypeAssociationForm = function( p0, callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'validatePhenotypeAssociationForm', p0, + callback ); }; -PhenotypeController.removePhenotypeAssociation = function (p0, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/removePhenotypeAssociation"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'removePhenotypeAssociation', p0, callback); +PhenotypeController.removePhenotypeAssociation = function( p0, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/removePhenotypeAssociation" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'removePhenotypeAssociation', p0, callback ); }; -PhenotypeController.makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis = function (p0, p1, p2, callback) { - googleAnalyticsTrackPageviewIfConfigured("/Gemma/PhenotypeController/makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis"); - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', - 'makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis', p0, p1, p2, callback); +PhenotypeController.makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis = function( p0, p1, p2, callback ) { + googleAnalyticsTrackPageviewIfConfigured( "/Gemma/PhenotypeController/makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis" ); + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', + 'makeDifferentialExpressionEvidencesFromDiffExpressionMetaAnalysis', p0, p1, p2, callback ); }; -PhenotypeController.removeAllEvidenceFromMetaAnalysis = function (p0, callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'removeAllEvidenceFromMetaAnalysis', p0, - callback); +PhenotypeController.removeAllEvidenceFromMetaAnalysis = function( p0, callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'removeAllEvidenceFromMetaAnalysis', p0, + callback ); }; -PhenotypeController.findExternalDatabaseName = function (callback) { - dwr.engine._execute(PhenotypeController._path, 'PhenotypeController', 'findExternalDatabaseName', callback); +PhenotypeController.findExternalDatabaseName = function( callback ) { + dwr.engine._execute( PhenotypeController._path, 'PhenotypeController', 'findExternalDatabaseName', callback ); }; // ===================================================================================== -if (typeof JavascriptLogger === 'undefined') { +if ( typeof JavascriptLogger === 'undefined' ) { var JavascriptLogger = {}; } JavascriptLogger._path = ctxBasePath + '/dwr'; -JavascriptLogger.writeToLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToLog', p0, p1, p2, p3, p4, callback ); }; -JavascriptLogger.writeToDebugLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToDebugLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToDebugLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToDebugLog', p0, p1, p2, p3, p4, callback ); }; -JavascriptLogger.writeToInfoLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToInfoLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToInfoLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToInfoLog', p0, p1, p2, p3, p4, callback ); }; -JavascriptLogger.writeToWarnLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToWarnLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToWarnLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToWarnLog', p0, p1, p2, p3, p4, callback ); }; -JavascriptLogger.writeToErrorLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToErrorLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToErrorLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToErrorLog', p0, p1, p2, p3, p4, callback ); }; -JavascriptLogger.writeToFatalLog = function (p0, p1, p2, p3, p4, callback) { - dwr.engine._execute(JavascriptLogger._path, 'JavascriptLogger', 'writeToFatalLog', p0, p1, p2, p3, p4, callback); +JavascriptLogger.writeToFatalLog = function( p0, p1, p2, p3, p4, callback ) { + dwr.engine._execute( JavascriptLogger._path, 'JavascriptLogger', 'writeToFatalLog', p0, p1, p2, p3, p4, callback ); }; // ==================================================================================== -if (typeof SignupController === 'undefined') { +if ( typeof SignupController === 'undefined' ) { var SignupController = {}; } SignupController._path = ctxBasePath + '/dwr'; -SignupController.loginCheck = function (callback) { - dwr.engine._execute(SignupController._path, 'SignupController', 'loginCheck', callback); +SignupController.loginCheck = function( callback ) { + dwr.engine._execute( SignupController._path, 'SignupController', 'loginCheck', callback ); }; // ==================================================================================== diff --git a/gemma-web/src/main/webapp/scripts/api/eeDesignMatrix.js b/gemma-web/src/main/webapp/scripts/api/eeDesignMatrix.js index 624936d056..658bfbea9b 100755 --- a/gemma-web/src/main/webapp/scripts/api/eeDesignMatrix.js +++ b/gemma-web/src/main/webapp/scripts/api/eeDesignMatrix.js @@ -65,11 +65,9 @@ var DesignMatrix = { this.grid = new Ext.grid.GridPanel( { ds : this.ds, cm : cm, - // collapsible : true, title : "Experimental Design overview", renderTo : "eeDesignMatrix", height : height, - // width : 600, viewConfig : { forceFit : true } diff --git a/gemma-web/src/main/webapp/scripts/api/entities/GemmaNavigationHeader.js b/gemma-web/src/main/webapp/scripts/api/entities/GemmaNavigationHeader.js index 820318a04c..b6b4d23fc7 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/GemmaNavigationHeader.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/GemmaNavigationHeader.js @@ -539,7 +539,7 @@ Gemma.GemmaNavigationHeader = Ext autoEl : { tag : 'a', href : ctxBasePath + '/home.html', - cn : '' + cn : 'Gemma Logo' } }, { @@ -588,7 +588,7 @@ Gemma.GemmaNavigationHeader = Ext autoEl : { tag : 'a', href : 'https://www.ubc.ca/', - cn : '', + cn : 'UBC Logo', style : 'padding-left:15px; padding-right:10px' } } ] ); diff --git a/gemma-web/src/main/webapp/scripts/api/entities/analysis/differentialExpression/DifferentialExpressionAnalysesSummaryTree.js b/gemma-web/src/main/webapp/scripts/api/entities/analysis/differentialExpression/DifferentialExpressionAnalysesSummaryTree.js index 6a780c3f1b..68e10c478e 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/analysis/differentialExpression/DifferentialExpressionAnalysesSummaryTree.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/analysis/differentialExpression/DifferentialExpressionAnalysesSummaryTree.js @@ -137,6 +137,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext var analysisName = null; var analysisNameExtra = null; var nodeText = ''; + var primaryFactorID = null; // if analysis has only one result set, don't give // it children and // put all info in parent node @@ -144,6 +145,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext resultSet = analysis.resultSets[0]; // get experimental factor string and build analysis parent node text analysisName = this.getFactorNameText(analysis, resultSet); + primaryFactorID = this.getPrimaryFactorID(analysis, resultSet); analysisNameExtra = this.getFactorNameExtra(analysis, resultSet); nodeText = ''; // if there's subset text, add baseline and @@ -152,10 +154,10 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext // FIXME if (subsetText !== '') { subsetText += this.getBaseline(resultSet); - subsetText += this.getActionLinks(resultSet, analysisName[0], this.ee.id, nodeId); + subsetText += this.getActionLinks(resultSet, analysisName[0], this.ee.id, primaryFactorID, nodeId); } else { nodeText += this.getBaseline(resultSet); - nodeText += this.getActionLinks(resultSet, analysisName[0], this.ee.id, nodeId); + nodeText += this.getActionLinks(resultSet, analysisName[0], this.ee.id, primaryFactorID, nodeId); } parentText = '' @@ -185,6 +187,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext // node text analysisName = this.getFactorNameText(analysis, resultSet); analysisNameExtra = this.getFactorNameExtra(analysis, resultSet); + primaryFactorID = this.getPrimaryFactorID(analysis, resultSet); var factor = analysisName[0]; interaction += analysisName[1]; @@ -199,7 +202,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext nodeText = ''; nodeText += this.getBaseline(resultSet); - nodeText += this.getActionLinks(resultSet, factor, this.ee.id, (nodeId + 1)); + nodeText += this.getActionLinks(resultSet, factor, this.ee.id, primaryFactorID,(nodeId + 1)); // make child nodes for each analysis and // add them to parent @@ -437,7 +440,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext // across all opened windows. return this.getId() + 'Experiment' + eeId + 'Chart' + nodeId + 'Div'; }, - getActionLinks: function (resultSet, factor, eeID, nodeId) { + getActionLinks: function ( resultSet, factorString, eeID, primaryFactorID, nodeId) { /* link for details */ var numbers = this.getExpressionNumbers(resultSet, nodeId, true); var linkText = ' ' @@ -468,18 +471,16 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext linkText += ''; /* provide link for visualization. */ - var tipText = "View top differentially expressed genes for "" + factor + """; + var tipText = "View top differentially expressed genes for "" + factorString + """; linkText += ' ' - + ""; + + resultSet.resultSetId + '\',\'' + factorString + + '\', \'' + primaryFactorID + '\')"> ' + + ""; var pValueDistImageSize = 16; - var strippedFactorName = Ext.util.Format.stripTags(factor); - // factorName is for backwards compatibility. Deprecated in favor of using the resultSetId. var imageUrl = ctxBasePath + '/expressionExperiment/visualizePvalueDist.html?' + 'id=' + eeID + '&analysisId=' - + resultSet.analysisId + '&rsid=' + resultSet.resultSetId + '&factorName=' + escape(strippedFactorName); - var methodWithArguments = 'showPValueDistributionWindow(\'' + escape(factor) + '\', \'' + imageUrl + + resultSet.analysisId + '&rsid=' + resultSet.resultSetId; + var methodWithArguments = 'showPValueDistributionWindow(\'' + escape(factorString) + '\', \'' + imageUrl + '\');'; // -8px -6px is used as background-position property because the image has gray border. @@ -500,23 +501,35 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext * interaction */ getFactorNameText: function (analysis, resultSet) { - var factor = ''; + var factorText = ''; var interaction = 0; if (resultSet.experimentalFactors === null || resultSet.experimentalFactors.length === 0) { - factor = "n/a"; + factorText = "n/a"; } else { for (var k = 0; k < resultSet.experimentalFactors.length; k++) { var ef = resultSet.experimentalFactors[k]; - if (k > 0 && k < resultSet.experimentalFactors.length) { - factor = factor + " X "; - interaction = interaction + 1; - } - factor = factor + ef.name; + if (ef.type === 'continuous') { + factorText = factorText + ef.name + ': ' + ef.description; + } else { + if ( k > 0 && k < resultSet.experimentalFactors.length ) { + factorText = factorText + " X "; + interaction = interaction + 1; + } + factorText = factorText + ef.name; + } } } - return [factor, interaction]; + return [factorText, interaction]; + }, + + getPrimaryFactorID: function (analysis, resultSet) { + if (resultSet.experimentalFactors === null || resultSet.experimentalFactors.length === 0) { + return null; + } else { + return resultSet.experimentalFactors[0].id; + } }, isContinuousFactor: function (resultSet) { @@ -545,7 +558,7 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext } // for categorical, list the names - var abrLen = 20; + var abrLen = 30; if (ef.type === 'categorical') { for (var m = 0; m < fvu.length; m++) { if (m > 0 && m < fvu.length) { @@ -555,7 +568,8 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext } } else { - // for continuous, show range like "(0 - 10)" + // for continuous, show range like "(0 - 10)" but also the descriptive name. + var name = ef.name; var vals = []; for (var m = 0; m < fvu.length; m++) { vals[m] = fvu[m].factorValue; @@ -568,11 +582,11 @@ Gemma.DifferentialExpressionAnalysesSummaryTree = Ext return a - b; }); - text = Number(vals[0]).toPrecision(2) + " – " + text = ef.description + ': ' + Number(vals[0]).toPrecision(2) + " – " + Number(vals[vals.length - 1]).toPrecision(2); } catch (err) { vals.sort(); // alpha - text = Ext.util.Format.ellipsis(vals[0]) + " – " + text = ef.description + ': ' + Ext.util.Format.ellipsis(vals[0]) + " – " + Ext.util.Format.ellipsis(vals[vals.length - 1], abrLen, true); } } @@ -748,7 +762,7 @@ Ext.reg('differentialExpressionAnalysesSummaryTree', Gemma.DifferentialExpressio * fix for now, should replace visualize 'button' with ext button that calls this function, and move function inside * Gemma.DifferentialExpressionAnalysesSummaryTree */ -function visualizeDiffExpressionHandler(eeid, diffResultId, factorDetails) { +function visualizeDiffExpressionHandler(eeid, diffResultId, factorDetails, factorId) { var visDiffWindow = new Gemma.VisualizationWithThumbsWindow({ thumbnails: false, @@ -764,6 +778,6 @@ function visualizeDiffExpressionHandler(eeid, diffResultId, factorDetails) { }, this); visDiffWindow.show({ - params: [diffResultId, Gemma.DIFFEXVIS_QVALUE_THRESHOLD] + params: [diffResultId, Gemma.DIFFEXVIS_QVALUE_THRESHOLD, factorId] }); } \ No newline at end of file diff --git a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentDetails.js b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentDetails.js index c1a3051a54..c3235f3392 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentDetails.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentDetails.js @@ -747,7 +747,7 @@ Gemma.ExpressionExperimentDetails = Ext baseCls: 'x-plain-panel', bodyStyle: 'padding:10px', defaults: { - bodyStyle: 'vertical-align:top;font-size:12px;color:black', + bodyStyle: 'vertical-align:top;', baseCls: 'x-plain-panel', fieldClass: 'x-bare-field' }, diff --git a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentPage.js b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentPage.js index 57a4e9f20b..23e703b879 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentPage.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentPage.js @@ -32,7 +32,7 @@ function getStatusBadge(faIconClass, colorClass, title, qTip) { function getGeeqBadges(quality, suitability) { var val = ''; val = val + - '' + getGeeqIcon(Number(quality)) + "" + @@ -77,14 +77,15 @@ function roundScore(value, valDecimals) { function getBatchInfoBadges(ee) { var result = ""; - if (ee.batchConfound !== null && ee.batchConfound !== "") { + var hasBatchConfound = ee.batchConfound !== null && ee.batchConfound !== ""; + + if (hasBatchConfound) { result = result + getStatusBadge('exclamation-triangle', 'dark-yellow', 'batch confound', ee.batchConfound); - return result; } // batch status, shown whether we have batch information or not. - if (ee.batchEffect !== null) { + if (!hasBatchConfound && ee.batchEffect !== null) { if (ee.batchEffect === "SINGLETON_BATCHES_FAILURE") { result = result + getStatusBadge('exclamation-triangle', 'dark-yellow', 'unable to batch', Gemma.HelpText.WidgetDefaults.ExpressionExperimentDetails.noBatchesSingletons); } else if (ee.batchEffect === "UNINFORMATIVE_HEADERS_FAILURE") { @@ -96,16 +97,17 @@ function getBatchInfoBadges(ee) { if (ee.batchConfound !== null && ee.batchConfound !== "") { // no-op. } else { - result = result + getStatusBadge('cogs', 'green', 'no batch effect', "Batch information is present, but no substantial effect was detected, so the data are not corrected.") + result = result + getStatusBadge('cogs', 'green', 'negligible batch effect', "Batch information is present, but the batch effect was considered below the threshold for warranting correction") } } else if (ee.batchEffect === "SINGLE_BATCH_SUCCESS" ) { result = result + getStatusBadge('cogs', 'green', 'single batch', "Samples were run in a single batch as far as we can tell"); } else if (ee.batchEffect === "NO_BATCH_INFO") { result = result + getStatusBadge('exclamation-triangle', 'dark-yellow', 'no batch info', Gemma.HelpText.WidgetDefaults.ExpressionExperimentDetails.noBatchInfo); } else if (ee.batchEffect === "BATCH_EFFECT_FAILURE") { - result = result + getStatusBadge( 'exclamation-triangle', 'dark-yellow', 'batch effect', ee.batchEffectStatistics ) + // FIXME I'm not sure we should use this. It just indicates there was a batch effect, but it wasn't corrected for some reason. + result = result + getStatusBadge( 'exclamation-triangle', 'dark-yellow', 'uncorrectable batch effect', "Batch effect may be present but could not be corrected: " + ee.batchConfound ) } else if (ee.batchEffect === "BATCH_EFFECT_UNDETERMINED_FAILURE") { - result = result + getStatusBadge( 'exclamation-triangle', 'dark-yellow', 'undetermined batch effect', 'Batch effect is undetermined, there was likely a problem with the SVD or a missing batch factor.'); + result = result + getStatusBadge( 'exclamation-triangle', 'dark-yellow', 'undetermined batch effect', 'Batch effect could not be determined.'); } else { // unsupported batch effect type result = result + getStatusBadge('exclamation-triangle', 'dark-yellow', ee.batchEffect, 'Unsupported batch effect type') @@ -315,9 +317,8 @@ Gemma.ExpressionExperimentPage = Ext.extend(Ext.TabPanel, { window.open(ctxBasePath + "/experimentalDesign/showExperimentalDesign.html?eeid=" + experimentDetails.id); } }], - html: batchInfo + '
Loading...
', + html: batchInfo + "Continuous factors are not shown in this view " + '
Loading...
', layout: 'absolute', - // items -> bar chart and table? listeners: { render: function () { DesignMatrix.init({ @@ -367,20 +368,6 @@ Gemma.ExpressionExperimentPage = Ext.extend(Ext.TabPanel, { makeDiagnosticsTab: function (experimentDetails, isAdmin) { -// removed; update diagnostics from the admin tab instead -// var refreshDiagnosticsLink = ''; -// if (this.editable || isAdmin) { -// refreshDiagnosticsLink = 'Refresh
'; -// } -// this.refreshDiagnosticsBtn = new Ext.Button({ -// icon: ctxBasePath + '/images/icons/arrow_refresh_small.png', -// text: 'Refresh diagnostics', -// handler: function () { -// window.location = "refreshDiagnostics.html?id=" + experimentDetails.id; -// }, -// hidden: (this.editable || isAdmin) -// }); var metaRow = new Ext.Panel( { diff --git a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentSetSummary.js b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentSetSummary.js index e293301914..0cc41797bc 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentSetSummary.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentSetSummary.js @@ -244,7 +244,7 @@ Gemma.ExpressionExperimentSetSummary = Ext baseCls : 'x-plain-panel', bodyStyle : 'padding:10px', defaults : { - bodyStyle : 'vertical-align:top;font-size:12px;color:black', + bodyStyle : 'vertical-align:top;', baseCls : 'x-plain-panel', fieldClass : 'x-bare-field' }, diff --git a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentTools.js b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentTools.js index 478fb537e9..f26c4e8252 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentTools.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentTools.js @@ -96,7 +96,7 @@ Gemma.ExpressionExperimentTools = Ext.extend(Gemma.CurationTools, { leftPanel.add({html: "

Analyses:

"}); leftPanel.add(this.differentialAnalysisPanelRenderer(this.experimentDetails, manager)); - leftPanel.add(this.linkAnalysisPanelRenderer(this.experimentDetails, manager)); + // leftPanel.add(this.linkAnalysisPanelRenderer(this.experimentDetails, manager)); eeRow.add(leftPanel); @@ -1223,6 +1223,16 @@ Gemma.ExpressionExperimentTools = Ext.extend(Gemma.CurationTools, { html: 'Differential Expression Analysis: ' }] }); + + if (!ee.suitableForDEA) { + var color = "#000"; + panel.add({ + html: '' + + 'Not suitable' + ' ' + }); + return panel; + } + var id = ee.id; var runBtn = new Ext.Button({ text: '', @@ -1231,6 +1241,8 @@ Gemma.ExpressionExperimentTools = Ext.extend(Gemma.CurationTools, { scope: this, cls: 'btn-refresh' }); + + if (ee.numPopulatedFactors > 0) { if (ee.dateDifferentialAnalysis) { var type = ee.differentialAnalysisEventType; @@ -1238,10 +1250,7 @@ Gemma.ExpressionExperimentTools = Ext.extend(Gemma.CurationTools, { var color = "#000"; var suggestRun = true; var qtip = 'ext:qtip="OK"'; - if (type == 'FailedDifferentialExpressionAnalysisEvent') { // note: - // no - // such - // thing. + if (type == 'FailedDifferentialExpressionAnalysisEvent') { color = 'red'; qtip = 'ext:qtip="Failed"'; } diff --git a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentsSummaryPanel.js b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentsSummaryPanel.js index 5a80b31f15..bc8eee3244 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentsSummaryPanel.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/experiment/ExpressionExperimentsSummaryPanel.js @@ -59,7 +59,7 @@ Gemma.ExpressionExperimentsSummaryPanel = Ext.extend( Ext.Panel, // this is so long because it is lifted from the original version of the summary table tpl : new Ext.XTemplate( - '
' + '
' + '
' + '
' + '
' @@ -76,26 +76,26 @@ Gemma.ExpressionExperimentsSummaryPanel = Ext.extend( Ext.Panel, + '
' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' + '' diff --git a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneDetailsTab.js b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneDetailsTab.js index 462437ba14..bcfd923601 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneDetailsTab.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneDetailsTab.js @@ -337,7 +337,7 @@ Gemma.GeneDetails = Ext.extend(Ext.Panel, { this.loadMask.hide(); this.add([ { - html: '
' + html: '
' + geneDetails.name + '
' + geneDetails.officialName diff --git a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetPreview.js b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetPreview.js index 9f5bbfecd2..f3fb0ea512 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetPreview.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetPreview.js @@ -84,7 +84,7 @@ Gemma.GeneSetPreview = Ext.extend(Gemma.SetPreview, { var selectedSet = this.selectedSetValueObject; if (!selectedSet) { - this.previewContent.setTitle('' + 'No selection' + this.previewContent.setTitle('' + 'No selection' + '   (0 genes)'); return; } diff --git a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetSummary.js b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetSummary.js index 6206fa6f4f..12f6ac4041 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetSummary.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/gene/GeneSetSummary.js @@ -241,7 +241,7 @@ Gemma.GeneSetSummary = Ext baseCls : 'x-plain-panel', bodyStyle : 'padding:10px', defaults : { - bodyStyle : 'vertical-align:top;font-size:12px;color:black', + bodyStyle : 'vertical-align:top;', baseCls : 'x-plain-panel', fieldClass : 'x-bare-field' }, diff --git a/gemma-web/src/main/webapp/scripts/api/entities/phenotype/form/GeneSearchComboBox.js b/gemma-web/src/main/webapp/scripts/api/entities/phenotype/form/GeneSearchComboBox.js index ce14424ca6..6c3295f8d5 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/phenotype/form/GeneSearchComboBox.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/phenotype/form/GeneSearchComboBox.js @@ -24,7 +24,7 @@ Gemma.PhenotypeAssociationForm.GeneSearchComboBox = Ext { name : 'comboText', convert : function( value, record ) { - return '
' + record.officialName + return '
' + record.officialName + ' (' + record.taxonCommonName + ')
'; } } ], diff --git a/gemma-web/src/main/webapp/scripts/api/entities/platform/ArrayDesignsNonPagingGrid.js b/gemma-web/src/main/webapp/scripts/api/entities/platform/ArrayDesignsNonPagingGrid.js index fb62c6e1dd..27c3216d09 100755 --- a/gemma-web/src/main/webapp/scripts/api/entities/platform/ArrayDesignsNonPagingGrid.js +++ b/gemma-web/src/main/webapp/scripts/api/entities/platform/ArrayDesignsNonPagingGrid.js @@ -24,6 +24,10 @@ Gemma.ArrayDesignsStore = Ext.extend( Ext.data.Store, { name : "expressionExperimentCount" }, { name : "summaryTable" + }, { + name : "createDate", + dateFormat : "timestamp", + type : "date" }, { name : "lastSequenceUpdate", dateFormat : "timestamp", @@ -399,6 +403,14 @@ Gemma.ArrayDesignsNonPagingGrid = Ext width : 0.03, tooltip : 'Number of experiments in Gemma that use this design' }, + { + header : "Created", + dataIndex : 'createDate', + width : 0.07, + sortDir : 'DESC', + xtype : 'datecolumn', + format : 'Y-m-d' + }, { header : "Seq. Update", dataIndex : 'lastSequenceUpdate', @@ -706,6 +718,9 @@ Gemma.ArrayDesignsNonPagingGrid = Ext index = this.getColumnModel().findColumnIndex( 'needsAttention' ); colModel.setHidden( index, !isAdmin ); + index = this.getColumnModel().findColumnIndex( 'createDate' ); // maybe we can expose this. + colModel.setHidden( index, !isAdmin ); + if ( !isAdmin ) { this.getStore().activateMultiFilter( 'troubledFilter' ); this.getStore().applyMultiFilters(); diff --git a/gemma-web/src/main/webapp/scripts/api/search/generalSearchSimple.js b/gemma-web/src/main/webapp/scripts/api/search/generalSearchSimple.js index 855f2dfb6e..0fc62ce4bd 100755 --- a/gemma-web/src/main/webapp/scripts/api/search/generalSearchSimple.js +++ b/gemma-web/src/main/webapp/scripts/api/search/generalSearchSimple.js @@ -4,7 +4,6 @@ Ext.BLANK_IMAGE_URL = ctxBasePath + '/images/default/s.gif'; Gemma.Search.GeneralSearchSimple = Ext.extend( Ext.Panel, { layout : 'hbox', height : 60, - width : 500, padding : 5, layoutConfig : { align : 'middle', diff --git a/gemma-web/src/main/webapp/scripts/api/util/GemmaTemplates.js b/gemma-web/src/main/webapp/scripts/api/util/GemmaTemplates.js index 418910cf3c..4388098049 100755 --- a/gemma-web/src/main/webapp/scripts/api/util/GemmaTemplates.js +++ b/gemma-web/src/main/webapp/scripts/api/util/GemmaTemplates.js @@ -2,11 +2,12 @@ Ext.namespace('Gemma.Widget', 'Gemma.Common'); Gemma.Widget.tpl = { ArrayDesignsNonPagingGrid : { - rowDetails : '

Elements: {designElementCount}

' - + '

With sequences: {numProbeSequences} (Number of elements with sequences)

' - + '

With align: {numProbeAlignments} (Number of elements with at least one genome alignment)

' - + '

Mapped to genes: {numProbesToGenes} (Number of elements mapped to at least one gene)

' - + '

Unique genes: {numGenes} (Number of distinct genes represented by the platform)

' + '

(as of {dateCached})

' + rowDetails : 'Elements: {designElementCount}
' + + 'With sequences: {numProbeSequences} (Number of elements with sequences)
' + + 'With align: {numProbeAlignments} (Number of elements with at least one genome alignment)
' + + 'Mapped to genes: {numProbesToGenes} (Number of elements mapped to at least one gene)
' + + 'Unique genes: {numGenes} (Number of distinct genes represented by the platform)
' + + ' (as of {dateCached})' } }; diff --git a/gemma-web/src/main/webapp/scripts/api/visualization/Heatmap.js b/gemma-web/src/main/webapp/scripts/api/visualization/Heatmap.js index 3749c50d8e..849ba64445 100755 --- a/gemma-web/src/main/webapp/scripts/api/visualization/Heatmap.js +++ b/gemma-web/src/main/webapp/scripts/api/visualization/Heatmap.js @@ -447,7 +447,7 @@ var Heatmap = function() { id : "heatmaplabel-" + Ext.id(), tag : 'div', html : " " + rowLabel, - style : "white-space: nowrap" + style : "white-space: nowrap;" }, true ); Ext.DomHelper.applyStyles( text, "position:absolute;top:" + offsety + "px;left:" + (offsetx + 5) + "px" ); } diff --git a/gemma-web/src/main/webapp/styles/.sorting b/gemma-web/src/main/webapp/styles/.sorting index cd5be4a4a6..9c9407d083 100644 --- a/gemma-web/src/main/webapp/styles/.sorting +++ b/gemma-web/src/main/webapp/styles/.sorting @@ -1,3 +1,5 @@ +reset-min.css ext-all.css ext-extra.css +ext-overrides.css antisense/ diff --git a/gemma-web/src/main/webapp/styles/antisense/colors.css b/gemma-web/src/main/webapp/styles/antisense/colors.css new file mode 100644 index 0000000000..0686ab4f6e --- /dev/null +++ b/gemma-web/src/main/webapp/styles/antisense/colors.css @@ -0,0 +1,109 @@ +/* + * Colors + * + * This stylesheet is in process of rewrite to match Vuetify's colors https://vuetifyjs.com/en/styles/colors/#material-colors + * + * + * Color palette: + * #00718f - new dark blue (hue 193) + * #338da5 - medium tint of 193. + * #9cc8d4 - tint of dark blue 193. + * #004f64 - shade of 193. + * #f9f7db - logo background + * ## Logo colors used in spots + * #c84c27 - new dark orange + * #b53825 - new brick red + * #fddb5c - new bright yellow + * #fcb536 - new light orange + * #f47f20 - new medium orange + * + * Older items + * #444 - dark gray (text) + * #3e9ade - medium blue (title) + * #b4c24b - lime (header 1) + * #ebf5fc - light cyan (hover text, footer) + * #d7e9f5 - medium cyan (tab) + * #1465b7 - dark blue (tab text, hyperlink) + * #ccc - medium gray (line) + * #f7f7f7 - light gray (form background) + * #f90 - orange (required *) + * + * #003366 - blue + * #CC6633 - orange + */ + +/* Text colors */ + +.gray { + color: #9E9E9E; +} + +.green { + color: #4CAF50; +} + +.gold { + color: #FFEB3B; +} + +.dark-yellow { + color: #FFC107; +} + +.orange { + color: #FF9800; +} + +.red { + color: #F44336; +} + +.gray-red { + color: #8e5a57; +} + +.dark-gray { + color: darkgray; +} + +.gray-blue { + color: #3F51B5; +} + +/* Background colors */ + +.bg-gray { + color: #9E9E9E; +} + +.bg-green { + background-color: #4CAF50; +} + +.bg-gold { + background-color: #FFEB3B; +} + +.bg-dark-yellow { + background-color: #FFC107; +} + +.bg-orange { + background-color: #FF9800; +} + +.bg-red { + background-color: #F44336; +} + +.bg-gray-red { + background-color: #8e5a57; +} + +.bg-dark-gray { + background-color: darkgray; +} + +.bg-gray-blue { + background-color: #3F51B5; +} diff --git a/gemma-web/src/main/webapp/styles/antisense/flex.css b/gemma-web/src/main/webapp/styles/antisense/flex.css new file mode 100644 index 0000000000..3fe2337394 --- /dev/null +++ b/gemma-web/src/main/webapp/styles/antisense/flex.css @@ -0,0 +1,29 @@ +/* flex */ + +/* do not use this to flex, please */ + +/* https://vuetifyjs.com/en/styles/spacing/#spacing */ + +.flex { + display: flex; +} + +.flex-wrap { + flex-wrap: wrap; +} + +.flex-grow { + flex-grow: 1; +} + +.justify-space-between { + justify-content: space-between; +} + +.justify-space-around { + justify-content: space-around; +} + +.align-baseline { + align-items: baseline; +} \ No newline at end of file diff --git a/gemma-web/src/main/webapp/styles/antisense/layout.css b/gemma-web/src/main/webapp/styles/antisense/layout.css index aadfd11bea..4067b77ef5 100644 --- a/gemma-web/src/main/webapp/styles/antisense/layout.css +++ b/gemma-web/src/main/webapp/styles/antisense/layout.css @@ -1,4 +1,5 @@ /* Based on a CSS Framework by Mike Stenhouse of Content with Style */ + /* SITE SPECIFIC LAYOUT */ body { margin: 0; @@ -278,282 +279,12 @@ hr.normal { color: royalblue !important; } -.gq-head { - font-size: 120%; -} - -.gq-head .gq-row { - line-height: 200%; - font-weight: bold; -} - -.gq-head .gq-extra .gq-btn { - top: -10px; -} - -.gq-body { - filter: saturate(70%); - margin: 0; - background: whitesmoke !important; - border-left: 1px solid lightgray; - border-bottom: 1px solid lightgray; - border-right: 1px solid lightgray; -} - -.gq-btn { - width: 100% !important; - padding: 5px; - background: whitesmoke; -} - -.gq-btn:hover { - filter: brightness(90%); -} - -.gq-btn * { - font-size: 106% !important; - cursor: pointer; - background: transparent !important; -} - -.extjs-sucks { - margin: 0; - text-align: center !important; -} - -.extjs-sucks * { - text-align: center !important; -} - -.gq-btn-details { - text-align: left !important; - margin: 0 !important; - width: 100% !important; - background: whitesmoke !important; - /*Looks better when the manual score override UI is enabled*/ - /*border-left: 1px solid lightgray;*/ - /*border-bottom: 1px solid lightgray;*/ - /*border-right: 1px solid lightgray;*/ -} - -.gq-btn-details:hover { - background: lightgray !important; - filter: none; -} - -.gq-btn-details * { - text-align: center !important; - display: inline-block !important; - background: whitesmoke !important; -} - -.gq-btn-details:hover * { - background: lightgray !important; - filter: none; -} - -.gq-btn-save { - border: solid 1px darkgray; - border-radius: 10px; - margin: 10px 5px 5px; - padding: 7px 5px 5px 5px; - width: 50% !important; - background: whitesmoke !important; -} - -.gq-btn-save:hover { - filter: brightness(110%); -} - -.gq-btn-save * { - font-size: 106% !important; - cursor: pointer; - background: whitesmoke !important; -} - -.gq-btn-recalc-all { - text-align: center !important; - font-size: 90% !important; - font-weight: 900 !important; - display: inline-block !important; - padding: 10px; - margin: 20px 0 !important; - width: 90% !important; - box-shadow: 0 0 3px #b9b9b9; -} - -.gq-btn-recalc-all * { - text-align: center !important; - display: inline-block !important; - cursor: pointer !important; -} - -.gq-btn-recalc-all.x-item-disabled { - color: darkgray !important; - background-color: lightgray !important; -} - -.gq-row { - padding: 2px; -} - -.gq-row.has-extra { - margin-bottom: 0; -} - -.gq-row .fa { - margin-left: 5px; -} - -.gq-label { - display: inline-block; - width: 180px; - font-weight: 500; - padding: 0 10px; - text-align: right; -} - -.gq-label:after { - content: ':'; -} - -.gq-value.negative { - margin-left: -5px; -} - -.gq-errors span.icon { - font-size: 300%; - width: 10%; -} - -.gq-errors span.msg { - float: right; - width: 90%; -} - -.gq-errors pre { - padding: 5px; - background: lightgray; - white-space: pre-wrap; -} - -.gq-extra { - box-shadow: inset 0 10px 10px -10px #585858; - text-align: center; - background: lightgray !important; - margin: 0; - padding: 0 5px 5px 5px; -} - -.gq-extra * { - background: transparent; - display: inline-block; -} - -.gq-extra label { - padding-right: 20px; -} - -.gq-extra .gq-btn { - padding: 0; - position: relative; - top: -8px; -} - -.gq-extra .gq-btn * { - color: #747474; -} - -.gq-subscore-refresh-btn { - margin-right: 10px; - padding: 5px; -} - -.gq-override-value-slider { - width: 200px; - margin: 0; - padding: 0; -} - -.gq-override-value-slider .x-slider-end, .x-slider-start { - background: none; -} - -.gq-override-value-slider .x-slider-inner { - height: 5px; - background: gray none; - border-radius: 10px; -} - -.gq-override-value-slider .x-slider-thumb { - background-image: none !important; - background: white; - width: 15px; - height: 15px; - border-radius: 10px; - top: -6px; -} - -.gq-override-value-wrap { - position: relative; - top: 10px; - overflow: visible; - margin-right: 10px; -} - -.gq-override-value { - border: none; - font-size: 105%; - padding: 2px; - text-align: center; -} - -.gq-override-value[disabled] { - filter: grayscale(100%); -} - -.gq-notif, .gq-notif * { - vertical-align: text-bottom !important; - display: inline-block !important; -} - -.gq-notif span { - padding: 5px 10px; - border-radius: 10px; - background-color: royalblue; - color: white; -} - -.gq-notif span:not([hidden]) { - opacity: 1; -} - -.gq-notif span[hidden] { - opacity: 0; - transition: opacity 1s linear; -} .folded { height: 5px; overflow: hidden; } -.x-form-item { - padding-left: 5px; - width: 100%; - text-align: left; - vertical-align: bottom; -} - -.x-form-item:nth-child(odd) { - /* border-bottom: solid 1px #eeeeee; */ - background: #f4f4f4; -} - -.x-form-item:nth-child(odd) *:not(textarea):not(.ee-status-badge):not(.fa):not(.security-link) { - background: #f4f4f4; -} - i[class*=qtp] { font-size: medium; color: #8793b9; @@ -628,73 +359,6 @@ i[class*=icon] { font-style: normal; } -/* Text colors */ - -.green { - color: #3A3; -} - -.gold { - color: gold; -} - -.dark-yellow { - color: #c39800; -} - -.orange { - color: #ff8700; -} - -.red { - color: #DD2222; -} - -.gray-red { - color: #8e5a57; -} - -.dark-gray { - color: darkgray; -} - -.gray-blue { - color: #3b5a82; -} - -/* Background colors */ - -.bg-green { - background-color: #3A3; -} - -.bg-gold { - background-color: gold; -} - -.bg-dark-yellow { - background-color: #c39800; -} - -.bg-orange { - background-color: #ff8700; -} - -.bg-red { - background-color: #DD2222; -} - -.bg-gray-red { - background-color: #8e5a57; -} - -.bg-dark-gray { - background-color: darkgray; -} - -.bg-gray-blue { - background-color: #3b5a82; -} /* Other */ diff --git a/gemma-web/src/main/webapp/styles/antisense/responsive.css b/gemma-web/src/main/webapp/styles/antisense/responsive.css new file mode 100644 index 0000000000..df202e2790 --- /dev/null +++ b/gemma-web/src/main/webapp/styles/antisense/responsive.css @@ -0,0 +1,107 @@ +/* a responsive mini-framework inspired by Bootstrap 5 https://getbootstrap.com/docs/5.0/ */ + +/* xs screen */ +.container { + margin: 0 auto; + padding: 0 1.25em; +} + +.d-sm { + display: none; +} + +.d-sm-inline { + display: inline; +} + +.d-md { + display: none; +} + +.d-md-inline { + display: none; +} + +.d-lg { + display: none; +} + +.d-lg-inline { + display: none; +} + +.d-xl { + display: none; +} + +.d-xl-inline { + display: none; +} + +/* small screens */ +@media (min-width: 576px) { + .container { + width: calc(576px - 2 * 1.25em); + } + + .d-sm { + display: block; + } + + .d-sm-inline { + display: inline; + } +} + +/* medium screen */ +@media (min-width: 768px) { + .container { + width: calc(768px - 2 * 1.25em); + } + + .d-md { + display: block; + } + + .d-md-inline { + display: inline; + } + + .flex-md-nowrap { + flex-wrap: nowrap; + } +} + +/* large screens */ +@media (min-width: 992px) { + .container { + width: calc(992px - 2 * 1.25em); + } + + .d-lg { + display: block; + } + + .d-lg-inline { + display: inline; + } + + .flex-lg-nowrap { + flex-wrap: nowrap; + } +} + +/* xl screens */ +@media (min-width: 1200px) { + .container { + width: calc(1200px - 2 * 1.25em); + } + + .d-xl { + display: block; + } + + .d-xl-inline { + display: inline; + } +} diff --git a/gemma-web/src/main/webapp/styles/antisense/spacing.css b/gemma-web/src/main/webapp/styles/antisense/spacing.css new file mode 100644 index 0000000000..edc6adf700 --- /dev/null +++ b/gemma-web/src/main/webapp/styles/antisense/spacing.css @@ -0,0 +1,34 @@ +/* spacing */ + +/* https://vuetifyjs.com/en/styles/spacing/#spacing */ + +/* paddings */ + +.px-3 { + padding-left: 1em; + padding-right: 1em; +} + +/* margins */ + +.mt-10 { + margin-top: 2.5em; +} + +.mb-3 { + margin-bottom: 1em; +} + +.mb-10 { + margin-bottom: 2.5em; +} + +.g-3 { + gap: 0.75em; +} + +/* gaps */ + +.g-5 { + gap: 1.25em; +} diff --git a/gemma-web/src/main/webapp/styles/antisense/typo.css b/gemma-web/src/main/webapp/styles/antisense/typo.css index 0211e642ea..84cea426b9 100644 --- a/gemma-web/src/main/webapp/styles/antisense/typo.css +++ b/gemma-web/src/main/webapp/styles/antisense/typo.css @@ -1,41 +1,21 @@ -/* A CSS Framework by Mike Stenhouse of Content with Style - - Color palette: - #00718f - new dark blue (hue 193) - #338da5 - medium tint of 193. - #9cc8d4 - tint of dark blue 193. - #004f64 - shade of 193. - #f9f7db - logo background - ## Logo colors used in spots - #c84c27 - new dark orange - #b53825 - new brick red - #fddb5c - new bright yellow - #fcb536 - new light orange - #f47f20 - new medium orange - - Older items - #444 - dark gray (text) - #3e9ade - medium blue (title) - #b4c24b - lime (header 1) - #ebf5fc - light cyan (hover text, footer) - #d7e9f5 - medium cyan (tab) - #1465b7 - dark blue (tab text, hyperlink) - #ccc - medium gray (line) - #f7f7f7 - light gray (form background) - #f90 - orange (required *) - - #003366 - blue - #CC6633 - orange -*/ /* TYPOGRAPHY */ +/* + * This stylesheet is in process of rewrite to match Vuetify's typography + */ + +/* A CSS Framework by Mike Stenhouse of Content with Style */ + +/* TYPOGRAPHY */ body { - text-align: left; - font: normal 0.9em arial, sans-serif; - color: #000000; + font-family: Avenir, Helvetica, Arial, sans-serif; + font-size: 16px; + font-size-adjust: none; + line-height: normal; + color: rgba(0, 0, 0, 0.87); text-decoration: none; } .footer { - font-size: smaller; + font-size: x-small; } img { @@ -43,21 +23,16 @@ img { } /* LINKS */ -a,a:link a:active { - color: #004f64; +a, a:link a:active { + color: #1976d2; text-decoration: none; } a:visited { - color: #004f64; + color: #1976d2; background-color: transparent; } -a:hover { - color: #f47f20; - text-decoration: none; -} - .ui-state-hover { background: lightyellow; } @@ -71,105 +46,101 @@ a.annotationLink { } a.newpage { - background: transparent url(../../images/icons/newwindow.png) no-repeat - scroll right center; + background: transparent url(../../images/icons/newwindow.png) no-repeat scroll right center; padding-right: 15px; } a.external { - background: transparent url(../../images/icons/link_external_icon.gif) - no-repeat scroll right center; + background: transparent url(../../images/icons/link_external_icon.gif) no-repeat scroll right center; padding-left: 15px; padding-right: 10px; } a.external:hover { - background: transparent - url(../../images/icons/link_external_icon_hover.gif) no-repeat scroll - right center; + background: transparent url(../../images/icons/link_external_icon_hover.gif) no-repeat scroll right center; padding-left: 15px; margin-right: 10px; } a.internal { - background: transparent url(../../images/icons/link_internal_icon.gif) - no-repeat scroll right center; + background: transparent url(../../images/icons/link_internal_icon.gif) no-repeat scroll right center; padding-left: 15px; margin-right: 10px; } a.internal:hover { - background: transparent - url(../../images/icons/link_internal_icon_hover.gif) no-repeat scroll - right center; + background: transparent url(../../images/icons/link_internal_icon_hover.gif) no-repeat scroll right center; padding-left: 15px; margin-right: 10px; } span.link { cursor: pointer; - text-decoration: underline; - color: #004f64; + color: #1976d2; } /* END LINKS */ /* HEADINGS */ -h1,h2,h3,h4,h5,h6 { +h1, h2, h3, h4, h5, h6 { font-weight: bold; } -h1,.big { - font-size: 2.2em; - letter-spacing: -1px; - line-height: 1.3em; - margin: 0 0 0.5em 0; - padding: 0; +h1 { + font-size: 6em; } -h2,.medium { - font-size: 1.6em; - line-height: 1.4em; - margin: 0 0 0.5em 0; - padding: 0; +h2 { + font-size: 3.75em; } h3 { - font-size: 1.3em; - line-height: 1.3em; - margin: 0 0 0.5em 0; - padding: 10px 0px 0px 0; - color: black; + font-size: 3em; } h4 { - font-size: 1.2em; - line-height: 1.3em; - margin: 0 0 0.25em 0; - padding: 0; - color: black; + font-size: 2.125em; } h5 { - font-size: 1.1em; - line-height: 1.3em; - margin: 0 0 0.25em 0; - padding: 0; - color: black; + font-size: 1.5em; } h6 { - font-size: 1em; - line-height: 1.3em; - margin: 0 0 0.25em 0; - padding: 0; - color: black; + font-size: 1.25em; +} + +/* rescale headers within the main content */ +/* h1 -> h4, h2 -> h5, etc. */ +#main h1 { + font-size: 1.5em; +} + +#main h2, #main h3, #main h4, #main h5, #main h6 { + font-size: 1.25em; } /* END HEADINGS */ /* TEXT */ p { + margin-bottom: 1em; +} + +.bigger { + font-size: 1.5em; +} + +.big { + font-size: 1.25em; +} + +.normal { font-size: 1em; - margin: 0 0 0.8em 0; - padding: 0px 0px 0px 0px; - line-height: 1.4em; +} + +.small { + font-size: 0.875em; +} + +.smaller { + font-size: 0.75em; } blockquote { @@ -178,43 +149,38 @@ blockquote { } pre { - font-family: monospace; - font-size: 1em; + font-family: monospace, monospace; } -strong,b { +strong, b { font-weight: bold; } -em,i { +em, i { font-style: italic; } code { - font-family: "courier new", courier, monospace; - font-size: 12px; + font-family: monospace, monospace; white-space: pre; } textarea { - font-family: verdana, arial, helvetica, sans-serif; - font-size: 1em; + font-family: Avenir, Helvetica, Arial, sans-serif; } -.clob,.stacktrace { +.clob, .stacktrace { border-style: solid; padding: 4px 6px 4px 6px; border-width: 1px; border-color: #DDDDDD; - font-size: 1em; line-height: 1.3em; height: 100px; overflow: auto; } .stacktrace { - font-size: 10px; - font-family: "courier new", courier, monospace; + font-family: monospace, monospace; height: 400px; } @@ -229,10 +195,6 @@ p.emphasized { padding: 0; } -p a { - text-decoration: underline; -} - ul.plainList { margin-left: 40px; margin-bottom: 15px; @@ -271,16 +233,17 @@ dl dd { /* END LISTS */ /* TABLE */ td { - font: normal 11px arial, tahoma, helvetica, sans-serif; + font-weight: normal; } /* this can interfere with EXT.js tables. */ -table { /*border-style:solid; - border-width:1px; - border-color:#BBBBBB; - margin: 0 0 0 0; - padding: 6px;*/ - +table { + /*border-style:solid; + border-width:1px; + border-color:#BBBBBB; + margin: 0 0 0 0; + padding: 6px;*/ + } td.label { @@ -293,7 +256,7 @@ td.label { th { border-bottom: solid #555555 1px; - font: bold 11px arial, tahoma, helvetica, sans-serif; + font-weight: bold; } hr { @@ -307,55 +270,29 @@ div.hr { } .error { - background: #fff url(../../images/default/grid/invalid_line.gif) - repeat-x bottom; + background: #fff url(../../images/default/grid/invalid_line.gif) repeat-x bottom; } /* Help pages */ -h2.helpstep,h3.helpstep { +h2.helpstep, h3.helpstep { left-margin: 0px; padding: 0px; line-height: 1em; font-size: 1.3em; - margin: 0 0 2 0px; -} - -.x-form-field-wrap .x-go-trigger { - background-image: url(../../images/icons/search-trigger.gif); - cursor: pointer; -} - -.x-loading { - background: url(../../images/default/tree/loading.gif) no-repeat center; -} - -/* used by CollapsedPanelTitlePlugin.js, style based on ext-all.css x-panel-header */ -.x-panel-collapsed-text { - /* see .front-page-header-text - color: #15428B; - font: bold 11px tahoma, arial, verdana, sans-serif;*/ - padding: 5px 3px 4px 5px; - float: right; - line-height: 13px; + margin: 0 0 2px 0px; } .blue-text-not-link { - color: #15428B; + color: #2196F3; } .front-page-header-text { - color: #15428B; - font: 18px tahoma, arial, verdana, sans-serif; -} - -/* reduced font size elements */ -.small { - font-size: smaller; + color: #3F51B5; } /* css for scriptaculous hovering */ .drophover { - background-color: #ff0; + background-color: #FFEB3B; } .dragItem { @@ -372,20 +309,20 @@ a.info { /* colours for positive and negative link counts*/ .positiveLink { - color: darkgreen; + color: #4CAF50; } .negativeLink { - color: red; + color: #F44336; } /* colours for validation/trouble */ .trouble { - color: red; + color: #F44336; } .validated { - color: darkgreen; + color: #4CAF50; } .disabled { @@ -399,13 +336,13 @@ a.info { /* colours for characteristics */ .usedWithUri { - color: darkgreen; + color: #4CAF50; font-weight: bold; } .usedNoUri { /* font-weight: bold; */ - + } .unusedWithUri { @@ -413,33 +350,35 @@ a.info { } .unusedNoUri { - + } /* sources of annotations */ .fromBioMaterial { - background-color:#d1e4fd; - padding:3px; + background-color: #d1e4fd; + padding: 3px; line-height: 1.5em; - border-radius:15px; + border-radius: 15px; } + .fromFactorValue { - background-color:#F0DE7D; - padding:3px; + background-color: #F0DE7D; + padding: 3px; line-height: 1.5em; - border-radius:15px; + border-radius: 15px; } + .fromExperimentTag { font-weight: bold; - background-color:#B0DE78; - padding:3px; + background-color: #B0DE78; + padding: 3px; line-height: 1.5em; - border-radius:15px; + border-radius: 15px; } a.info:hover { z-index: 25; - background-color: #ff0; + background-color: #FFEB3B; } a.info span { @@ -458,12 +397,6 @@ a.info:hover span { /*the span will display just on :hover state*/ text-align: center; } -/* make sure link text is white when selected in Ext tables - */ -.x-grid-row-selected a { - color: white !important; -} - /* tooltips, modified from http://psacake.com/web/jl.asp */ a.tooltip { @@ -503,115 +436,14 @@ a.tooltip:hover .tooltiptext { */ .metThreshold { font-weight: bold; - color: #339900; + color: #4CAF50; } /* * for display of search results, see search.js */ .search-result-body { /*font-style: italic; */ - -} - -/* - * FileUploadField component styles - */ -.x-form-file-wrap { - position: relative; - height: 22px; -} - -.x-form-file-wrap .x-form-file { - position: absolute; - right: 0; - -moz-opacity: 0; - filter: alpha(opacity : 0); - opacity: 0; - z-index: 2; - height: 22px; -} - -.x-form-file-wrap .x-form-file-btn { - position: absolute; - right: 0; - z-index: 1; -} - -.x-form-file-wrap .x-form-file-text { - position: absolute; - left: 0; - z-index: 3; - color: #777; -} - -/* -* On ext fields set fieldClass to this to remove border/shading. -*/ -.x-bare-field { - padding: 1px 3px; - -x-system-font: none; - background: transparent; - border: 0px; - font-family: tahoma, arial, helvetica, sans-serif; - font-size: 12px; - font-size-adjust: none; - font-stretch: normal; - font-style: normal; - font-variant: normal; - font-weight: normal; - line-height: normal; - margin: 0; - font-family: tahoma, arial, helvetica, sans-serif; -} - -/** Use as 'baseCls' for panels to remove outline. */ -.x-plain-panel { - border: 0px; -} - -/** Used by Ext in table layouts, but not defined in ext-all.css */ -.x-table-layout-cell { - padding: 5px; - margin: 3px; - vertical-align: top; -} - -/** -* Override ext default -*/ -.x-progress-text { - font-size: 11px; - font-weight: normal; - color: #000; - padding: 1px 5px; - overflow: hidden; - position: absolute; - left: 0; - text-align: center; -} - -/** -* Replacement for StatusBar lost in Ext 3 -*/ -.x-statusbar .x-status-text { - height: 21px; - line-height: 21px; - padding: 0 4px; - cursor: default; -} -.x-statusbar .x-status-busy { - padding-left: 25px; - background: transparent url(../../images/default/grid/loading.gif) - no-repeat 3px 3px; -} - -.x-statusbar .x-status-text-panel { - border-top: 1px solid #99BBE8; - border-right: 1px solid #fff; - border-bottom: 1px solid #fff; - border-left: 1px solid #99BBE8; - padding: 2px 8px 2px 5px; } .news { @@ -624,61 +456,13 @@ a.tooltip:hover .tooltiptext { } .news p { - + } .upload-icon { background: url('../../images/icons/add.png') no-repeat 0 0 !important; } -.right-align-btn .x-btn-mc { - text-align: right; -} - -.unstyledTitle .x-panel-header { - background: none repeat-x scroll 0 -1px transparent; - color: black; - border: 0px solid; -} - -.unstyledTitle .x-tool-toggle { - background-position: 0 -255px; - float: left; - margin-right: 5px; -} - -.unstyledTitle .x-tool-toggle-over { - background-position: -15px -255px; -} - -.x-panel,.unstyledTitle,.x-panel-collapsed .x-tool-toggle { - background-position: 0 -240px; -} - -.x-panel,.unstyledTitle,.x-panel-collapsed .x-tool-toggle-over { - background-position: -15px -240px; -} - -.x-tool-delete { - background-image: url('../../images/icons/cross.png'); - margin-left: 10px; -} - -.x-tool-delete-over { - background-image: url('../../images/icons/cross.png'); - margin-left: 10px; -} - -.x-tool-saveEdit { - background-image: url('../../images/icons/diskEdit2.png'); - margin-left: 10px; -} - -.x-tool-saveEdit-over { - background-image: url('../../images/icons/diskEdit2.png'); - margin-left: 10px; -} - /* hover thumbnails */ /*Credits: Dynamic Drive CSS Library */ /*URL: http://www.dynamicdrive.com/style/ */ @@ -714,10 +498,6 @@ a.tooltip:hover .tooltiptext { left: 60px; /*position where enlarged image should offset horizontally */ } -/* end of hover thumbnails*/ -.x-form-trigger-paste-genes { - background-image: url("../../images/icons/page_upload.png") -} .absolute-position-loading-mask { top: 70px !important @@ -725,10 +505,9 @@ a.tooltip:hover .tooltiptext { .inline-help-form-q-tip { line-height: 1.1em; - font-size: 1.0em; } -.indent20,.indent20 p,.indent20 ul { +.indent20, .indent20 p, .indent20 ul { padding-left: 20px } diff --git a/gemma-web/src/main/webapp/styles/ext-overrides.css b/gemma-web/src/main/webapp/styles/ext-overrides.css new file mode 100644 index 0000000000..86b3974611 --- /dev/null +++ b/gemma-web/src/main/webapp/styles/ext-overrides.css @@ -0,0 +1,199 @@ +/* Override for Ext.js */ + +.x-form-field-wrap .x-go-trigger { + background-image: url('../../images/icons/search-trigger.gif'); + cursor: pointer; +} + +.x-menu-item-text { + color: rgba(0, 0, 0, 0.87); +} + +.x-loading { + background: url('../../images/default/tree/loading.gif') no-repeat center; +} + +/* used by CollapsedPanelTitlePlugin.js, style based on ext-all.css x-panel-header */ +.x-panel-collapsed-text { + /* see .front-page-header-text + color: #15428B; + font: bold 11px tahoma, arial, verdana, sans-serif;*/ + padding: 5px 3px 4px 5px; + float: right; + line-height: 13px; +} + +/* make sure link text is white when selected in Ext tables + */ +.x-grid-row-selected a { + color: white !important; +} + +/* + * FileUploadField component styles + */ +.x-form-file-wrap { + position: relative; + height: 22px; +} + +.x-form-file-wrap .x-form-file { + position: absolute; + right: 0; + -moz-opacity: 0; + filter: alpha(opacity:0); + opacity: 0; + z-index: 2; + height: 22px; +} + +.x-form-file-wrap .x-form-file-btn { + position: absolute; + right: 0; + z-index: 1; +} + +.x-form-file-wrap .x-form-file-text { + position: absolute; + left: 0; + z-index: 3; + color: #777; +} + +/* +* On ext fields set fieldClass to this to remove border/shading. +*/ +.x-bare-field { + padding: 1px 3px; + background: transparent; + border: 0; + font-size-adjust: none; + font-stretch: normal; + font-style: normal; + font-variant: normal; + font-weight: normal; + line-height: normal; + margin: 0; +} + +/** Use as 'baseCls' for panels to remove outline. */ +.x-plain-panel { + border: 0; +} + +/** Used by Ext in table layouts, but not defined in ext-all.css */ +.x-table-layout-cell { + padding: 5px; + margin: 3px; + vertical-align: top; +} + +/** +* Override ext default +*/ +.x-progress-text { + font-weight: normal; + color: #000; + padding: 1px 5px; + overflow: hidden; + position: absolute; + left: 0; + text-align: center; +} + +/** +* Replacement for StatusBar lost in Ext 3 +*/ +.x-statusbar .x-status-text { + height: 21px; + line-height: 21px; + padding: 0 4px; + cursor: default; +} + +.x-statusbar .x-status-busy { + padding-left: 25px; + background: transparent url(../../images/default/grid/loading.gif) no-repeat 3px 3px; +} + +.x-statusbar .x-status-text-panel { + border-top: 1px solid #99BBE8; + border-right: 1px solid #fff; + border-bottom: 1px solid #fff; + border-left: 1px solid #99BBE8; + padding: 2px 8px 2px 5px; +} + +.right-align-btn .x-btn-mc { + text-align: right; +} + +.unstyledTitle .x-panel-header { + background: none repeat-x scroll 0 -1px transparent; + color: black; + border: 0 solid; +} + +.unstyledTitle .x-tool-toggle { + background-position: 0 -255px; + float: left; + margin-right: 5px; +} + +.unstyledTitle .x-tool-toggle-over { + background-position: -15px -255px; +} + +.x-panel, .unstyledTitle, .x-panel-collapsed .x-tool-toggle { + background-position: 0 -240px; +} + +.x-panel, .unstyledTitle, .x-panel-collapsed .x-tool-toggle-over { + background-position: -15px -240px; +} + +.x-tool-delete { + background-image: url('../../images/icons/cross.png'); + margin-left: 10px; +} + +.x-tool-delete-over { + background-image: url('../../images/icons/cross.png'); + margin-left: 10px; +} + +.x-tool-saveEdit { + background-image: url('../../images/icons/diskEdit2.png'); + margin-left: 10px; +} + +.x-tool-saveEdit-over { + background-image: url('../../images/icons/diskEdit2.png'); + margin-left: 10px; +} + +/* end of hover thumbnails*/ +.x-form-trigger-paste-genes { + background-image: url("../../images/icons/page_upload.png") +} + +.x-form-item { + padding-left: 5px; + width: 100%; + text-align: left; + vertical-align: bottom; +} + +.x-form-item:nth-child(odd) { + /* border-bottom: solid 1px #eeeeee; */ + background: #f4f4f4; +} + +.x-form-item:nth-child(odd) *:not(textarea):not(.ee-status-badge):not(.fa):not(.security-link) { + background: #f4f4f4; +} + +.x-form-textarea { + font: normal 12px tahoma, arial, helvetica, sans-serif; +} + diff --git a/gemma-web/src/main/webapp/styles/geeq.css b/gemma-web/src/main/webapp/styles/geeq.css new file mode 100644 index 0000000000..eb43b879a8 --- /dev/null +++ b/gemma-web/src/main/webapp/styles/geeq.css @@ -0,0 +1,254 @@ +.gq-head { + font-size: 120%; +} + +.gq-head .gq-row { + line-height: 200%; + font-weight: bold; +} + +.gq-head .gq-extra .gq-btn { + top: -10px; +} + +.gq-body { + filter: saturate(70%); + margin: 0; + background: whitesmoke !important; + border-left: 1px solid lightgray; + border-bottom: 1px solid lightgray; + border-right: 1px solid lightgray; +} + +.gq-btn { + width: 100% !important; + padding: 5px; + background: whitesmoke; +} + +.gq-btn:hover { + filter: brightness(90%); +} + +.gq-btn * { + font-size: 106% !important; + cursor: pointer; + background: transparent !important; +} + +.extjs-sucks { + margin: 0; + text-align: center !important; +} + +.extjs-sucks * { + text-align: center !important; +} + +.gq-btn-details { + text-align: left !important; + margin: 0 !important; + width: 100% !important; + background: whitesmoke !important; + /*Looks better when the manual score override UI is enabled*/ + /*border-left: 1px solid lightgray;*/ + /*border-bottom: 1px solid lightgray;*/ + /*border-right: 1px solid lightgray;*/ +} + +.gq-btn-details:hover { + background: lightgray !important; + filter: none; +} + +.gq-btn-details * { + text-align: center !important; + display: inline-block !important; + background: whitesmoke !important; +} + +.gq-btn-details:hover * { + background: lightgray !important; + filter: none; +} + +.gq-btn-save { + border: solid 1px darkgray; + border-radius: 10px; + margin: 10px 5px 5px; + padding: 7px 5px 5px 5px; + width: 50% !important; + background: whitesmoke !important; +} + +.gq-btn-save:hover { + filter: brightness(110%); +} + +.gq-btn-save * { + font-size: 106% !important; + cursor: pointer; + background: whitesmoke !important; +} + +.gq-btn-recalc-all { + text-align: center !important; + font-size: 90% !important; + font-weight: 900 !important; + display: inline-block !important; + padding: 10px; + margin: 20px 0 !important; + width: 90% !important; + box-shadow: 0 0 3px #b9b9b9; +} + +.gq-btn-recalc-all * { + text-align: center !important; + display: inline-block !important; + cursor: pointer !important; +} + +.gq-btn-recalc-all.x-item-disabled { + color: darkgray !important; + background-color: lightgray !important; +} + +.gq-row { + padding: 2px; +} + +.gq-row.has-extra { + margin-bottom: 0; +} + +.gq-row .fa { + margin-left: 5px; +} + +.gq-label { + display: inline-block; + width: 180px; + font-weight: 500; + padding: 0 10px; + text-align: right; +} + +.gq-label:after { + content: ':'; +} + +.gq-value.negative { + margin-left: -5px; +} + +.gq-errors span.icon { + font-size: 300%; + width: 10%; +} + +.gq-errors span.msg { + float: right; + width: 90%; +} + +.gq-errors pre { + padding: 5px; + background: lightgray; + white-space: pre-wrap; +} + +.gq-extra { + box-shadow: inset 0 10px 10px -10px #585858; + text-align: center; + background: lightgray !important; + margin: 0; + padding: 0 5px 5px 5px; +} + +.gq-extra * { + background: transparent; + display: inline-block; +} + +.gq-extra label { + padding-right: 20px; +} + +.gq-extra .gq-btn { + padding: 0; + position: relative; + top: -8px; +} + +.gq-extra .gq-btn * { + color: #747474; +} + +.gq-subscore-refresh-btn { + margin-right: 10px; + padding: 5px; +} + +.gq-override-value-slider { + width: 200px; + margin: 0; + padding: 0; +} + +.gq-override-value-slider .x-slider-end, .x-slider-start { + background: none; +} + +.gq-override-value-slider .x-slider-inner { + height: 5px; + background: gray none; + border-radius: 10px; +} + +.gq-override-value-slider .x-slider-thumb { + background-image: none !important; + background: white; + width: 15px; + height: 15px; + border-radius: 10px; + top: -6px; +} + +.gq-override-value-wrap { + position: relative; + top: 10px; + overflow: visible; + margin-right: 10px; +} + +.gq-override-value { + border: none; + font-size: 105%; + padding: 2px; + text-align: center; +} + +.gq-override-value[disabled] { + filter: grayscale(100%); +} + +.gq-notif, .gq-notif * { + vertical-align: text-bottom !important; + display: inline-block !important; +} + +.gq-notif span { + padding: 5px 10px; + border-radius: 10px; + background-color: royalblue; + color: white; +} + +.gq-notif span:not([hidden]) { + opacity: 1; +} + +.gq-notif span[hidden] { + opacity: 0; + transition: opacity 1s linear; +} diff --git a/gemma-web/src/main/webapp/styles/menu.css b/gemma-web/src/main/webapp/styles/menu.css deleted file mode 100644 index 7d216b8420..0000000000 --- a/gemma-web/src/main/webapp/styles/menu.css +++ /dev/null @@ -1,5 +0,0 @@ -.x-menu-item-large .x-menu-item-text{ - line-height:20px; - font-size:12px; - color:black; -} diff --git a/gemma-web/src/test/java/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest.java b/gemma-web/src/test/java/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest.java new file mode 100644 index 0000000000..49b2d3be5c --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest.java @@ -0,0 +1,150 @@ +package ubic.gemma.web.controller.diff; + +import org.junit.After; +import org.junit.Test; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.ImportResource; +import org.springframework.http.MediaType; +import org.springframework.test.context.ContextConfiguration; +import ubic.gemma.core.analysis.expression.diff.AnalysisSelectionAndExecutionService; +import ubic.gemma.core.analysis.report.ExpressionExperimentReportService; +import ubic.gemma.core.job.executor.webapp.TaskRunningService; +import ubic.gemma.model.expression.experiment.ExperimentalDesign; +import ubic.gemma.model.expression.experiment.ExpressionExperiment; +import ubic.gemma.persistence.service.analysis.expression.diff.DifferentialExpressionAnalysisService; +import ubic.gemma.persistence.service.expression.experiment.ExpressionExperimentService; +import ubic.gemma.persistence.util.TestComponent; +import ubic.gemma.web.util.BaseWebTest; + +import static org.hamcrest.CoreMatchers.nullValue; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.eq; +import static org.mockito.Mockito.*; +import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content; +import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; +import static ubic.gemma.web.util.dwr.MockDwrRequestBuilders.*; +import static ubic.gemma.web.util.dwr.MockDwrResultMatchers.*; + +@ContextConfiguration +public class DifferentialExpressionAnalysisControllerTest extends BaseWebTest { + + @Configuration + @TestComponent + @ImportResource("classpath:ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest-dwr.xml") + static class DifferentialExpressionAnalysisControllerTestContextConfiguration extends BaseWebTestContextConfiguration { + + @Bean + public TaskRunningService taskRunningService() { + return mock(); + } + + @Bean + public AnalysisSelectionAndExecutionService analysisSelectionAndExecutionService() { + return mock(); + } + + @Bean + public ExpressionExperimentService expressionExperimentService() { + return mock(); + } + + @Bean + public DifferentialExpressionAnalysisService differentialExpressionAnalysisService() { + return mock(); + } + + @Bean + public ExpressionExperimentReportService experimentReportService() { + return mock(); + } + } + + @Autowired + private ExpressionExperimentService expressionExperimentService; + + @Autowired + private TaskRunningService taskRunningService; + + @After + public void resetMocks() { + reset( expressionExperimentService, taskRunningService ); + } + + @Test + public void testIndex() throws Exception { + mvc.perform( dwrStaticPage( "/index.html" ) ) + .andExpect( status().isOk() ) + .andExpect( content().contentType( MediaType.TEXT_HTML ) ); + } + + @Test + public void testDiffExAnalysisControllerTestPage() throws Exception { + mvc.perform( dwrStaticPage( "/test/DifferentialExpressionAnalysisController" ) ) + .andExpect( status().isOk() ) + .andExpect( content().contentType( MediaType.TEXT_HTML ) ); + } + + /** + * This error is produced via {@link javax.servlet.http.HttpServletResponse#sendError(int)} and thus is not + * intercepted by Spring's error handler. It will however be handled by the Web server via {@code error.jsp}. + */ + @Test + public void testUndefinedTestPage() throws Exception { + mvc.perform( dwrStaticPage( "/test/bleh" ) ) + .andExpect( status().isNotImplemented() ); + } + + @Test + public void testJsEngine() throws Exception { + mvc.perform( dwrStaticPage( "/engine.js" ) ) + .andExpect( status().isOk() ) + .andExpect( content().contentType( "text/javascript;charset=utf-8" ) ); + } + + @Test + public void test() throws Exception { + ExpressionExperiment ee = ExpressionExperiment.Factory.newInstance(); + ee.setExperimentalDesign( new ExperimentalDesign() ); + when( expressionExperimentService.loadAndThawLiteOrFail( eq( 1L ), any(), any() ) ).thenReturn( ee ); + when( taskRunningService.submitTaskCommand( any() ) ).thenReturn( "23" ); + mvc.perform( dwr( DifferentialExpressionAnalysisController.class, "run", 1L ) ) + .andExpect( callback().value( "23" ) ); + verify( taskRunningService ).submitTaskCommand( any() ); + } + + @Test + public void testBatchCall() throws Exception { + ExpressionExperiment ee = ExpressionExperiment.Factory.newInstance(); + ee.setExperimentalDesign( new ExperimentalDesign() ); + when( expressionExperimentService.loadAndThawLiteOrFail( eq( 1L ), any(), any() ) ).thenReturn( ee ); + mvc.perform( dwrBatch( 1 ).dwr( DifferentialExpressionAnalysisController.class, "run", 1L ) ) + .andExpect( batch( 0 ).callback().doesNotExist() ) + .andExpect( batch( 1 ).callback().value( nullValue() ) ); + verify( taskRunningService ).submitTaskCommand( any() ); + } + + @Test + public void testMultipleCalls() throws Exception { + ExpressionExperiment ee = ExpressionExperiment.Factory.newInstance(); + ee.setExperimentalDesign( new ExperimentalDesign() ); + when( expressionExperimentService.loadAndThawLiteOrFail( eq( 1L ), any(), any() ) ).thenReturn( ee ); + when( expressionExperimentService.loadAndThawLiteOrFail( eq( 2L ), any(), any() ) ).thenReturn( ee ); + mvc.perform( dwr( DifferentialExpressionAnalysisController.class, "run", 1L ) + .and( 2L ) ) + .andExpect( callback( 0 ).value( nullValue() ) ) + .andExpect( callback( 1 ).value( nullValue() ) ) + .andExpect( callback( 2 ).doesNotExist() ) + .andExpect( exception( 2 ).doesNotExist() ); + verify( taskRunningService, times( 2 ) ).submitTaskCommand( any() ); + } + + @Test + public void testMissingEndpoint() throws Exception { + mvc.perform( dwr( DifferentialExpressionAnalysisController.class, "run2", 1L ) ) + .andExpect( exception().javaClassName( "java.lang.Throwable" ) ) + .andExpect( exception().message( "Error" ) ); + verifyNoInteractions( taskRunningService ); + } +} \ No newline at end of file diff --git a/gemma-web/src/test/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentControllerTest.java b/gemma-web/src/test/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentControllerTest.java index 72e15e54ab..de998a8178 100644 --- a/gemma-web/src/test/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentControllerTest.java +++ b/gemma-web/src/test/java/ubic/gemma/web/controller/expression/experiment/ExpressionExperimentControllerTest.java @@ -22,6 +22,8 @@ import org.junit.After; import org.junit.Test; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.security.access.AccessDeniedException; +import ubic.gemma.core.job.SubmittedTask; import ubic.gemma.core.job.executor.webapp.TaskRunningService; import ubic.gemma.model.expression.experiment.ExpressionExperiment; import ubic.gemma.model.expression.experiment.ExpressionExperimentDetailsValueObject; @@ -34,6 +36,13 @@ import java.util.concurrent.ExecutionException; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; +import static ubic.gemma.web.util.dwr.MockDwrRequestBuilders.dwr; +import static ubic.gemma.web.util.dwr.MockDwrResultHandlers.getCallback; +import static ubic.gemma.web.util.dwr.MockDwrResultHandlers.getException; +import static ubic.gemma.web.util.dwr.MockDwrResultMatchers.callback; +import static ubic.gemma.web.util.dwr.MockDwrResultMatchers.exception; /** * @author ptan @@ -86,18 +95,56 @@ public void testLoadStatusSummariesLimit() { } @Test - public void testUpdatePubMed() throws ExecutionException, InterruptedException { + public void testUpdatePubMed() throws Exception { ExpressionExperiment ee = getTestPersistentExpressionExperiment(); ees.add( ee ); - String taskId = eeController.updatePubMed( ee.getId(), "1" ); - taskRunningService.getSubmittedTask( taskId ).getResult(); - ee = expressionExperimentService.thaw( ee ); - assertEquals( "Biochem Med", ee.getPrimaryPublication().getPublication() ); + mvc.perform( dwr( ExpressionExperimentController.class, "updatePubMed", ee.getId(), "1" ) ) + .andExpect( callback().exist() ) + .andDo( getCallback( ( String taskId ) -> { + SubmittedTask st = taskRunningService.getSubmittedTask( taskId ); + assertNotNull( st ); + try { + st.getResult(); + } catch ( ExecutionException | InterruptedException e ) { + throw new RuntimeException( e ); + } + ExpressionExperiment ee1 = expressionExperimentService.thaw( ee ); + assertEquals( "Biochem Med", ee1.getPrimaryPublication().getPublication() ); + } ) ); + + + mvc.perform( dwr( ExpressionExperimentController.class, "updatePubMed", ee.getId(), "2" ) ) + .andExpect( callback().exist() ) + .andDo( getCallback( ( String taskId ) -> { + SubmittedTask st = taskRunningService.getSubmittedTask( taskId ); + assertNotNull( st ); + try { + st.getResult(); + } catch ( ExecutionException | InterruptedException e ) { + throw new RuntimeException( e ); + } + ExpressionExperiment ee1 = expressionExperimentService.thaw( ee ); + assertEquals( "Biochem Biophys Res Commun", ee1.getPrimaryPublication().getPublication() ); + } ) ); + } - taskId = eeController.updatePubMed( ee.getId(), "2" ); - taskRunningService.getSubmittedTask( taskId ).getResult(); - ee = expressionExperimentService.thaw( ee ); - assertEquals( "Biochem Biophys Res Commun", ee.getPrimaryPublication().getPublication() ); + @Test + public void testUpdatePubMedAsAnonymousUser() throws Exception { + ExpressionExperiment ee = getTestPersistentExpressionExperiment(); + ees.add( ee ); + runAsAnonymous(); + try { + mvc.perform( dwr( ExpressionExperimentController.class, "updatePubMed", ee.getId(), "1" ) ) + .andExpect( status().isOk() ) + .andExpect( exception().exist() ) + .andExpect( callback().doesNotExist() ) + .andDo( getException( e -> { + assertEquals( AccessDeniedException.class.getName(), e.getJavaClassName() ); + assertEquals( "Access is denied", e.getMessage() ); + } ) ); + } finally { + runAsAdmin(); + } } } diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/BaseWebTest.java b/gemma-web/src/test/java/ubic/gemma/web/util/BaseWebTest.java index b8bd67ed28..f11861b95f 100644 --- a/gemma-web/src/test/java/ubic/gemma/web/util/BaseWebTest.java +++ b/gemma-web/src/test/java/ubic/gemma/web/util/BaseWebTest.java @@ -15,7 +15,7 @@ import org.springframework.web.servlet.handler.SimpleMappingExceptionResolver; import org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver; import ubic.gemma.persistence.util.MailEngine; -import ubic.gemma.persistence.util.SpringProfiles; +import ubic.gemma.persistence.util.EnvironmentProfiles; import java.util.Arrays; import java.util.Properties; @@ -28,7 +28,7 @@ * For a full integration test base class, use {@link ubic.gemma.web.util.BaseSpringWebTest}. * @author poirigui */ -@ActiveProfiles({ "web", SpringProfiles.TEST }) +@ActiveProfiles({ "web", EnvironmentProfiles.TEST }) @WebAppConfiguration public abstract class BaseWebTest extends AbstractJUnit4SpringContextTests implements InitializingBean { diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyMatchers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyMatchers.java new file mode 100644 index 0000000000..c9b94dcc2a --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyMatchers.java @@ -0,0 +1,24 @@ +package ubic.gemma.web.util.dwr; + +import org.springframework.test.web.servlet.ResultMatcher; + +import static org.springframework.test.util.AssertionErrors.assertTrue; + +public abstract class AbstractDwrReplyMatchers extends AbstractDwrReplyParser { + + protected AbstractDwrReplyMatchers( String callback, int batchId, int callId ) { + super( callback, batchId, callId ); + } + + public ResultMatcher exist() { + return result -> { + assertTrue( "Expected a line matching " + replyPattern, replyPattern.matcher( result.getResponse().getContentAsString() ).find() ); + }; + } + + public ResultMatcher doesNotExist() { + return result -> { + assertTrue( "Expected no line matching " + replyPattern, !replyPattern.matcher( result.getResponse().getContentAsString() ).find() ); + }; + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyParser.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyParser.java new file mode 100644 index 0000000000..67db1b44ac --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/AbstractDwrReplyParser.java @@ -0,0 +1,24 @@ +package ubic.gemma.web.util.dwr; + +import org.springframework.test.web.servlet.MvcResult; + +import java.io.UnsupportedEncodingException; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import static org.springframework.test.util.AssertionErrors.assertTrue; + +public class AbstractDwrReplyParser { + + protected final Pattern replyPattern; + + protected AbstractDwrReplyParser( String callback, int batchId, int callId ) { + replyPattern = Pattern.compile( "^" + Pattern.quote( callback ) + "\\('" + batchId + "','" + callId + "',(.*?)\\);$", Pattern.MULTILINE ); + } + + protected String getReply( MvcResult result ) throws UnsupportedEncodingException { + Matcher m = replyPattern.matcher( result.getResponse().getContentAsString() ); + assertTrue( "Expected a line matching " + replyPattern, m.find() ); + return m.group( 1 ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchHandlers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchHandlers.java new file mode 100644 index 0000000000..396b7eac5e --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchHandlers.java @@ -0,0 +1,32 @@ +package ubic.gemma.web.util.dwr; + +import java.util.function.Consumer; + +/** + * Handles DWR batches. + * @author poirigui + */ +public class DwrBatchHandlers { + + private final int batchId; + + public DwrBatchHandlers( int batchId ) { + this.batchId = batchId; + } + + public DwrCallbackHandler getCallback( int callId, Consumer doWithReply ) { + return new DwrCallbackHandler<>( batchId, callId, doWithReply ); + } + + public DwrCallbackHandler getCallback( Consumer doWithReply ) { + return getCallback( batchId, doWithReply ); + } + + public DwrExceptionHandler getException( int callId, Consumer doWithException ) { + return new DwrExceptionHandler( batchId, callId, doWithException ); + } + + public DwrExceptionHandler getException( Consumer doWithException ) { + return getException( batchId, doWithException ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchMatchers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchMatchers.java new file mode 100644 index 0000000000..6202d54630 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrBatchMatchers.java @@ -0,0 +1,36 @@ +package ubic.gemma.web.util.dwr; + +/** + * Match DWR batch results. + * @author poirigui + */ +public class DwrBatchMatchers { + + private final int batchId; + + public DwrBatchMatchers( int batchId ) { + this.batchId = batchId; + } + + /** + * Match a DWR callback. + */ + public DwrCallbackMatchers callback( int callId ) { + return new DwrCallbackMatchers( batchId, callId ); + } + + public DwrCallbackMatchers callback() { + return callback( 0 ); + } + + /** + * Match a DWR exception. + */ + public DwrExceptionMatchers exception( int callId ) { + return new DwrExceptionMatchers( batchId, callId ); + } + + public DwrExceptionMatchers exception() { + return exception( 0 ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackHandler.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackHandler.java new file mode 100644 index 0000000000..c671c27d3f --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackHandler.java @@ -0,0 +1,25 @@ +package ubic.gemma.web.util.dwr; + +import com.jayway.jsonpath.JsonPath; +import org.springframework.test.web.servlet.MvcResult; +import org.springframework.test.web.servlet.ResultHandler; + +import java.util.function.Consumer; + +public class DwrCallbackHandler extends AbstractDwrReplyParser implements ResultHandler { + + private static final JsonPath jsonPath = JsonPath.compile( "$.data" ); + + private final Consumer doWithReply; + + protected DwrCallbackHandler( int batchId, int callId, Consumer doWithReply ) { + super( "dwr.engine._remoteHandleCallback", batchId, callId ); + this.doWithReply = doWithReply; + } + + @Override + public void handle( MvcResult result ) throws Exception { + String payload = "{\"data\":" + getReply( result ) + "}"; + doWithReply.accept( jsonPath.read( payload ) ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackMatchers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackMatchers.java new file mode 100644 index 0000000000..17ae33e9b6 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrCallbackMatchers.java @@ -0,0 +1,57 @@ +package ubic.gemma.web.util.dwr; + +import org.hamcrest.Matcher; +import org.springframework.test.util.JsonPathExpectationsHelper; +import org.springframework.test.web.servlet.ResultMatcher; + +import java.text.ParseException; + +/** + * Matches successful DWR replies. + * @author poirigui + */ +public class DwrCallbackMatchers extends AbstractDwrReplyMatchers { + + /** + * DWR replies with JavaScript objects which might not be in a suitable JSON container (i.e. {@code []}, {@code {}}. + *

+ * Thus, this class modifies the behaviour by wrapping the object in a {@code {"data":reply}} container and + * adjusting the assertion message if necessary. + */ + private static final JsonPathExpectationsHelper jsonPathHelper = new JsonPathExpectationsHelper( "$.data" ) { + + @Override + public void assertValue( String responseContent, Object expectedValue ) throws ParseException { + try { + super.assertValue( "{\"data\":" + responseContent + "}", expectedValue ); + } catch ( AssertionError e ) { + throw new AssertionError( e.getMessage().replaceFirst( "\\$\\.data", "\\$" ), e.getCause() ); + } + } + + @Override + public void assertValue( String content, Matcher matcher ) throws ParseException { + try { + super.assertValue( "{\"data\":" + content + "}", matcher ); + } catch ( AssertionError e ) { + throw new AssertionError( e.getMessage().replaceFirst( "\\$\\.data", "\\$" ), e.getCause() ); + } + } + }; + + public DwrCallbackMatchers( int batchId, int callId ) { + super( "dwr.engine._remoteHandleCallback", batchId, callId ); + } + + public ResultMatcher value( Object expected ) { + return result -> { + jsonPathHelper.assertValue( getReply( result ), expected ); + }; + } + + public ResultMatcher value( org.hamcrest.Matcher matcher ) { + return result -> { + jsonPathHelper.assertValue( getReply( result ), matcher ); + }; + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrException.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrException.java new file mode 100644 index 0000000000..652d223a48 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrException.java @@ -0,0 +1,9 @@ +package ubic.gemma.web.util.dwr; + +import lombok.Value; + +@Value +public class DwrException { + String javaClassName; + String message; +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionHandler.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionHandler.java new file mode 100644 index 0000000000..91629a12f8 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionHandler.java @@ -0,0 +1,31 @@ +package ubic.gemma.web.util.dwr; + +import com.jayway.jsonpath.JsonPath; +import org.springframework.test.web.servlet.MvcResult; +import org.springframework.test.web.servlet.ResultHandler; + +import java.util.function.Consumer; + +public class DwrExceptionHandler extends AbstractDwrReplyParser implements ResultHandler { + + private static final JsonPath + javaClassNamePath = JsonPath.compile( "$.javaClassName" ), + messagePath = JsonPath.compile( "$.message" ); + + private final Consumer doWithException; + + public DwrExceptionHandler( int batchId, int callId, Consumer doWithException ) { + super( "dwr.engine._remoteHandleException", batchId, callId ); + this.doWithException = doWithException; + } + + @Override + public void handle( MvcResult result ) throws Exception { + doWithException.accept( parseException( result ) ); + } + + private DwrException parseException( MvcResult result ) throws Exception { + String reply = getReply( result ); + return new DwrException( javaClassNamePath.read( reply ), messagePath.read( reply ) ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionMatchers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionMatchers.java new file mode 100644 index 0000000000..58f9426018 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrExceptionMatchers.java @@ -0,0 +1,28 @@ +package ubic.gemma.web.util.dwr; + +import org.springframework.test.util.JsonPathExpectationsHelper; +import org.springframework.test.web.servlet.ResultMatcher; + +/** + * Matches erroneous DWR replies. + * @author poirigui + */ +public class DwrExceptionMatchers extends AbstractDwrReplyMatchers { + + public DwrExceptionMatchers( int batchId, int callId ) { + super( "dwr.engine._remoteHandleException", batchId, callId ); + } + + public ResultMatcher javaClassName( String value ) { + return result -> { + new JsonPathExpectationsHelper( "$.javaClassName" ).assertValue( getReply( result ), value ); + }; + } + + public ResultMatcher message( String value ) { + return result -> { + new JsonPathExpectationsHelper( "$.message" ).assertValue( getReply( result ), value ); + }; + } + +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrRequestBuilder.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrRequestBuilder.java new file mode 100644 index 0000000000..04ba727db0 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/DwrRequestBuilder.java @@ -0,0 +1,82 @@ +package ubic.gemma.web.util.dwr; + +import org.springframework.mock.web.MockHttpServletRequest; +import org.springframework.test.web.servlet.RequestBuilder; +import org.springframework.test.web.servlet.request.MockMvcRequestBuilders; + +import javax.servlet.ServletContext; +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; +import java.nio.charset.StandardCharsets; + +/** + * Request builder that allows multiple DWR calls to be performed. + * @author poirigui + */ +public class DwrRequestBuilder implements RequestBuilder { + + private final String servletPath; + private final Class clazz; + private final String methodName; + private final int batchId; + + // internal state + private final StringBuilder callPayload; + private int callCount = 0; + + public DwrRequestBuilder( String servletPath, Class clazz, String methodName, int batchId ) { + this.servletPath = servletPath; + this.clazz = clazz; + this.methodName = methodName; + this.batchId = batchId; + this.callPayload = new StringBuilder(); + } + + /** + * Chain one additional DWR call. + */ + public DwrRequestBuilder and( Object... args ) { + int callId = callCount; + callPayload + .append( "c" ).append( callId ).append( "-scriptName=" ).append( clazz.getSimpleName() ).append( '\n' ) + .append( "c" ).append( callId ).append( "-methodName=" ).append( methodName ).append( '\n' ) + .append( "c" ).append( callId ).append( "-id=" ).append( callId ).append( '\n' ); + int i = 0; + for ( Object arg : args ) { + String type; + if ( arg instanceof String ) { + type = "string"; + } else if ( arg instanceof Number ) { + type = "number"; + } else if ( arg instanceof Boolean ) { + type = "boolean"; + } else { + throw new IllegalArgumentException( "Unsupported type: " + arg.getClass() ); + } + try { + callPayload.append( "c" ).append( callId ).append( "-param" ).append( i++ ).append( "=" ).append( type ).append( ":" ) + .append( URLEncoder.encode( String.valueOf( arg ), StandardCharsets.UTF_8.name() ) ) + .append( '\n' ); + } catch ( UnsupportedEncodingException e ) { + throw new RuntimeException( e ); + } + } + callCount++; + return this; + } + + @Override + public MockHttpServletRequest buildRequest( ServletContext servletContext ) { + String payload = "callCount=" + callCount + "\n" + + "page=\n" + + "httpSessionId=\n" + + "scriptSessionId=\n" + + callPayload + + "batchId=" + batchId + "\n"; + return MockMvcRequestBuilders + .post( servletPath + "/call/plaincall/{className}.{methodName}.dwr", clazz.getSimpleName(), methodName ) + .servletPath( servletPath ) + .content( payload ) + .buildRequest( servletContext ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrBatchRequestBuilders.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrBatchRequestBuilders.java new file mode 100644 index 0000000000..ebace7a817 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrBatchRequestBuilders.java @@ -0,0 +1,19 @@ +package ubic.gemma.web.util.dwr; + +public class MockDwrBatchRequestBuilders { + + private final String servletPath; + private final int batchId; + + public MockDwrBatchRequestBuilders( String servletPath, int batchId ) { + this.servletPath = servletPath; + this.batchId = batchId; + } + + /** + * Perform a DWR call. + */ + public DwrRequestBuilder dwr( Class clazz, String methodName, Object... args ) { + return new DwrRequestBuilder( servletPath, clazz, methodName, batchId ).and( args ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrRequestBuilders.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrRequestBuilders.java new file mode 100644 index 0000000000..eca628219e --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrRequestBuilders.java @@ -0,0 +1,38 @@ +package ubic.gemma.web.util.dwr; + +import org.directwebremoting.impl.DefaultContainer; +import org.springframework.test.web.servlet.RequestBuilder; +import org.springframework.test.web.servlet.request.MockMvcRequestBuilders; + +import javax.servlet.ServletConfig; + +public class MockDwrRequestBuilders { + + /** + * TODO: infer this from the servlet configuration + */ + private static final String SERVLET_PATH = "/dwr"; + + /** + * Request the DWR static page. + * @see org.directwebremoting.impl.ContainerUtil#setupDefaults(DefaultContainer, ServletConfig) + */ + public static RequestBuilder dwrStaticPage( String page ) { + return MockMvcRequestBuilders.get( SERVLET_PATH + page ) + .servletPath( SERVLET_PATH ); + } + + /** + * Perform a DWR call. + */ + public static DwrRequestBuilder dwr( Class clazz, String methodName, Object... args ) { + return new DwrRequestBuilder( SERVLET_PATH, clazz, methodName, 0 ).and( args ); + } + + /** + * Perform a batched DWR call. + */ + public static MockDwrBatchRequestBuilders dwrBatch( int batchId ) { + return new MockDwrBatchRequestBuilders( SERVLET_PATH, batchId ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultHandlers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultHandlers.java new file mode 100644 index 0000000000..aeb11c88d9 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultHandlers.java @@ -0,0 +1,30 @@ +package ubic.gemma.web.util.dwr; + +import java.util.function.Consumer; + +/** + * Handles DWR results. + * @author poirigui + */ +public class MockDwrResultHandlers { + + public static DwrBatchHandlers getBatch( int batchId ) { + return new DwrBatchHandlers( batchId ); + } + + public static DwrCallbackHandler getCallback( int callId, Consumer doWithReply ) { + return new DwrCallbackHandler<>( 0, callId, doWithReply ); + } + + public static DwrCallbackHandler getCallback( Consumer doWithReply ) { + return getCallback( 0, doWithReply ); + } + + public static DwrExceptionHandler getException( int callId, Consumer doWithException ) { + return new DwrExceptionHandler( 0, callId, doWithException ); + } + + public static DwrExceptionHandler getException( Consumer doWithException ) { + return getException( 0, doWithException ); + } +} \ No newline at end of file diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultMatchers.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultMatchers.java new file mode 100644 index 0000000000..5b78ef6a02 --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/MockDwrResultMatchers.java @@ -0,0 +1,37 @@ +package ubic.gemma.web.util.dwr; + +/** + * Match DWR results. + * @author poirigui + */ +public class MockDwrResultMatchers { + + /** + * Match a batch of DWR results. + */ + public static DwrBatchMatchers batch( int batchId ) { + return new DwrBatchMatchers( batchId ); + } + + /** + * Match a DWR callback. + */ + public static DwrCallbackMatchers callback( int callId ) { + return new DwrCallbackMatchers( 0, callId ); + } + + public static DwrCallbackMatchers callback() { + return callback( 0 ); + } + + /** + * Match a DWR exception. + */ + public static DwrExceptionMatchers exception( int callId ) { + return new DwrExceptionMatchers( 0, callId ); + } + + public static DwrExceptionMatchers exception() { + return exception( 0 ); + } +} diff --git a/gemma-web/src/test/java/ubic/gemma/web/util/dwr/package-info.java b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/package-info.java new file mode 100644 index 0000000000..8b99046e5e --- /dev/null +++ b/gemma-web/src/test/java/ubic/gemma/web/util/dwr/package-info.java @@ -0,0 +1,8 @@ +/** + * Utilities for testing DWR endpoints. + * @author poirigui + */ +@ParametersAreNonnullByDefault +package ubic.gemma.web.util.dwr; + +import javax.annotation.ParametersAreNonnullByDefault; \ No newline at end of file diff --git a/gemma-web/src/test/resources/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest-dwr.xml b/gemma-web/src/test/resources/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest-dwr.xml new file mode 100644 index 0000000000..605435d23b --- /dev/null +++ b/gemma-web/src/test/resources/ubic/gemma/web/controller/diff/DifferentialExpressionAnalysisControllerTest-dwr.xml @@ -0,0 +1,30 @@ + + + + + + + + + + + + + + dwrController + + + + + + + + + + + \ No newline at end of file diff --git a/pom.xml b/pom.xml index 3f781e607d..a3614752e3 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ Gemma gemma gemma - 1.31.1 + 1.31.2 2005 The Gemma Project for meta-analysis of genomics data https://gemma.msl.ubc.ca @@ -140,6 +140,7 @@ baseCode baseCode + 1.1.20 @@ -485,6 +486,8 @@ true 1 + true + true @@ -626,7 +629,7 @@ - 0.0.16-SNAPSHOT + 0.0.16 3.2.18.RELEASE 3.2.10.RELEASE 2.25.1 diff --git a/src/annotations/org/hibernate/annotations.xml b/src/annotations/org/hibernate/annotations.xml new file mode 100644 index 0000000000..a13e5f31d9 --- /dev/null +++ b/src/annotations/org/hibernate/annotations.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/src/site/resources/images/gemma-headerlogo.png b/src/site/resources/images/gemma-headerlogo.png new file mode 100644 index 0000000000..18d4ac5447 Binary files /dev/null and b/src/site/resources/images/gemma-headerlogo.png differ diff --git a/src/site/resources/images/ubc-logo-2018-crest-blue-rgb72.jpg b/src/site/resources/images/ubc-logo-2018-crest-blue-rgb72.jpg new file mode 100644 index 0000000000..bb61e5fb9d Binary files /dev/null and b/src/site/resources/images/ubc-logo-2018-crest-blue-rgb72.jpg differ diff --git a/src/site/site.xml b/src/site/site.xml index 98b549d518..0d58688433 100644 --- a/src/site/site.xml +++ b/src/site/site.xml @@ -2,12 +2,12 @@ xsi:schemaLocation="http://maven.apache.org/SITE/2.0.0 http://maven.apache.org/xsd/site-2.0.0.xsd"> Gemma - https://gemma.msl.ubc.ca/images/logo/gemma-headerlogo.png + /images/gemma-headerlogo.png https://gemma.msl.ubc.ca UBC - https://gemma.msl.ubc.ca/images/logo/ubcgrey_logo_40.png + /images/ubc-logo-2018-crest-blue-rgb72.jpg https://www.ubc.ca/

Sample correlationPCA Scree
Data sets:' - + '{expressionExperimentCount}' + + '{expressionExperimentCount}' + '' - + '{updatedExpressionExperimentCount}' + + '{updatedExpressionExperimentCount}' + '' - + '{newExpressionExperimentCount}' + + '{newExpressionExperimentCount}' + '
 {taxonCommonName}' - + '{totalCount}' + + '{totalCount}' + '' - + '{updatedCount}' + + '{updatedCount}' + '' - + '{newCount}' + + '{newCount}' + '