From d7bbade26d1647f59794e4a0ac349ad8e9c8c37a Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Thu, 15 Mar 2018 20:43:14 -0700 Subject: [PATCH 01/61] update for next development version --- gotrack/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gotrack/pom.xml b/gotrack/pom.xml index 6c6cc07..b7c2384 100644 --- a/gotrack/pom.xml +++ b/gotrack/pom.xml @@ -4,7 +4,7 @@ ubc.pavlab gotrack war - 1.2 + 1.3-SNAPSHOT gotrack http://maven.apache.org From e5645ee414c9ed4852011da935dc8022d7f7bb94 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 13:54:31 -0700 Subject: [PATCH 02/61] Fix enrichment table not updating on new run --- gotrack/src/main/webapp/resources/js/enrichment.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gotrack/src/main/webapp/resources/js/enrichment.js b/gotrack/src/main/webapp/resources/js/enrichment.js index 08b7a34..f7048cc 100644 --- a/gotrack/src/main/webapp/resources/js/enrichment.js +++ b/gotrack/src/main/webapp/resources/js/enrichment.js @@ -58,6 +58,12 @@ function runEnrichmentComplete(xhr, status, args) { } + try { + PF('tableEnrichmentWdg').filter(); + } catch (e) { + + } + try { reInitializeCharts(); From edc34b18277c765fedf0326e16a38a3cba6b32ea Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 16:20:10 -0700 Subject: [PATCH 03/61] Fix incorrect species count and years select Home page was displaying a count for all species instead of just those loaded. Similarly, the annotation download form allowed selecting years for species who had no editions in said year. --- .../java/ubc/pavlab/gotrack/beans/Cache.java | 62 ++++++++++++------- .../component/AnnotationDownloadView.java | 5 ++ gotrack/src/main/webapp/index.xhtml | 7 ++- .../composites/annotationDownload.xhtml | 2 +- 4 files changed, 51 insertions(+), 25 deletions(-) diff --git a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/Cache.java b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/Cache.java index ec76c59..1317f7e 100644 --- a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/Cache.java +++ b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/Cache.java @@ -112,7 +112,8 @@ public class Cache implements Serializable { private Map accessionToGene = new ConcurrentHashMap<>(); // Useful derived constants - private ImmutableList availableYears; + private Map> speciesYears = new ConcurrentHashMap<>(); + private int availableYears; // These are used for autocompletion // ********************************* @@ -218,10 +219,14 @@ public AnnotationType[] getAnnotationTypes() { return AnnotationType.values(); } - public ImmutableList getAvailableYears() { + public int getAvailableYears() { return availableYears; } + public ImmutableList getSpeciesYears( Species species ) { + return speciesYears.get( species ); + } + private void createSpecies() { Set sr = Sets.newHashSet(); @@ -293,7 +298,8 @@ private void createEditions( CacheDAO cacheDAO ) { } // Populate derived constants - Set availableYearsBuilder = Sets.newHashSet(); + Map> availableYearsBuilder = Maps.newHashMap(); + Calendar cal = Calendar.getInstance(); // Create Edition objects for ( EditionDTO dto : cacheDAO.getAllEditions( speciesRestrictions ) ) { @@ -313,12 +319,16 @@ private void createEditions( CacheDAO cacheDAO ) { continue; } - // Populate derived constants - Calendar cal = Calendar.getInstance(); + Species species = speciesCache.get( dto.getSpecies() ); + + Set years = availableYearsBuilder.get( species ); + if ( years == null ) { + years = Sets.newHashSet(); + availableYearsBuilder.put( species, years ); + } cal.setTime( dto.getDate() ); - availableYearsBuilder.add( cal.get( Calendar.YEAR ) ); + years.add( cal.get( Calendar.YEAR ) ); - Species species = speciesCache.get( dto.getSpecies() ); Map m = allEditions.get( species ); if ( m == null ) { @@ -349,12 +359,14 @@ private void createEditions( CacheDAO cacheDAO ) { } } - List sortedYears = Lists.newArrayList(availableYearsBuilder); - Collections.sort(sortedYears); - - availableYears = ImmutableList.copyOf( sortedYears ); - - // ImmutableSet.Builder availableYearsBuilder = ImmutableSet.builder(); + Set allYears = Sets.newHashSet(); + for ( Entry> speciesSetEntry : availableYearsBuilder.entrySet() ) { + List sortedYears = Lists.newArrayList( speciesSetEntry.getValue() ); + Collections.sort( sortedYears ); + speciesYears.put( speciesSetEntry.getKey(), ImmutableList.copyOf( sortedYears ) ); + allYears.addAll( speciesSetEntry.getValue() ); + } + availableYears = allYears.size(); currentGOEdition = Collections.max( allGOEditions.values() ); @@ -927,6 +939,10 @@ public Edition getCurrentEditions( Species species ) { return currentEditions.get( species ); } + public Collection getCurrentEditions() { + return currentEditions.values(); + } + /** * @param species * @return UNORDERED collection of all editions for this species @@ -990,29 +1006,29 @@ public GOEdition getGlobalMaxGOEdition() { } /** - * @param ed edition - * @param t term + * @param ed edition + * @param t term * @return count of genes annotated with this term or any of its children */ public Integer getInferredAnnotationCount( Edition ed, GeneOntologyTerm t ) { if ( ed == null || t == null ) return null; Map tmp = inferredAnnotationCount.get( ed ); - if (tmp != null) { - return tmp.get(t); + if ( tmp != null ) { + return tmp.get( t ); } return null; } /** - * @param ed edition - * @param t term + * @param ed edition + * @param t term * @return count of genes annotated with this term */ public Integer getDirectAnnotationCount( Edition ed, GeneOntologyTerm t ) { if ( ed == null || t == null ) return null; Map tmp = directAnnotationCount.get( ed ); - if (tmp != null) { - return tmp.get(t); + if ( tmp != null ) { + return tmp.get( t ); } return null; } @@ -1279,6 +1295,10 @@ public GOEdition getGOEdition( Integer edId ) { return allGOEditions.get( edId ); } + public Collection getAllGOEditions() { + return allGOEditions.values(); + } + // Application Level Caching get/set /** diff --git a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/component/AnnotationDownloadView.java b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/component/AnnotationDownloadView.java index 732bf6b..5783978 100644 --- a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/component/AnnotationDownloadView.java +++ b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/component/AnnotationDownloadView.java @@ -21,6 +21,7 @@ import com.google.common.base.Joiner; import com.google.common.base.Predicate; +import com.google.common.collect.ImmutableList; import com.google.common.collect.Iterables; import com.google.common.collect.Lists; import org.apache.log4j.Logger; @@ -85,6 +86,10 @@ public void init() { filterEditions(); } + public ImmutableList getAllYears() { + return cache.getSpeciesYears( session.getSpecies() ); + } + public Integer getYear() { return year; } diff --git a/gotrack/src/main/webapp/index.xhtml b/gotrack/src/main/webapp/index.xhtml index c299b49..90e8f31 100644 --- a/gotrack/src/main/webapp/index.xhtml +++ b/gotrack/src/main/webapp/index.xhtml @@ -229,8 +229,9 @@ -

Compare and/or download monthly annotations from #{statsService.latestSpeciesCnt} species over the last #{statsService.latestYearsAvailable} years.

+

Compare and/or download monthly annotations from #{cache.speciesList.size()} species over the last #{cache.availableYears} years.

+

Database

@@ -251,8 +252,8 @@
-
- +
+

Download Annotations

diff --git a/gotrack/src/main/webapp/resources/composites/annotationDownload.xhtml b/gotrack/src/main/webapp/resources/composites/annotationDownload.xhtml index 1a28662..dbbf6db 100644 --- a/gotrack/src/main/webapp/resources/composites/annotationDownload.xhtml +++ b/gotrack/src/main/webapp/resources/composites/annotationDownload.xhtml @@ -36,7 +36,7 @@ - + From 698498552873791773e244293a28645db5e78ec2 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 16:26:24 -0700 Subject: [PATCH 04/61] Fix trends GO Size chart has species subtitle --- gotrack/src/main/webapp/resources/js/trends.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gotrack/src/main/webapp/resources/js/trends.js b/gotrack/src/main/webapp/resources/js/trends.js index 86675bc..58a7463 100644 --- a/gotrack/src/main/webapp/resources/js/trends.js +++ b/gotrack/src/main/webapp/resources/js/trends.js @@ -27,9 +27,11 @@ function handleFetchCharts(xhr, status, args) { var options = plotting.defaultHCOptions('hc-' + ckey, chart); - options.subtitle = { - text: args.species.scientificName - }; + if (ckey !== 'ontSize' ) { + options.subtitle = { + text: args.species.scientificName + }; + } if (syncGroups[ckey]) { plotting.addSynchronization(options); From b17b6ea768cc15f94c7cb394cc4199cc5f2f27d9 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 16:29:14 -0700 Subject: [PATCH 05/61] Fix: Trends species select not recreating charts --- gotrack/src/main/webapp/trends.xhtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gotrack/src/main/webapp/trends.xhtml b/gotrack/src/main/webapp/trends.xhtml index b706fb7..a3bfb80 100644 --- a/gotrack/src/main/webapp/trends.xhtml +++ b/gotrack/src/main/webapp/trends.xhtml @@ -97,7 +97,7 @@ converter="speciesConverter"> - + From 5c93fdd3609f3b013ab501c7d73cd0971f52b34c Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 16:40:41 -0700 Subject: [PATCH 06/61] Add note that we do not propagate across aspects Also add QuickGO link out. --- gotrack/src/main/webapp/terms.xhtml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/gotrack/src/main/webapp/terms.xhtml b/gotrack/src/main/webapp/terms.xhtml index 20f2f6d..38ffa1d 100644 --- a/gotrack/src/main/webapp/terms.xhtml +++ b/gotrack/src/main/webapp/terms.xhtml @@ -95,8 +95,11 @@ - + + + + @@ -104,8 +107,7 @@ - + @@ -113,8 +115,7 @@ - + @@ -122,8 +123,7 @@ - + @@ -254,7 +254,9 @@ style="width:600px;text-align:left;">

The Term Information tab shows the most current information for the selected GO term.

- Ancestry Chart: The most current ancestry chart for the selected GO term. The figure is interactive: + Ancestry Chart: The most current ancestry chart for the selected GO term.

+

Note: Unlike QuickGO, we do not propagate across aspects.

+

The figure is interactive: select a term to open its individual page, hover a term to view more information and highlight its direct relations, zoom, and pan.

From 7be123f85abf0641ce8ef233657dcc7eb70f7e27 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 16:45:40 -0700 Subject: [PATCH 07/61] Add species text to annotation download form Was not obvious that the annotations you are downloading are specific to the currently selected species. --- gotrack/src/main/webapp/index.xhtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gotrack/src/main/webapp/index.xhtml b/gotrack/src/main/webapp/index.xhtml index 90e8f31..de3536b 100644 --- a/gotrack/src/main/webapp/index.xhtml +++ b/gotrack/src/main/webapp/index.xhtml @@ -253,7 +253,7 @@
-

Download Annotations

+

Download #{sessionManager.species.commonName} Annotations

From 4e5f41453dbc26119b1291049cb5e505f92e3ecb Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 17:09:25 -0700 Subject: [PATCH 08/61] Enrichment table: auto width, resizable columns --- .../webapp/resources/composites/enrichmentResultsTable.xhtml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml index 31d11dc..faab70a 100644 --- a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml +++ b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml @@ -32,7 +32,8 @@ selection="#{cc.attrs.selection}" rowKey="#{entry.term.goId}" liveScroll="true" - scrollRows="25"> + scrollRows="25" + resizableColumns="true"> @@ -106,7 +107,7 @@ + headerText="Name"> From 27d40ba6ef1ea5585849d21c4efb3776b21701cd Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 17:14:52 -0700 Subject: [PATCH 09/61] Improve enrichment threshold help message --- gotrack/src/main/webapp/enrichment.xhtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gotrack/src/main/webapp/enrichment.xhtml b/gotrack/src/main/webapp/enrichment.xhtml index 2cfdf34..426637a 100644 --- a/gotrack/src/main/webapp/enrichment.xhtml +++ b/gotrack/src/main/webapp/enrichment.xhtml @@ -725,7 +725,7 @@ -

Threshold to use for the above multiple test correction method.

+

Threshold to use for the above multiple test correction method. This establishes the definition of "significant" for the results displays.

From 4dc2f5b70437c9e5d3ea8263a010195b4cc5a369 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Mon, 19 Mar 2018 17:25:52 -0700 Subject: [PATCH 10/61] Term Chart start with only sig. series visible --- .../main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java | 7 +++++-- gotrack/src/main/webapp/resources/js/plotting.js | 3 +++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java index ddf6a5f..318447d 100644 --- a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java +++ b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java @@ -364,8 +364,11 @@ private void createTermCountChart() { ChartValues cv = new ChartValues( "GO Term Counts by Edition", "Count of Unique GO Terms", "Date" ); Series significantTerms = new Series( "Significant Terms" ); - Series allTerms = new Series( "All Tested Terms" ); - Series rejectedTerms = new Series( "Rejected Terms" ); + + SeriesExtra allTerms = new SeriesExtra( "All Tested Terms" ); + allTerms.putExtra( "visible", false ); + SeriesExtra rejectedTerms = new SeriesExtra( "Rejected Terms" ); + rejectedTerms.putExtra( "visible", false ); for ( Entry> rawResultsEntry : combinedAnalysis.getEnrichmentAnalysis().getRawResults() .entrySet() ) { diff --git a/gotrack/src/main/webapp/resources/js/plotting.js b/gotrack/src/main/webapp/resources/js/plotting.js index 50cd7fe..0ed5995 100644 --- a/gotrack/src/main/webapp/resources/js/plotting.js +++ b/gotrack/src/main/webapp/resources/js/plotting.js @@ -292,6 +292,9 @@ if (!isUndefined(series.extra) && !isUndefined(series.extra.title)) { seriesOptions.title = series.extra.title; } + if (!isUndefined(series.extra) && !isUndefined(series.extra.visible)) { + seriesOptions.visible = series.extra.visible; + } options.series.push(seriesOptions) } From e196d62331b67cdbb2d526961eb99c1ee775ffa5 Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Wed, 21 Mar 2018 10:55:57 -0700 Subject: [PATCH 11/61] Stability score now shows significance volatility Coefficient of variation now based on p-value signifiance cutoff instead of mean. This gives a sense of how volatile it is WRT its signifiance. Stability colour scale is now absolute instead of quantile based and is a bit more lenient. Stability column infinity and NaN replaced with No Change and No Data, respectively. Related to issue #36. --- .../gotrack/analysis/StabilityAnalysis.java | 10 +++-- .../pavlab/gotrack/beans/EnrichmentView.java | 44 ++----------------- gotrack/src/main/webapp/enrichment.xhtml | 4 +- .../composites/enrichmentResultsTable.xhtml | 4 +- 4 files changed, 15 insertions(+), 47 deletions(-) diff --git a/gotrack/src/main/java/ubc/pavlab/gotrack/analysis/StabilityAnalysis.java b/gotrack/src/main/java/ubc/pavlab/gotrack/analysis/StabilityAnalysis.java index 29bed2c..6a182fc 100644 --- a/gotrack/src/main/java/ubc/pavlab/gotrack/analysis/StabilityAnalysis.java +++ b/gotrack/src/main/java/ubc/pavlab/gotrack/analysis/StabilityAnalysis.java @@ -106,6 +106,10 @@ protected boolean removeEldestEntry( Map.Entry eldest ) { // iterate over editions in order for ( Edition ed : orderedEditions ) { + + // P-Value cutoff for significance + Double cutoff = analysis.getCutoff( ed ); + EnrichmentResult er = data.get( ed ); if ( er != null ) { if ( previousResult != null ) { @@ -166,12 +170,12 @@ protected boolean removeEldestEntry( Map.Entry eldest ) { } // calculate scores (very similar to a coefficient of variation) - double score = ( maxp - minp ) / er.getPvalue(); + double score = ( maxp - minp ) / cutoff; runningScore += score; runningScoreCnt++; - scores.put( ed, new StabilityScore( b[0], b[1], minp, maxp, Math.log( score ), - Math.log( runningScore / runningScoreCnt ) ) ); + scores.put( ed, new StabilityScore( b[0], b[1], minp, maxp, -Math.log( score ), + -Math.log( runningScore / runningScoreCnt ) ) ); // if ( er.getPvalue() > maxp || er.getPvalue() < minp ) { // log.debug( t.getGoId() ); diff --git a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java index 318447d..df87d86 100644 --- a/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java +++ b/gotrack/src/main/java/ubc/pavlab/gotrack/beans/EnrichmentView.java @@ -185,10 +185,6 @@ public String getLabel() { // ******************************************************** - - // Stability Data - private Map stabilityRangeCache = Maps.newConcurrentMap(); - // Enrichment Chart @Getter @Setter @@ -298,7 +294,6 @@ public void enrich() { statusPoller ); enrichmentResults = combinedAnalysis.getEnrichmentAnalysis().getResults(); - stabilityRangeCache = Maps.newConcurrentMap(); statusPoller.newStatus( "Creating tables and charts...", 90 ); @@ -797,38 +792,6 @@ private void resetFetchTermInformation() { selectedValueName = null; } - // Stability --------------------------------------------------------------------------------------- - - private double[] stabilityRange( Edition ed ) { - if ( ed == null ) { - return null; - } - - double[] range = stabilityRangeCache.get( ed ); - if ( range == null ) { - // Figure out range of values for Stability scores - - Map editionData = enrichmentResults.get( ed ); - - double minStability = Double.POSITIVE_INFINITY; - double maxStability = Double.NEGATIVE_INFINITY; - for ( GeneOntologyTerm term : editionData.keySet() ) { - StabilityScore sc = combinedAnalysis.getStabilityAnalysis().getStabilityScores( term, ed ); - Double v = sc.getScore(); - if ( !v.isInfinite() && !v.isNaN() ) { - if ( v > maxStability ) maxStability = v; - if ( v < minStability ) minStability = v; - } - } - range = new double[2]; - range[0] = minStability; - range[1] = maxStability; - stabilityRangeCache.put( ed, range ); - } - - return range; - } - // Enrichment Table --------------------------------------------------------------------------------------- public void loadEnrichmentTableData() { @@ -848,7 +811,6 @@ private void loadEnrichmentTableData( Edition ed ) { enrichmentTableEdition = ed; if ( ed != null ) { - double[] stabilityRange = stabilityRange( ed ); Set sigTerms = combinedAnalysis.getEnrichmentAnalysis().getTermsSignificant( ed ); Map editionData = enrichmentResults.get( ed ); for ( Entry termEntry : editionData.entrySet() ) { @@ -857,9 +819,9 @@ private void loadEnrichmentTableData( Edition ed ) { StabilityScore sc = combinedAnalysis.getStabilityAnalysis().getStabilityScores( term, ed ); Double val = sc.getScore(); int quantile = 0; - if ( !val.isNaN() && !val.isInfinite() ) { - quantile = (int) Math - .round( 19 * (val - stabilityRange[0]) / (stabilityRange[1] - stabilityRange[0]) ) + 1; + if ( !val.isNaN() ) { + // Scale from -8 -> 10 + quantile = (int) Math.max(1, Math.min(20, 20 - (Math.ceil( val ) + 8 ) )); } enrichmentTableValues diff --git a/gotrack/src/main/webapp/enrichment.xhtml b/gotrack/src/main/webapp/enrichment.xhtml index 426637a..5480628 100644 --- a/gotrack/src/main/webapp/enrichment.xhtml +++ b/gotrack/src/main/webapp/enrichment.xhtml @@ -823,8 +823,8 @@ to plot the term's p-value and 95% confidence interval over its history.

- Note: A stability score of -∞ means we saw no significant variation in Set Size or Hits over a given timeline (keep in mind this does - not mean the p-value stays constant as other numbers go into its calculation). A score with � or NaN means there was not enough available data. + Note: The stability score typically ranges between -10 and 10 with 10 being more stable than -10. A score of ∞ means we saw no significant variation in Set Size or Hits over a given timeline (keep in mind this does + not mean the p-value is constant). A score with � or NaN means there was not enough available data.

diff --git a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml index faab70a..be3f707 100644 --- a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml +++ b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml @@ -153,9 +153,11 @@ oncomplete="PF('enrichmentChartWdg').show();handleGraphSelected(xhr, status, args);"> - + + + From ae6575bcbe2a84991bb8b5eb6dccc2ad9ba9197d Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Wed, 21 Mar 2018 14:57:07 -0700 Subject: [PATCH 12/61] Resolve #36: Help on stability is incomplete. Adds more contextual help in enrichment view, specifically to each column and row of row expansion. Reorganizes the overlaypanel to be closer to their calling button. Related to issue #37. --- gotrack/src/main/webapp/enrichment.xhtml | 210 ++++++------------ .../composites/enrichmentResultsTable.xhtml | 192 ++++++++++++++-- .../src/main/webapp/resources/css/common.css | 12 +- .../main/webapp/resources/css/enrichment.css | 4 +- 4 files changed, 254 insertions(+), 164 deletions(-) diff --git a/gotrack/src/main/webapp/enrichment.xhtml b/gotrack/src/main/webapp/enrichment.xhtml index 5480628..f6d403d 100644 --- a/gotrack/src/main/webapp/enrichment.xhtml +++ b/gotrack/src/main/webapp/enrichment.xhtml @@ -62,6 +62,9 @@ + +

Select the species you would like to run an enrichment analysis for.

+
@@ -116,6 +119,9 @@ + +

Which aspects (Cellular Component, Biological Process, Molecular Function) to include in the analysis.

+
@@ -132,6 +138,13 @@ + +

Type of multiple tests correction to apply.

+
    +
  • Bonferroni: Reject null hypotheses who P-values are less than the given threshold.
  • +
  • BH step-up: Benjamini–Hochberg procedure, controls FDR at given threshold level.
  • +
+
@@ -147,6 +160,10 @@ + +

Threshold to use for the above multiple test correction method. This establishes the definition of "significant" for the results displays.

+ +
@@ -162,6 +179,9 @@ + +

Select only those terms with at least this number of genes associated with them. Used to to remove overly-specific terms from analysis.

+
@@ -176,6 +196,11 @@ + + +

Select only those terms with at most this number of genes associated with them (0 for no maximum). Used to remove overly-general terms from analysis.

+
+ @@ -195,6 +220,10 @@ + +

The analysis will generate a similarity plot. This plot can compare subsequent editions to each-other (PROXIMAL) or compare each edition to the most current (CURRENT). +

+
@@ -254,12 +283,46 @@
+ +
+

Description:

+

GO Term Counts by Edition shows counts of unique GO Terms associated with this each enrichment analysis over time.

+

Legend Descriptions:

+

All Tested Terms: Count of unique terms that passed all settings criteria.

+

Significant Terms: Count of unique terms that passed all settings criteria and were significant.

+

Rejected Terms: Count of unique terms that did not pass all settings criteria.

+ +

Controls:

+

<Click> any edition to view the enrichment results at that point in time in bottom table.

+

<Click> a legend item to toggle that series.

+

<Ctrl/Command> + <Click> a legend item to show only that series.

+
+
+ +
+

Description:

+

Enrichment Similarity shows Jaccard similarity of the sets of significantly enriched terms over time.

+ + +

Legend Descriptions:

+

The series differ in which sets of terms we are comparing:

+

All Terms: Compare all significant terms.

+

Top 5 Terms: Compare the top 5 terms.

+

Parents of Top Terms: Compare the top 5 terms and all of their ancestors.

+

Genes Backing Top Terms: Compare the genes that are responsible for the top 5 terms.

+ +

Controls:

+

<Click> any edition to view the term sets described above.

+

<Click> a legend item to toggle that series.

+

<Ctrl/Command> + <Click> a legend item to show only that series.

+
+
@@ -268,6 +331,17 @@
+ +
+

These buttons provide a means to visualize the changes in enrichment results over the + history of this hitlist. You may choose from plotting either the top 5 terms in every + edition or your selected terms By Rank or By P-Value.

+

If By Rank is chosen, you will be shown a Bump Chart of the corresponding terms + and their relative ranks over time. Areas of heavy change will have lots of crossing + lines (and thus appear darker) while areas of stability will have lots of parallel + lines (and thus appear lighter and cleaner)

+
+
- - -

Select the species you would like to run an enrichment analysis for.

-
- -

Which aspects (Cellular Component, Biological Process, Molecular Function) to include in the analysis.

-
- -

Type of multiple tests correction to apply.

-
    -
  • Bonferroni: Reject null hypotheses who P-values are less than the given threshold.
  • -
  • BH step-up: Benjamini–Hochberg procedure, controls FDR at given threshold level.
  • -
-
- - - -

Threshold to use for the above multiple test correction method. This establishes the definition of "significant" for the results displays.

- -
- - -

Select only those terms with at least this number of genes associated with them. Used to to remove overly-specific terms from analysis.

-
- -

Select only those terms with at most this number of genes associated with them (0 for no maximum). Used to remove overly-general terms from analysis.

-
- -

The analysis will generate a similarity plot. This plot can compare subsequent editions to each-other (PROXIMAL) or compare each edition to the most current (CURRENT). -

-
- - -
-

Description:

-

GO Term Counts by Edition shows counts of unique GO Terms associated with this each enrichment analysis over time.

-

Legend Descriptions:

-

All Tested Terms: Count of unique terms that passed all settings criteria.

-

Significant Terms: Count of unique terms that passed all settings criteria and were significant.

-

Rejected Terms: Count of unique terms that did not pass all settings criteria.

- -

Controls:

-

<Click> any edition to view the enrichment results at that point in time in bottom table.

-

<Click> a legend item to toggle that series.

-

<Ctrl/Command> + <Click> a legend item to show only that series.

-
-
- - -
-

Description:

-

Enrichment Similarity shows Jaccard similarity of the sets of significantly enriched terms over time.

- - -

Legend Descriptions:

-

The series differ in which sets of terms we are comparing:

-

All Terms: Compare all significant terms.

-

Top 5 Terms: Compare the top 5 terms.

-

Parents of Top Terms: Compare the top 5 terms and all of their ancestors.

-

Genes Backing Top Terms: Compare the genes that are responsible for the top 5 terms.

- -

Controls:

-

<Click> any edition to view the term sets described above.

-

<Click> a legend item to toggle that series.

-

<Ctrl/Command> + <Click> a legend item to show only that series.

-
-
- - - - -
-

Description:

-

Enrichment Results Table shows enrichment data for those terms that were significantly enriched at some point in their history.

-

- This means that not every term in table is significant at the currently chosen time-point, but it was necessarily significant as some point. -

- - -

Column Descriptions:

-

: View more details, such as which genes in your hit list are associated with the term.

-

Id: Gene Ontology Id. <Click> on the icons for links to QuickGO and its ancestry chart, respectively.

-

Aspect: One of Biological Process, Cellular Component, or Molecular Function.

-

Name: Description of the Gene Ontology Term.

-

Set Size: Number of genes in the background (currently all annotated genes) that are annotated with the given term.

-

Hits: Number of genes in the hitlist annotated with the given term.

-

P-Value: P-Value (after correction if Bonferroni).

-

- Recent Stability: Metric representing the variability of the term's p-value in its recent past (akin to the logarithm of the coefficient of variation). This is calculated using - six month rolling regressions on the historical changes in 'Set Size' and 'Hits'. <Click> on - to plot the term's p-value and 95% confidence interval over its history. -

-

- Note: The stability score typically ranges between -10 and 10 with 10 being more stable than -10. A score of ∞ means we saw no significant variation in Set Size or Hits over a given timeline (keep in mind this does - not mean the p-value is constant). A score with � or NaN means there was not enough available data. -

- -
- -
- - -
-

Description:

-

These buttons provide a means to visualize the changes in enrichment results over the history of this hitlist. You may choose from plotting either the top 5 terms in every edition or your selected terms By Rank or By P-Value.

-

If By Rank is chosen, you will be shown a Bump Chart of the corresponding terms and their relative ranks over time. Areas of heavy change will have lots of crossing lines (and thus appear darker) while areas of stability will have lots of parallel lines (and thus appear lighter and cleaner)

- -
-
- \ No newline at end of file diff --git a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml index be3f707..83b2404 100644 --- a/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml +++ b/gotrack/src/main/webapp/resources/composites/enrichmentResultsTable.xhtml @@ -38,6 +38,18 @@ oncomplete="postAjaxSortTable(PF('tableEnrichmentWdg'))"/> + +
+

This table shows enrichment data for those terms that were significantly enriched in this edition as well as those that were significant at some point in their history.

+

+ This means that not every term in the table is significant at the currently chosen edition, but it was necessarily significant as some point. +

+
+
+ @@ -72,11 +84,45 @@
+ + +
+

<Click> on to view more details, such as which genes in your hit list are associated with the term.

+ +
+
+ +
+ filterMatchMode="contains" + sortBy="#{entry.term.goId}" + style="width:120px;" + exportable="false"> + + +
+

+ Gene Ontology Id. +

+

+ <Click> on to view the term's QuickGO entry. +

+

+ <Click> on to view the term's ancestry chart, NOTE: we do not propagate across aspects whereas QuickGo does. +

+
+
+ + +
@@ -92,9 +138,24 @@ - + + +
+

+ One of Biological Process, Cellular Component, or Molecular Function. +

+
+
+ + +
+ filterMatchMode="contains" + sortBy="#{entry.term.name}"> + + +
+

+ Short description of the given term. +

+
+
+ + +
+ style="width:80px;"> + + +
+

+ Number of genes in the background (all annotated genes) that are annotated with the given term. +

+
+
+ + +
+ + + + +
+

+ Number of genes in the hit list annotated with the given term. +

+
+
+ + +
- + + +
+

+ P-Value (after correction if Bonferroni). Highlighted green if the term is significant in the selected edition. +

+
+
+ + +
@@ -144,11 +262,44 @@
- + + +
+

Metric representing the variability of the term's p-value in its recent past.

+

+ This is calculated using six month rolling regressions on the historical changes in + 'Pop. Hits' and 'Hits'. Given the results of these regressions we use their 95% confidence + intervals to calculate a 95% confidence interval around the p-value. This range is then used + to calculate the negative log of the coefficient of variation with respect to that edition's + significance cutoff to get the stability score. +

+

+ The stability score typically ranges between -10 and 10 with 10 being more + stable than -10. +

+

+ A score of No Change means we saw no significant variation in both + Pop. Hits and Hits over its recent past (keep in mind this does not mean the p-value + is constant). +

+

A score of No Data means there was not enough available.

+

+ <Click> on to plot the term's + p-value and 95% confidence interval over its history. +

+
+
+ + +
@@ -166,53 +317,54 @@ - + + - + - + - + - + - + - + - + - + diff --git a/gotrack/src/main/webapp/resources/css/common.css b/gotrack/src/main/webapp/resources/css/common.css index 07656cc..50a1ce8 100644 --- a/gotrack/src/main/webapp/resources/css/common.css +++ b/gotrack/src/main/webapp/resources/css/common.css @@ -95,8 +95,8 @@ button.ui-button.icon-only span { button.ui-button.no-value { height: 12px; - width: 2.2em; - outline:none; + width: 1.5em; + outline: none; } button.ui-button.no-background { @@ -114,6 +114,8 @@ button.ui-button.no-background:hover { button.ui-button.no-value > span.ui-icon { margin-left: -8px; margin-top: -8px; + height: 100%; + width: 100%; } button.ui-button.no-value > span.ui-button-text { @@ -264,9 +266,9 @@ div.inline { padding: 5px; } -.overlay-help { - padding: 0.5em 0; -} +/*.overlay-help {*/ + /*padding: 0.5em 0;*/ +/*}*/ .overlay-help p { margin: 0.2em 1em; diff --git a/gotrack/src/main/webapp/resources/css/enrichment.css b/gotrack/src/main/webapp/resources/css/enrichment.css index fe039b5..fd433b6 100644 --- a/gotrack/src/main/webapp/resources/css/enrichment.css +++ b/gotrack/src/main/webapp/resources/css/enrichment.css @@ -215,7 +215,7 @@ tr.ui-widget-content.significant td:nth-last-child(2) { } div.ui-overlaypanel-content { - width: 600px; + max-width: 600px; text-align: left; } @@ -266,7 +266,5 @@ button.ui-button.absoluteBtn { } button.ui-button.absoluteBtn > span { - left: 5px; - top: 5px; z-index: 99999; } \ No newline at end of file From 6d807f1dd460f3a7e2d4632e54f2410bff2873ec Mon Sep 17 00:00:00 2001 From: JacobsonMT Date: Wed, 21 Mar 2018 15:00:50 -0700 Subject: [PATCH 13/61] Help on gene view tabs no longer toggles tab --- gotrack/src/main/webapp/genes.xhtml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gotrack/src/main/webapp/genes.xhtml b/gotrack/src/main/webapp/genes.xhtml index 2af9adc..46b5159 100644 --- a/gotrack/src/main/webapp/genes.xhtml +++ b/gotrack/src/main/webapp/genes.xhtml @@ -182,7 +182,8 @@ + type="button" + onclick="event.stopPropagation();"/>