Repository 'ngchm'
hg clone https://toolshed.g2.bx.psu.edu/repos/insilico-bob/ngchm

Changeset 7:2f45bc8d5b9b (2016-12-19)
Previous changeset 6:00fc62d280a0 (2016-12-19) Next changeset 8:15acc2ab7d1f (2016-12-21)
Commit message:
Uploaded
added:
._.
._.DS_Store
._NGCHMheatmap.xml
._heatmap.sh
._repository_dependencies.xml
TestFiles/._400x400-column-covariate.txt
TestFiles/._400x400-row-covariate.txt
TestFiles/._400x400.txt
TestFiles/._Galaxy400x400-noCovariates.ngchm
removed:
CHM.R
GalaxyMapGen.jar
MDAheatmap/MDAheatmap.mako
MDAheatmap/config/MDAheatmap.xml
MDAheatmap/css/NGCHM.css
MDAheatmap/images/cancel.png
MDAheatmap/images/full.png
MDAheatmap/images/full_selected.png
MDAheatmap/images/go.png
MDAheatmap/images/join.png
MDAheatmap/images/mdandersonlogo260x85.png
MDAheatmap/images/next.png
MDAheatmap/images/prev.png
MDAheatmap/images/ribbonH.png
MDAheatmap/images/ribbonH_selected.png
MDAheatmap/images/ribbonV.png
MDAheatmap/images/ribbonV_selected.png
MDAheatmap/images/split.png
MDAheatmap/images/zoom-in.png
MDAheatmap/images/zoom-out.png
MDAheatmap/javascript/.gitignore
MDAheatmap/javascript/ColorMapManager.js
MDAheatmap/javascript/DetailHeatMapDisplay.js
MDAheatmap/javascript/MatrixManager.js
MDAheatmap/javascript/NGCHM_Util.js
MDAheatmap/javascript/SelectionManager.js
MDAheatmap/javascript/SummaryHeatMapDisplay.js
MDAheatmap/javascript/lib/deflate.js
MDAheatmap/javascript/lib/inflate.js
MDAheatmap/javascript/lib/z-worker.js
MDAheatmap/javascript/lib/zip.js
MDAheatmap/javascript/temp.js
MDAheatmap/oldstatic/css/NGCHM.css
MDAheatmap/oldstatic/images/full.png
MDAheatmap/oldstatic/images/full_selected.png
MDAheatmap/oldstatic/images/join.png
MDAheatmap/oldstatic/images/mdandersonlogo260x85.png
MDAheatmap/oldstatic/images/ribbonH.png
MDAheatmap/oldstatic/images/ribbonH_selected.png
MDAheatmap/oldstatic/images/ribbonV.png
MDAheatmap/oldstatic/images/ribbonV_selected.png
MDAheatmap/oldstatic/images/split.png
MDAheatmap/oldstatic/images/zoom-in.png
MDAheatmap/oldstatic/images/zoom-out.png
MDAheatmap/oldstatic/javascript/.gitignore
MDAheatmap/oldstatic/javascript/ColorMapManager.js
MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js
MDAheatmap/oldstatic/javascript/MatrixManager.js
MDAheatmap/oldstatic/javascript/NGCHM_Util.js
MDAheatmap/oldstatic/javascript/SelectionManager.js
MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js
MDAheatmap/oldstatic/javascript/lib/deflate.js
MDAheatmap/oldstatic/javascript/lib/inflate.js
MDAheatmap/oldstatic/javascript/lib/z-worker.js
MDAheatmap/oldstatic/javascript/lib/zip.js
MDAheatmap/oldstatic/javascript/temp.js
MDAheatmap/static/css/NGCHM.css
MDAheatmap/static/images/addButton.png
MDAheatmap/static/images/breakButtonOff.png
MDAheatmap/static/images/breakButtonOn.png
MDAheatmap/static/images/cancel.png
MDAheatmap/static/images/classButtonOff.png
MDAheatmap/static/images/classButtonOn.png
MDAheatmap/static/images/closeButton.png
MDAheatmap/static/images/covariateBarsOff.png
MDAheatmap/static/images/covariateBarsOn.png
MDAheatmap/static/images/createPdf.png
MDAheatmap/static/images/dataLayersOff.png
MDAheatmap/static/images/dataLayersOn.png
MDAheatmap/static/images/filterClassButton.png
MDAheatmap/static/images/full.png
MDAheatmap/static/images/full_selected.png
MDAheatmap/static/images/gear.png
MDAheatmap/static/images/gearDis.png
MDAheatmap/static/images/gear_big.png
MDAheatmap/static/images/go.png
MDAheatmap/static/images/join.png
MDAheatmap/static/images/mdandersonlogo260x85.png
MDAheatmap/static/images/minusButton.png
MDAheatmap/static/images/next.png
MDAheatmap/static/images/pdf.png
MDAheatmap/static/images/plusButton.png
MDAheatmap/static/images/prefApply.png
MDAheatmap/static/images/prefBack.png
MDAheatmap/static/images/prefCancel.png
MDAheatmap/static/images/prefSave.png
MDAheatmap/static/images/prev.png
MDAheatmap/static/images/removeFilterClassButton.png
MDAheatmap/static/images/ribbonH.png
MDAheatmap/static/images/ribbonH_selected.png
MDAheatmap/static/images/ribbonV.png
MDAheatmap/static/images/ribbonV_selected.png
MDAheatmap/static/images/rowsColsOff.png
MDAheatmap/static/images/rowsColsOn.png
MDAheatmap/static/images/save.png
MDAheatmap/static/images/searchButton.png
MDAheatmap/static/images/split.png
MDAheatmap/static/images/zoom-in.png
MDAheatmap/static/images/zoom-out.png
MDAheatmap/static/javascript/.gitignore
MDAheatmap/static/javascript/ColorMapManager.js
MDAheatmap/static/javascript/DetailHeatMapDisplay.js
MDAheatmap/static/javascript/MatrixManager.js
MDAheatmap/static/javascript/NGCHM_Util.js
MDAheatmap/static/javascript/PdfGenerator.js
MDAheatmap/static/javascript/SelectionManager.js
MDAheatmap/static/javascript/SummaryHeatMapDisplay.js
MDAheatmap/static/javascript/UserHelpManager.js
MDAheatmap/static/javascript/UserPreferenceManager.js
MDAheatmap/static/javascript/UserPreferenceManager.js.sav
MDAheatmap/static/javascript/custom.js
MDAheatmap/static/javascript/lib/deflate.js
MDAheatmap/static/javascript/lib/inflate.js
MDAheatmap/static/javascript/lib/jspdf.debug.js
MDAheatmap/static/javascript/lib/z-worker.js
MDAheatmap/static/javascript/lib/zip.js
MDAheatmap/templates/MDAheatmap.mako
MDAheatmap/templates/MDAheatmap.oldmako
NGCHMheatmap.xml
TestFiles/400x400-column-covariate.txt
TestFiles/400x400-row-covariate.txt
TestFiles/400x400.txt
TestFiles/Galaxy400x400-noCovariates.ngchm
heatmap.sh
naNGCHMheatmap/._.DS_Store
naNGCHMheatmap/._NGCHMheatmap.xml
naNGCHMheatmap/._heatmap.sh
naNGCHMheatmap/._repository_dependencies.xml
naNGCHMheatmap/CHM.R
naNGCHMheatmap/GalaxyMapGen.jar
naNGCHMheatmap/MDAheatmap/._.DS_Store
naNGCHMheatmap/MDAheatmap/MDAheatmap.mako
naNGCHMheatmap/MDAheatmap/config/MDAheatmap.xml
naNGCHMheatmap/MDAheatmap/css/NGCHM.css
naNGCHMheatmap/MDAheatmap/images/cancel.png
naNGCHMheatmap/MDAheatmap/images/full.png
naNGCHMheatmap/MDAheatmap/images/full_selected.png
naNGCHMheatmap/MDAheatmap/images/go.png
naNGCHMheatmap/MDAheatmap/images/join.png
naNGCHMheatmap/MDAheatmap/images/mdandersonlogo260x85.png
naNGCHMheatmap/MDAheatmap/images/next.png
naNGCHMheatmap/MDAheatmap/images/prev.png
naNGCHMheatmap/MDAheatmap/images/ribbonH.png
naNGCHMheatmap/MDAheatmap/images/ribbonH_selected.png
naNGCHMheatmap/MDAheatmap/images/ribbonV.png
naNGCHMheatmap/MDAheatmap/images/ribbonV_selected.png
naNGCHMheatmap/MDAheatmap/images/split.png
naNGCHMheatmap/MDAheatmap/images/zoom-in.png
naNGCHMheatmap/MDAheatmap/images/zoom-out.png
naNGCHMheatmap/MDAheatmap/javascript/.gitignore
naNGCHMheatmap/MDAheatmap/javascript/ColorMapManager.js
naNGCHMheatmap/MDAheatmap/javascript/DetailHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/javascript/MatrixManager.js
naNGCHMheatmap/MDAheatmap/javascript/NGCHM_Util.js
naNGCHMheatmap/MDAheatmap/javascript/SelectionManager.js
naNGCHMheatmap/MDAheatmap/javascript/SummaryHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/javascript/lib/deflate.js
naNGCHMheatmap/MDAheatmap/javascript/lib/inflate.js
naNGCHMheatmap/MDAheatmap/javascript/lib/z-worker.js
naNGCHMheatmap/MDAheatmap/javascript/lib/zip.js
naNGCHMheatmap/MDAheatmap/javascript/temp.js
naNGCHMheatmap/MDAheatmap/oldstatic/css/NGCHM.css
naNGCHMheatmap/MDAheatmap/oldstatic/images/full.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/full_selected.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/join.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/mdandersonlogo260x85.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH_selected.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV_selected.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/split.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-in.png
naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-out.png
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/.gitignore
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/ColorMapManager.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/MatrixManager.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/NGCHM_Util.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SelectionManager.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/deflate.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/inflate.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/z-worker.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/zip.js
naNGCHMheatmap/MDAheatmap/oldstatic/javascript/temp.js
naNGCHMheatmap/MDAheatmap/static/css/NGCHM.css
naNGCHMheatmap/MDAheatmap/static/images/addButton.png
naNGCHMheatmap/MDAheatmap/static/images/breakButtonOff.png
naNGCHMheatmap/MDAheatmap/static/images/breakButtonOn.png
naNGCHMheatmap/MDAheatmap/static/images/cancel.png
naNGCHMheatmap/MDAheatmap/static/images/classButtonOff.png
naNGCHMheatmap/MDAheatmap/static/images/classButtonOn.png
naNGCHMheatmap/MDAheatmap/static/images/closeButton.png
naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOff.png
naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOn.png
naNGCHMheatmap/MDAheatmap/static/images/createPdf.png
naNGCHMheatmap/MDAheatmap/static/images/dataLayersOff.png
naNGCHMheatmap/MDAheatmap/static/images/dataLayersOn.png
naNGCHMheatmap/MDAheatmap/static/images/filterClassButton.png
naNGCHMheatmap/MDAheatmap/static/images/full.png
naNGCHMheatmap/MDAheatmap/static/images/full_selected.png
naNGCHMheatmap/MDAheatmap/static/images/gear.png
naNGCHMheatmap/MDAheatmap/static/images/gearDis.png
naNGCHMheatmap/MDAheatmap/static/images/gear_big.png
naNGCHMheatmap/MDAheatmap/static/images/go.png
naNGCHMheatmap/MDAheatmap/static/images/join.png
naNGCHMheatmap/MDAheatmap/static/images/mdandersonlogo260x85.png
naNGCHMheatmap/MDAheatmap/static/images/minusButton.png
naNGCHMheatmap/MDAheatmap/static/images/next.png
naNGCHMheatmap/MDAheatmap/static/images/pdf.png
naNGCHMheatmap/MDAheatmap/static/images/plusButton.png
naNGCHMheatmap/MDAheatmap/static/images/prefApply.png
naNGCHMheatmap/MDAheatmap/static/images/prefBack.png
naNGCHMheatmap/MDAheatmap/static/images/prefCancel.png
naNGCHMheatmap/MDAheatmap/static/images/prefSave.png
naNGCHMheatmap/MDAheatmap/static/images/prev.png
naNGCHMheatmap/MDAheatmap/static/images/removeFilterClassButton.png
naNGCHMheatmap/MDAheatmap/static/images/ribbonH.png
naNGCHMheatmap/MDAheatmap/static/images/ribbonH_selected.png
naNGCHMheatmap/MDAheatmap/static/images/ribbonV.png
naNGCHMheatmap/MDAheatmap/static/images/ribbonV_selected.png
naNGCHMheatmap/MDAheatmap/static/images/rowsColsOff.png
naNGCHMheatmap/MDAheatmap/static/images/rowsColsOn.png
naNGCHMheatmap/MDAheatmap/static/images/save.png
naNGCHMheatmap/MDAheatmap/static/images/searchButton.png
naNGCHMheatmap/MDAheatmap/static/images/split.png
naNGCHMheatmap/MDAheatmap/static/images/zoom-in.png
naNGCHMheatmap/MDAheatmap/static/images/zoom-out.png
naNGCHMheatmap/MDAheatmap/static/javascript/.gitignore
naNGCHMheatmap/MDAheatmap/static/javascript/ColorMapManager.js
naNGCHMheatmap/MDAheatmap/static/javascript/DetailHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/static/javascript/MatrixManager.js
naNGCHMheatmap/MDAheatmap/static/javascript/NGCHM_Util.js
naNGCHMheatmap/MDAheatmap/static/javascript/PdfGenerator.js
naNGCHMheatmap/MDAheatmap/static/javascript/SelectionManager.js
naNGCHMheatmap/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js
naNGCHMheatmap/MDAheatmap/static/javascript/UserHelpManager.js
naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js
naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js.sav
naNGCHMheatmap/MDAheatmap/static/javascript/custom.js
naNGCHMheatmap/MDAheatmap/static/javascript/lib/deflate.js
naNGCHMheatmap/MDAheatmap/static/javascript/lib/inflate.js
naNGCHMheatmap/MDAheatmap/static/javascript/lib/jspdf.debug.js
naNGCHMheatmap/MDAheatmap/static/javascript/lib/z-worker.js
naNGCHMheatmap/MDAheatmap/static/javascript/lib/zip.js
naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.mako
naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.oldmako
naNGCHMheatmap/NGCHMheatmap.xml
naNGCHMheatmap/TestFiles/._400x400-column-covariate.txt
naNGCHMheatmap/TestFiles/._400x400-row-covariate.txt
naNGCHMheatmap/TestFiles/._400x400.txt
naNGCHMheatmap/TestFiles/._Galaxy400x400-noCovariates.ngchm
naNGCHMheatmap/TestFiles/400x400-column-covariate.txt
naNGCHMheatmap/TestFiles/400x400-row-covariate.txt
naNGCHMheatmap/TestFiles/400x400.txt
naNGCHMheatmap/TestFiles/Galaxy400x400-noCovariates.ngchm
naNGCHMheatmap/heatmap.sh
naNGCHMheatmap/repository_dependencies.xml
repository_dependencies.xml
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b ._.
b
Binary file ._. has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b ._.DS_Store
b
Binary file ._.DS_Store has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b ._NGCHMheatmap.xml
b
Binary file ._NGCHMheatmap.xml has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b ._heatmap.sh
b
Binary file ._heatmap.sh has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b ._repository_dependencies.xml
b
Binary file ._repository_dependencies.xml has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b CHM.R
--- a/CHM.R Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,125 +0,0 @@
-### This method generates a row and column ordering given an input matrix and ordering methods.
-###
-### matrixData - numeric matrix 
-### rowOrderMethod - Hierarchical, Original, Random
-### rowDistanceMeasure - For clustering, distance measure. May be: euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation.
-### rowAgglomerationMethod - For clustering, agglomeration method.  May be:  'average' for Average Linkage, 'complete' for Complete Linkage,
-###                                                                          'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.
-### colOrderMethod 
-### colDistanceMeasure
-### colAgglomerationMethod
-### rowOrderFile - output file of order of rows 
-### rowDendroFile - output file of row dendrogram  
-### colOrderFile - output file of order of cols
-### colDendroFile - output file of col dendrogram
-
-performDataOrdering<-function(dataFile, rowOrderMethod, rowDistanceMeasure, rowAgglomerationMethod, colOrderMethod, colDistanceMeasure, colAgglomerationMethod,rowOrderFile, colOrderFile, rowDendroFile, colDendroFile)
-{ 
-   dataMatrix = read.table(dataFile, header=TRUE, sep = "\t", row.names = 1, as.is=TRUE, na.strings=c("NA","N/A","-","?"))
-   rowOrder <-  createOrdering(dataMatrix, rowOrderMethod, "row", rowDistanceMeasure, rowAgglomerationMethod)  
-   if (rowOrderMethod == "Hierarchical") {
-      writeHCDataTSVs(rowOrder, rowDendroFile, rowOrderFile)
-   } else {
-      writeOrderTSV(rowOrder, rownames(dataMatrix), rowOrderFile)
-   }
-
-   colOrder <-  createOrdering(dataMatrix, colOrderMethod, "col", colDistanceMeasure, colAgglomerationMethod)  
-   if (colOrderMethod == "Hierarchical") {
-      writeHCDataTSVs(colOrder, colDendroFile, colOrderFile)
-   } else {
-      writeOrderTSV(colOrder, colnames(dataMatrix), colOrderFile)
-   }
-}
-
-#creates output files for hclust ordering
-writeHCDataTSVs<-function(uDend, outputHCDataFileName, outputHCOrderFileName)
-{
-   data<-cbind(uDend$merge, uDend$height, deparse.level=0)
-   colnames(data)<-c("A", "B", "Height")
-   write.table(data, file = outputHCDataFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)

-   data=matrix(,length(uDend$labels),2);
-   for (i in 1:length(uDend$labels)) {
-      data[i,1] = uDend$labels[i];
-      data[i,2] = which(uDend$order==i);
-   }
-   colnames(data)<-c("Id", "Order")
-   write.table(data, file = outputHCOrderFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)
-}
-
-#creates order file for non-clustering methods
-writeOrderTSV<-function(newOrder, originalOrder, outputHCOrderFileName)
-{
-   data=matrix(,length(originalOrder),2);
-   for (i in 1:length(originalOrder)) {
-      data[i,1] = originalOrder[i];
-      data[i,2] = which(newOrder==originalOrder[i]);
-   }
-   colnames(data)<-c("Id", "Order")
-   write.table(data, file = outputHCOrderFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)
-}
-
-
-
-createOrdering<-function(matrixData, orderMethod, direction, distanceMeasure, agglomerationMethod)
-{
-  ordering <- NULL
-
-  if (orderMethod == "Hierarchical")
-  {
-
-    # Compute dendrogram for "Distance Metric"
-    distVals <- NULL
-    if(direction=="row") {
-      if (distanceMeasure == "correlation") {
-        geneGeneCor <- cor(t(matrixData), use="pairwise")
-        distVals <- as.dist((1-geneGeneCor)/2)
-      } else {
-        distVals <- dist(matrixData, method=distanceMeasure)
-      }
-    } else { #column
-      if (distanceMeasure == "correlation") {
-        geneGeneCor <- cor(matrixData, use="pairwise")
-        distVals <- as.dist((1-geneGeneCor)/2)
-      } else {
-        distVals <- dist(t(matrixData), method=distanceMeasure)
-      }
-    }
-
-#    if (agglomerationMethod == "ward") {
-#      ordering <- hclust(distVals * distVals, method="ward.D2")
-#    } else {
-      ordering <- hclust(distVals, method=agglomerationMethod)
-#    }
-  }
-  else if (orderMethod == "Random")
-  {
-    if(direction=="row") {
-       headerList <- rownames(matrixData)
-       ordering <- sample(headerList, length(headerList)) 
-    } else {
-       headerList <- colnames(matrixData)
-       ordering <- sample(headerList, length(headerList)) 
-    }
-  }
-  else if (orderMethod == "Original")
-  {
-    if(direction=="row") {
-       ordering <- rownames(matrixData) 
-    } else {
-       ordering <- colnames(matrixData) 
-    }
-  } else {
-    stop("createOrdering -- failed to find ordering method")
-  }
-  return(ordering)
-}
-### Initialize command line arguments and call performDataOrdering
-
-options(warn=-1)
-
-args = commandArgs(TRUE)
-
-performDataOrdering(dataFile=args[1], rowOrderMethod=args[2], rowDistanceMeasure=args[3], rowAgglomerationMethod=args[4], colOrderMethod=args[5], colDistanceMeasure=args[6], colAgglomerationMethod=args[7],rowOrderFile=args[8], colOrderFile=args[9], rowDendroFile=args[10], colDendroFile=args[11])
-
-#suppressWarnings(performDataOrdering(dataFile=args[1], rowOrderMethod=args[2], rowDistanceMeasure=args[3], rowAgglomerationMethod=args[4], colOrderMethod=args[5], colDistanceMeasure=args[6], colAgglomerationMethod=args[7],rowOrderFile=args[8], colOrderFile=args[9], rowDendroFile=args[10], colDendroFile=args[11]))
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b GalaxyMapGen.jar
b
Binary file GalaxyMapGen.jar has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/MDAheatmap.mako
--- a/MDAheatmap/MDAheatmap.mako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,96 +0,0 @@
-<HTML>
-   <HEAD>
-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>
-
- <meta id='viewport' name ="viewport" content="">
-
-   </HEAD>
-   
-   <BODY onresize="chmResize()">
-    <%
-       from galaxy import model
-       users_current_history = trans.history
-       url_dict = { }
-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]
-       output_datasets = hda.creating_job.output_datasets
-       for o in output_datasets:
-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )
-    %>
-
-    <script>
-       heatMap = null;  //global - heatmap object.
-
-       var url_dict = ${ h.dumps( url_dict ) };
-       var hdaId   = '${trans.security.encode_id( hda.id )}';
-       var hdaExt  = '${hda.ext}';
-       var ajaxUrl = "${h.url_for( controller='/datasets', action='index')}/" + hdaId + "/display?to_ext=" + hdaExt;
-
-       var xmlhttp=new XMLHttpRequest();
-       xmlhttp.open("GET", ajaxUrl, true);
-       xmlhttp.responseType = 'blob';
-       xmlhttp.onload = function(e) {
-           if (this.status == 200) {
-               var blob = new Blob([this.response], {type: 'compress/zip'});
-               zip.useWebWorkers = false;
-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);
-               var name = 'galaxydata';
-               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);
-               heatMap.addEventListener(processDetailMapUpdate);
-               initSummaryDisplay();
-               initDetailDisplay()
-           }
-       };
-       xmlhttp.send();
-
-       function chmResize() {
-          detailResize();
-       }
-
-    </script>
-
-    <div class="mdaServiceHeader">
-        <div class="mdaServiceHeaderLogo">
-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">
-        </div>
-      
-    <div id='detail_buttons' align="center" style="display:none">
-  <img id='zoomOut_btn' src='images/zoom-out.png' alt='Zoom Out' onmouseover='detailDataToolHelp(this,"Zoom Out")' onclick='detailDataZoomOut();'   align="top"   />
-     <img id='zoomIn_btn' src='images/zoom-in.png' alt='Zoom In' onmouseover='detailDataToolHelp(this,"Zoom In")' onclick='detailDataZoomIn();' align="top"   />
-     <img id='full_btn' src='images/full_selected.png' alt='Full' onmouseover='detailDataToolHelp(this,"Normal View")' onclick='detailNormal();' align="top"   />
-     <img id='ribbonH_btn' src='images/ribbonH.png' alt='Ribbon H' onmouseover='detailDataToolHelp(this,"Horizontal Ribbon View")' onclick='detailHRibbonButton();' align="top"  />
-     <img id='ribbonV_btn' src='images/ribbonV.png' alt='Ribbon V' onmouseover='detailDataToolHelp(this,"Vertical Ribbon View")' onclick='detailVRibbonButton();'  align="top"  />
-    <span style='display: inline-block;'><b>Search: </b><input type="text" id="search_text" name="search" onkeypress='clearSrchBtns();' onchange='detailSearch();'
-                                                         onmouseover='detailDataToolHelp(this,"Search Row/Column Labels. Separate search terms with spaces or commas. Use * for wild card matching. Hit enter or Go to run the search. If the search box turns red none of the search terms were found. If it turns yellow only some of the search terms were found.", 200)' ></span>
-     <img id='go_btn' src='images/go.png' alt='Go' onmouseover='detailDataToolHelp(this,"Search Row/Column Labels")'  onclick='detailSearch();' align="top"  />
-     <img id='prev_btn' src='images/prev.png' alt='Previous' onmouseover='userHelpClose();' style="display:none;" onclick='searchPrev();'  align="top"  />
-     <img id='next_btn' src='images/next.png' alt='Next' onmouseover='userHelpClose();' style="display:none;" onclick='searchNext();'  align="top"  />
-     <img id='cancel_btn' src='images/cancel.png' alt='Cancel' onmouseover='detailDataToolHelp(this,"Clear current search")' style="display:none;" onclick='clearSearch();'  align="top"  />
-       </div>
-    </div>
-
-    <div id="container">
-
-       <div id='summary_chm' style='position: relative;'>
-          <canvas id='summary_canvas'></canvas>
- <div id='sumlabelDiv' style="display: inline-block"></div>
-       </div>
-
-   <div id= 'divider' style='position: relative;' onmousedown="dividerStart()" ontouchstart="dividerStart()">
-   </div>
-
-       <div id='detail_chm' style='position: relative;'>
-          <canvas id='detail_canvas' style='display: inline-block'></canvas>
-          <div id='labelDiv' style="display: inline-block"></div>
-       </div>
-   </div>
-
-</BODY >
-</HTML>
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/config/MDAheatmap.xml
--- a/MDAheatmap/config/MDAheatmap.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE visualization SYSTEM "../../visualization.dtd">
-<visualization name="MDAheatmap">
- <data_sources>
-    <data_source>
-       <model_class>HistoryDatasetAssociation</model_class>
-       <test test_attr="extension">zip</test>
-       <to_param param_attr="id">dataset_id</to_param>
-    </data_source>
- </data_sources>
- <params>
-    <param type="dataset" var_name_in_template="hda" required="true">dataset_id</param>
- </params>
- <entry_point entry_point_type="mako">MDAheatmap.mako</entry_point>
-</visualization> 
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/css/NGCHM.css
--- a/MDAheatmap/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,121 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-
-#divider{
- height: 82%;
- width: 5px;
- vertical-align:top;
- display:inline-block;
- background: #666666;
- cursor: ew-resize;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:98%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#detail_buttons {
- margin-top: 10px;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/cancel.png
b
Binary file MDAheatmap/images/cancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/full.png
b
Binary file MDAheatmap/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/full_selected.png
b
Binary file MDAheatmap/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/go.png
b
Binary file MDAheatmap/images/go.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/join.png
b
Binary file MDAheatmap/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/mdandersonlogo260x85.png
b
Binary file MDAheatmap/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/next.png
b
Binary file MDAheatmap/images/next.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/prev.png
b
Binary file MDAheatmap/images/prev.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/ribbonH.png
b
Binary file MDAheatmap/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/ribbonH_selected.png
b
Binary file MDAheatmap/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/ribbonV.png
b
Binary file MDAheatmap/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/ribbonV_selected.png
b
Binary file MDAheatmap/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/split.png
b
Binary file MDAheatmap/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/zoom-in.png
b
Binary file MDAheatmap/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/images/zoom-out.png
b
Binary file MDAheatmap/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/.gitignore
--- a/MDAheatmap/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/ColorMapManager.js
--- a/MDAheatmap/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,222 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeys: This function calculates and returns an
-  * array containing 10 continuous threshold breakpoint keys from the original thresholds 
-  * submitted.  It is used only for rendering a continuous classification bar help.  
-  **********************************************************************************/
- this.getContinuousThresholdKeys = function(){
-     var conThresh = new Array();
-     var bottomThresh = thresholds[0];
-     var threshSize = this.getContinuousThresholdKeySize();
-     //Add first threshold from original threshold list
-     conThresh.push(bottomThresh);
-     //Calculate and create "interim" 8 thresholds
-     for (var i = 1; i <= 8; i++){
-      conThresh.push(bottomThresh+Math.floor(threshSize*i));
-     }
-     //Add last threshold from original threshold list
-     conThresh.push(thresholds[thresholds.length - 1]);  
-     return conThresh;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeySize: This function calculates the size 
-  * separating each "interim" threshold key for a continuous classification bar.  
-  **********************************************************************************/
- this.getContinuousThresholdKeySize = function(){
-     var bottomThresh = thresholds[0];
-     var topThresh = thresholds[thresholds.length - 1]; 
-     return (topThresh - bottomThresh) / 8;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- continue;
- }
- }
- } else {
- color = this.getColor(value);
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
- this.getRgbToHex = function(rgb) {
- var a = rgb.a
- var r = rgb.r
- var g = rgb.g
- var b = rgb.b
-     return ('#' + componentToHex(r) + componentToHex(g) + componentToHex(b));
- }
-
- function componentToHex(c) {
-     var hex = c.toString(16);
-     return hex.length == 1 ? "0" + hex : hex;
- }
-
-}
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/DetailHeatMapDisplay.js
--- a/MDAheatmap/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1743 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var userHelpOpen;\r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-\r\n-var detailDendroHeight = 105;\r\n-var detailDendroWidth = 105;\r\n-var normDetailDendroMatrixHeight = 200;\r\n-var rowDetailDendroMatrix,colDetailDendroMatrix;\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-var currentSearchItem;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'divider\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src="images/join.png";\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(10);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  (detailDataViewWidth + calculateTotalClassBarHeight("row") + detailDendroWidth);\r\n-\t\tdetCanvas.height = (detailDataViewHeight + calculateTotalClassBarHeight("column") + detailDendroHeight);\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = clickStart;\r\n-\tdocument.onmouseup = clickEnd;\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.addEventListener("touchmove", function(e){\r\n-\t\te.preventDefault();\r\n-\t\tif (e.touches){\r\n-\t    \tif (e.touches.length > 1){\r\n-\t    \t\treturn false;\r\n-\t    \t}\r\n-\t    }\r\n-\t})\r\n-\tdetCanvas.addEventListener("touchstart", function(e){\r\n-\t\tuserHelpClose();\r\n-\t\tclickStart(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchmove", function(e){\r\n-\t\te.stopPropagation();\r\n-\t\te.preventDefault();\r\n-\t\thandleMove(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchend", function(e){clickEnd(e)}, false);\r\n-\t\r\n-\tdetCanvas.addEventListener("gestureend",function(e){\r\n-\t\tif (e.scale > 1){\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\t} else if (e.scale < 1){\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\t}\r\n-\t},false)\r\n-\t\r\n-\t\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function clickStart(e){\r\n-\tuserHelpClose();\r\n-\tdragOffsetX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tdragOffsetY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\r\n-    mouseDown = true;\r\n-}\r\n-function clickEnd(e){\r\n-\tmouseDown = false;\r\n-\tvar dragEndX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tvar dragEndY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\tvar rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\tif (Math.abs(dragEndX - dragOffsetX) < colElementSize/10 && Math.abs(dragEndY - dragOffsetY) < rowElementSize/10){\r\n-\t\tuserHelpOpen(e);\r\n-\t}\r\n-}\r\n-\r\n-function handleDrag(e) {\r\n-    if(!mouseDown) return;\r\n-    var rowElementSize = dataBoxWidth * detCanvas.cli'..b'\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row")+detailDendroWidth;\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column")+detailDendroHeight;\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/MatrixManager.js
--- a/MDAheatmap/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,463 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different 'zoom' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = 'tn';\r\n-MatrixManager.SUMMARY_LEVEL = 's';\r\n-MatrixManager.RIBBON_VERT_LEVEL = 'rv';\r\n-MatrixManager.RIBBON_HOR_LEVEL = 'rh';\r\n-MatrixManager.DETAIL_LEVEL = 'd';\r\n-\r\n-MatrixManager.WEB_SOURCE = 'W';\r\n-MatrixManager.FILE_SOURCE = 'F';\r\n-\r\n-MatrixManager.Event_INITIALIZED = 'Init';\r\n-MatrixManager.Event_JSON = 'Json';\r\n-MatrixManager.Event_NEWDATA = 'NewData';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Return the row sample ratio for a given level\r\n-\tthis.getRowSampleRatio = function(level){\r\n-\t\treturn datalayers[level].rowSampleRatio;\r\n-\t}\r\n-\t\r\n-\t//Return the column sample ratio for a given level\r\n-\tthis.getColSampleRatio = function(level){\r\n-\t\treturn datalayers[level].colSampleRatio;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don't do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdatalayers[level].setReadWindow(row, column, numRows, numColumns);\r\n-    } \t\r\n-\r\n-\t// Retrieve color map Manager for this heat map.\r\n-\tthis.getColorMapManager = function() {\r\n-\t\tif (initialized != 1)\r\n-\t\t\treturn null;\r\n-\t\t\r\n-\t\tif (colorMapMgr == null ) {\r\n-\t\t\tcolorMapMgr = new ColorMapManager(colorMaps);\r\n-\t\t}\r\n-\t\treturn colorMapMgr;\r\n-\t}\r\n-\t\r\n-\t//Retrieve classifications\r\n-\tthis.getClassifications = function() {\r\n-\t\treturn classifications;\r\n-\t}\r\n-\t\r\n-\t//Get Row Labels\r\n-\tthis.getRowLabels = function() {\r\n-\t\treturn rowLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tth"..b' to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\t\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\r\n-    this.rowSampleRatio = jsonData.row_sample_ratio;\r\n-    this.colSampleRatio = jsonData.col_sample_ratio;\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endRowCalc = (row+(numRows-1))/rowsPerTile;\r\n-    \tvar endColCalc = (column+(numColumns-1))/colsPerTile;\r\n-\t\tvar endRowTile = Math.floor(endRowCalc)+(endRowCalc%1 > 0 ? 1 : 0);\r\n-\t\tvar endColTile = Math.floor(endColCalc)+(endColCalc%1 > 0 ? 1 : 0);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/NGCHM_Util.js
--- a/MDAheatmap/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,8 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/SelectionManager.js
--- a/MDAheatmap/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,386 +0,0 @@\n-/**\r\n- * This code is responsible for handling changes in position of selected heat map region.\r\n- * It handles mouse, keyboard, and button events that change the position of the selected\r\n- * region.  It also tracks whether the display is in a single window or split into two\r\n- * separate windows.  If in separate windows, local storage events are used to communicate\r\n- * changes between the two windows.  \r\n- */\r\n-\r\n-//Globals that provide information about heat map position selection.\r\n-\r\n-mode = null;          // Set to normal or ribbon vertical or ribbon horizontal \r\n-currentRow=null;      // Top row of current selected position\r\n-currentCol=null;      // Left column of the current selected position\r\n-dataPerRow=null;      // How many rows are included in the current selection\r\n-dataPerCol=null;      // How many columns in the current selection\r\n-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.\r\n-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.\r\n-var searchItems=[];   // Valid labels found from a user search\r\n-\r\n-                      //isSub will be set to true if windows are split and this is the child.\r\n-isSub = getURLParameter(\'sub\') == \'true\';  \r\n-hasSub = false;       //hasSub set to true if windows are split and this is the parent.\r\n-\r\n-\r\n-/* This routine is called when the selected row / column is changed.\r\n- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,\r\n- * and dataPerCol as desired. This method does redrawing and notification as necessary.  \r\n- */\r\n-function updateSelection() {\r\n-\tvar selected = "";\r\n-\t\t\r\n-\tif (!isSub) {\r\n-\t\t//We have the summary heat map so redraw the yellow selection box.\r\n-\t\tdrawLeftCanvasBox();\r\n-\t} \r\n-\tif (!hasSub) {\r\n-\t\t// Redraw based on mode type and selection. \r\n-\t\theatMap.setReadWindow(getLevelFromMode(MatrixManager.DETAIL_LEVEL),currentRow,currentCol,dataPerCol,dataPerRow);\r\n-\t\tdrawDetailHeatMap();\r\n-\t} \r\n-\t\r\n- \t//If summary and detail as split into two browsers.  Communicate the selection change\r\n-\t//to the other browser.\r\n-\tif (isSub || hasSub) {\r\n-\t\tlocalStorage.removeItem(\'event\');\r\n-\t\tlocalStorage.setItem(\'currentRow\', \'\' + currentRow);\r\n-\t\tlocalStorage.setItem(\'currentCol\', \'\' + currentCol);\r\n-\t\tlocalStorage.setItem(\'dataPerRow\', \'\' + dataPerRow);\r\n-\t\tlocalStorage.setItem(\'dataPerCol\', \'\' + dataPerCol);\r\n-\t\tlocalStorage.setItem(\'selectedStart\', \'\' + selectedStart);\r\n-\t\tlocalStorage.setItem(\'selectedStop\', \'\' + selectedStop);\r\n-\t\tlocalStorage.setItem(\'mode\', mode);\r\n-    \t//turn current search items into a comma delimited string.\r\n-    \tfor (var i=0; i < searchItems.length; i++) {selected+=";"+searchItems[i];}\r\n-\t\tlocalStorage.setItem(\'selected\', selected);\r\n-\t\tlocalStorage.setItem(\'event\', \'changePosition\');\r\n-\t}\t\t\r\n-}\r\n-\r\n-function changeMode(newMode) {\r\n-\t\r\n-\tif (!hasSub) {\r\n-\t\tif (newMode == \'RIBBONH\')\r\n-\t\t\tdetailHRibbon();\r\n-\t\tif (newMode == \'RIBBONV\')\r\n-\t\t\tdetailVRibbon();\r\n-\t\tif (newMode == \'NORMAL\')\r\n-\t\t\tdetailNormal();\r\n-\t} else {\r\n-\t\tlocalStorage.removeItem(\'event\');\r\n-\t\tlocalStorage.setItem(\'selectedStart\', \'\' + selectedStart);\r\n-\t\tlocalStorage.setItem(\'selectedStop\', \'\' + selectedStop);\r\n-\t\tlocalStorage.setItem(\'mode\', newMode);\r\n-\t\tlocalStorage.setItem(\'event\', \'changeMode\');\r\n-\t}\r\n-}\r\n-\r\n-/* Handle mouse scroll wheel events to zoom in / out.\r\n- */\r\n-function handleScroll(evt) {\r\n-\tevt.preventDefault();\r\n-\tif (evt.wheelDelta < 0 || evt.deltaY > 0 || evt.scale < 1) { //Zoom out\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem(\'event\');\r\n-\t\t\tlocalStorage.setItem(\'event\', \'zoomOut\' )\r\n-\t\t}\r\n-\t} else { // Zoom in\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem(\'event\');\r\n-\t\t\tlocalStorage.setItem(\'event\', \'zoomIn\' )\r\n-\t\t}\r\n-\t}\t\r\n-\treturn false;\r\n-} \t\t\r\n-\r\n-\r\n-function keyNavigate(e){\r\n-\tuserHelpClose();\r\n-    clearTimeout(de'..b" sample ratios (ratio of detail to summary) \r\n- * are used to calculate the proper detail coordinates.  \r\n- **********************************************************************************/\r\n-function setCurrentRowFromSum(sumRow) {\r\n-\t// Up scale current summary row to detail equivalent\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tif (rowSampleRatio > 1) {\r\n-\t\tcurrentRow = (sumRow*rowSampleRatio);\r\n-\t} else {\r\n-\t\tcurrentRow = sumRow;\r\n-\t}\r\n-}\r\n-function setCurrentColFromSum(sumCol) {\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tif (colSampleRatio > 1) {\r\n-\t\tcurrentCol = (sumCol*colSampleRatio);\r\n-\t} else {\r\n-\t\tcurrentCol = sumCol;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - setCurrentSumRow(Col): These functions perform the conversion of \r\n- * currentRow and currentCol coordinates from detail to summary.  This is done \r\n- * so that the  proper row/col location is set on the summary pane when a user clicks \r\n- * in the detail pane. This is used when the leftCanvasBox is drawn. The heatmap \r\n- * row/col sample ratios (ratio of detail to summary) are used to  calculate the \r\n- * proper detail coordinates.\r\n- **********************************************************************************/\r\n-function getCurrentSumRow() {\r\n-\t// Unless current mode is vertical ribbon, start with detail current row\r\n-\tvar currRow = currentRow;\r\n-\t// If current mode is vertical ribbon, start Selected Start and apply\r\n-\t// ribbon vertical sample ratio.\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rvRatio = heatMap.getRowSampleRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tcurrRow = selectedStart * rvRatio;\r\n-\t}\r\n-\t// Convert selected current row value to Summary level\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\treturn  Math.floor(currRow/rowSampleRatio)+1;\r\n-}\r\n-//Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumCol() {\r\n-\tvar currCol = currentCol;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rhRatio = heatMap.getColSampleRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tcurrCol = selectedStart * rhRatio;\r\n-\t}\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\treturn  Math.floor(currCol/colSampleRatio)+1;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentSumDataPerRow(Col): These functions perform the conversion of \r\n- * dataPerRow and dataPerCol from detail to summary.  This is done so that the  \r\n- * proper view pane can be calculated on the summary heatmap when drawing the \r\n- * leftCanvasBox on that side of the screen.\r\n- **********************************************************************************/\r\n-function getCurrentSumDataPerRow() {\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(getLevelFromMode(MatrixManager.SUMMARY_LEVEL));\r\n-\t// Summary data per row for all modes except Ribbon Horizontal using the sample ration for that level\r\n-\tvar\tsumDataPerRow = Math.floor(dataPerRow/rowSampleRatio);\r\n-\t// For Ribbon Horizontal, we convert to summary level THEN apply the ribbon horizontal sample ratio\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rate = heatMap.getColSampleRatio(getLevelFromMode(MatrixManager.RIBBON_HOR_LEVEL));\r\n-\t\tsumDataPerRow = (Math.floor(dataPerRow/summarySampleRatio)*rate);\r\n-\t} \r\n-\treturn sumDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumDataPerCol() {\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(getLevelFromMode(MatrixManager.SUMMARY_LEVEL));\r\n-\tvar\tsumDataPerCol = Math.floor(dataPerCol/colSampleRatio);\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rate = heatMap.getRowSampleRatio(getLevelFromMode(MatrixManager.RIBBON_VERT_LEVEL));\r\n-\t\tsumDataPerCol = (Math.floor(dataPerCol/summarySampleRatio)*rate);\r\n-\t} \r\n-\treturn sumDataPerCol;\r\n-}\r\n-\r\n-\r\n-\r\n-\r\n-\r\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/SummaryHeatMapDisplay.js
--- a/MDAheatmap/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,995 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var dendroPaddingHeight = 1;\r\n-var rowDendroHeight = 102; // this is the height of the row dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var columnDendroHeight = 102; // this is the height of the col dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var normDendroMatrixHeight = 500; // this is the height of the dendro matrices created in buildDendroMatrix\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-var summarySampleRatio;\r\n-\r\n-var rowDendroBars;\r\n-var colDendroBars;\r\n-var colDendroMatrix;\r\n-var rowDendroMatrix;\r\n-var chosenBar = {axis: null, index: null};\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcanvas.onmousemove = handleMove;\r\n-\t// set the position to (1,1) so that the detail pane loads at the top left corner of the summary.\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {\r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tclassBars = heatMap.getClassifications();\r\n-\t\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\t\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\t\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummarySampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Row\'); // create array with the bars\r\n-\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\'); // create array with the bars\r\n-\t\t\r\n-\t\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\t\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\t\trowEmptySpace = summaryMatrixWidth/2 - summaryMatrixHeight;\r\n-\t\telse if (summaryMatrixHeight > summaryMatrixWidth && summaryMatrixHeight/summaryMatrixWidth > 2)\r\n-\t\t\tcolEmptySpace = summaryMatrixHeight/2 - summaryMatrixWidth;\r\n-\t\t\r\n-\t\tcalcTotalSize();\r\n-\r\n-\t\tcanvas.width =  summaryTotalWidth;\r\n-\t\tcanvas.height = summaryTotalHeight;\r\n-\t\tsetupGl();\r\n-\t\tinitGl();\r\n-\t\tbuildSummaryTexture();\r\n-\t\tleftCanvasBoxVertThick = (1+Math.floor(summaryMatrixWidth/250))/1000;\r\n-\t\tleftCanvasBoxHorThick = (1+Math.floor(summaryMatrixHeight/250))/1000;\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//'..b'dendroMatrix[0].length){\r\n-\t\tif (dendroMatrix[i][j+1] == 1 ||dendroMatrix[i][j+1] == 2){\r\n-\t\t\tj++;\r\n-\t\t\tdendroMatrix[i][j] = 2;\r\n-\t\t} else {//if (dendroMatrix[i-1][j] == 1 ||dendroMatrix[i-1][j] == 2){\r\n-\t\t\ti--;\r\n-\t\t\tdendroMatrix[i][j] = 2;\r\n-\t\t}\r\n-\t}\r\n-\treturn j;\r\n-}\r\n-\r\n-function highlightAllBranchesInRange(height,leftExtreme,rightExtreme,dendroMatrix){\r\n-\tfor (var i = height; i >= 0; i--){\r\n-\t\tfor (var loc in dendroMatrix[i]){\r\n-\t\t\tif (leftExtreme < loc && loc < rightExtreme){\r\n-\t\t\t\tdendroMatrix[i][loc] = 2;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function clearDendroSelection(){\r\n-\tchosenBar = {axis: null, index: null};\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\');\r\n-\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),"Row");\r\n-\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\tdrawRowDendrogram(TexPixels);\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\r\n-\r\n-\r\n-//***************************//\r\n-//Selection Label Functions *//\r\n-//***************************//\r\n-function summaryResize() {\r\n-\tclearSelectionMarks();\r\n-\tdrawRowSelectionMarks();\r\n-\tdrawColSelectionMarks();\r\n-}\r\n-\r\n-\r\n-function drawRowSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalHeight - summaryMatrixHeight;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedRows = getSearchRows();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedRows.length; i++) {\r\n-\t\tvar xPos = canvas.clientWidth + 3;\r\n-\t\tvar position = headerSize + (selectedRows[i]/heatMap.getRowSampleRatio(MatrixManager.DETAIL_LEVEL));\r\n-\t\tvar yPos = ((position * canvas.clientHeight) / summaryTotalHeight) - fontSize;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'F\');\r\n-\t}\r\n-}\r\n-\r\n-function drawColSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalWidth - summaryMatrixWidth;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedCols = getSearchCols();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedCols.length; i++) {\r\n-\t\tvar position = headerSize + (selectedCols[i]/heatMap.getColSampleRatio(MatrixManager.DETAIL_LEVEL));\r\n-\t\tvar xPos = ((position * canvas.clientWidth) / summaryTotalWidth) + fontSize/2;\r\n-\t\tvar yPos = canvas.clientHeight + 4;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'T\');\r\n-\t}\r\n-}\r\n-\r\n-function clearSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar oldMarks = document.getElementsByClassName("MarkLabel");\r\n-\twhile (oldMarks.length > 0) {\r\n-\t\tmarkElement.removeChild(oldMarks[0]);\r\n-\t}\r\n-\r\n-}\r\n-\r\n-\r\n-function dividerStart(){\r\n-\tuserHelpClose();\r\n-\tdocument.addEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.addEventListener(\'touchmove\', dividerMove);\r\n-\tdocument.addEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.addEventListener(\'touchend\',dividerEnd);\r\n-}\r\n-function dividerMove(e){\r\n-\tvar divider = document.getElementById(\'divider\');\r\n-\tif (e.touches){\r\n-    \tif (e.touches.length > 1){\r\n-    \t\treturn false;\r\n-    \t}\r\n-    }\r\n-\tvar Xmove = e.touches ? divider.offsetLeft - e.touches[0].pageX : divider.offsetLeft - e.pageX;\r\n-\tvar summary = document.getElementById(\'summary_chm\');\r\n-\tvar summaryX = summary.offsetWidth - Xmove;\r\n-\tsummary.setAttribute("style","position: relative; width:" + summaryX + "px");\r\n-\tvar detail = document.getElementById(\'detail_chm\');\r\n-\tvar detailX = detail.offsetWidth + Xmove;\r\n-\tdetail.setAttribute("style","position: relative; width:" + detailX + "px");\r\n-\tclearLabels();\r\n-\tclearSelectionMarks();\r\n-}\r\n-function dividerEnd(){\r\n-\tdocument.removeEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.removeEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.removeEventListener(\'touchmove\',dividerMove);\r\n-\tdocument.removeEventListener(\'touchend\',dividerEnd);\r\n-\tdetailResize();\r\n-\tsummaryResize();\r\n-}\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/lib/deflate.js
--- a/MDAheatmap/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/lib/inflate.js
--- a/MDAheatmap/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/lib/z-worker.js
--- a/MDAheatmap/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/lib/zip.js
--- a/MDAheatmap/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/javascript/temp.js
--- a/MDAheatmap/javascript/temp.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,49 +0,0 @@
-/**
- * 
- */
-
-function buildSomething () {
- var numRows = 10;
- var numCols = 10;
- var myMatrix = create2DArray(numRows, numCols);
-
- //Note 0 based - may need to modify for row - column ordering starting at 1
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Move data into a linear (texture) array - could change to colors at the same time
- var texture = new Array(numRows*numCols);
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- texture[row*numCols+col] = myMatrix[row][col];
- }
- }
-
- //For a sideways dendor - row dendro still do the 2D array normal way
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Then pull out one column at a time to put on the front of each texture row.
- var currentRow = 7;
- var textureRow = new Array(1000);
- pos = 700;
- for (var row = 0; row < numRows; row++) {
- textureRow[pos + col] = myMatrix[row][7];
- }
-}
-
-
-
-function create2DArray(rows, columns) {
- var matrix = new Array(rows);
- for (var i = 0; i < rows; i++) {
- matrix[i] = new Array(columns);
- }
- return matrix;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/css/NGCHM.css
--- a/MDAheatmap/oldstatic/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,107 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;  */
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    verticalAlign:top;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    verticalAlign:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/full.png
b
Binary file MDAheatmap/oldstatic/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/full_selected.png
b
Binary file MDAheatmap/oldstatic/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/join.png
b
Binary file MDAheatmap/oldstatic/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/mdandersonlogo260x85.png
b
Binary file MDAheatmap/oldstatic/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/ribbonH.png
b
Binary file MDAheatmap/oldstatic/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/ribbonH_selected.png
b
Binary file MDAheatmap/oldstatic/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/ribbonV.png
b
Binary file MDAheatmap/oldstatic/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/ribbonV_selected.png
b
Binary file MDAheatmap/oldstatic/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/split.png
b
Binary file MDAheatmap/oldstatic/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/zoom-in.png
b
Binary file MDAheatmap/oldstatic/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/images/zoom-out.png
b
Binary file MDAheatmap/oldstatic/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/.gitignore
--- a/MDAheatmap/oldstatic/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/ColorMapManager.js
--- a/MDAheatmap/oldstatic/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,181 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- continue;
- }
- }
- } else {
- color = this.getColor(value);
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
-}
-
-
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js
--- a/MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1165 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var userHelpOpen;\r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src="images/join.png";\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(20);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  detailDataViewWidth + calculateTotalClassBarHeight("row");\r\n-\t\tdetCanvas.height = detailDataViewHeight + calculateTotalClassBarHeight("column");\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = function(e){\r\n-\t\tdragOffsetX = e.pageX;\r\n-\t\tdragOffsetY = e.pageY;\r\n-\r\n-\t    mouseDown = true;\r\n-\t}\r\n-\tdocument.onmouseup = function(e){\r\n-\t\tmouseDown = false;\r\n-\t}\r\n-\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function handleDrag(e) {\r\n-\tclearTimeout(detailPoint);\r\n-    if(!mouseDown) return;\r\n-    var rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-    \r\n-    var xDrag = e.pageX - dragOffsetX;\r\n-    var yDrag = e.pageY - dragOffsetY;\r\n-    \r\n-    if ((Math.abs(xDrag/rowElementSize) > 1) || \r\n-    \t(Math.abs(yDrag/colElementSize) > 1)    ) {\r\n-    \tcurrentRow = Math.floor(currentRow - (yDrag/colElementSize));\r\n-    \tcurrentCol = Math.floor(currentCol - (xDrag/rowElementSize));\r\n-    \t\r\n-\t    dragOffsetX = e.pageX;\r\n-\t    dragOffsetY = e.pageY;\r\n-\t    var numRows = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);\r\n-\t    var numCols = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);\r\n-\t    checkRow();\r\n-\t    checkColumn();\r\n-\t \r\n-\t    updateSelection();\r\n-   }\r\n-    return false;\r\n-}\t\r\n-\r\n-function handleMove(e) {\r\n-\tif (mouseDown){\r\n-\t\thandleDrag(e);\r\n-\t} else{\r\n-\t\tuserHelpOpen(e);\r\n-\t}\r\n-}\r\n- \r\n-function getColClassPixelHeight() {\r\n-\tvar classbarHeight = calculateTotalClassBarHeight("column");\r\n-\treturn detCanvas.clientHeight*(classbarHeight/detCanvas.height);\r\n-}\r\n-\r\n-function getRowClassPixelWidth() {\r\n-\tvar classbarWidth = calculateTotalClassBarHeight("row");\r\n-\treturn detCanvas.clientWidth*(classbarWidth/detCanvas.width);\r\n-}\r\n-\r\n-function isOnObject(e,type) {\r\n-    var rowClassWidthPx =  getRowClassPixelWidth();\r\n-    var colClassHeightPx = getColClassPixelHeight();\r\n-    if (e.layerY > colClassHeightPx ) { \r\n-    \tif  ((type == "map") && e.layerX > rowClassWidthPx) {\r\n-    \t\treturn true;\r\n-    \t}\r\n-    \tif  ((type'..b'm vec2 u_box_right_bottom;\' +\r\n- \t\t \t\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row");\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column");\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/MatrixManager.js
--- a/MDAheatmap/oldstatic/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,443 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different 'zoom' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = 'tn';\r\n-MatrixManager.SUMMARY_LEVEL = 's';\r\n-MatrixManager.RIBBON_VERT_LEVEL = 'rv';\r\n-MatrixManager.RIBBON_HOR_LEVEL = 'rh';\r\n-MatrixManager.DETAIL_LEVEL = 'd';\r\n-\r\n-MatrixManager.WEB_SOURCE = 'W';\r\n-MatrixManager.FILE_SOURCE = 'F';\r\n-\r\n-MatrixManager.Event_INITIALIZED = 'Init';\r\n-MatrixManager.Event_NEWDATA = 'NewData';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don't do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdatalayers[level].setReadWindow(row, column, numRows, numColumns);\r\n-    } \t\r\n-\r\n-\t// Retrieve color map Manager for this heat map.\r\n-\tthis.getColorMapManager = function() {\r\n-\t\tif (initialized != 1)\r\n-\t\t\treturn null;\r\n-\t\t\r\n-\t\tif (colorMapMgr == null ) {\r\n-\t\t\tcolorMapMgr = new ColorMapManager(colorMaps);\r\n-\t\t}\r\n-\t\treturn colorMapMgr;\r\n-\t}\r\n-\t\r\n-\t//Retrieve classifications\r\n-\tthis.getClassifications = function() {\r\n-\t\treturn classifications;\r\n-\t}\r\n-\t\r\n-\t//Get Row Labels\r\n-\tthis.getRowLabels = function() {\r\n-\t\treturn rowLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tthis.getColLabels = function() {\r\n-\t\treturn colLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tthis.getDendrogram = function() {\r\n-\t\treturn dendrogram;\r\n-\t}\r\n-\t\r\n-\t//Method used to register another callback function for a user that wants to be notifed\r\n-\t//of updates to the status of heat map data.\r\n-\tthis.addEventListener = function(callback) {"..b'(MatrixManager.Event_NEWDATA, level);\r\n-\t\t\t     }\r\n-\t\t\t    \t  \r\n-\t\t\t     fr.readAsArrayBuffer(blob);\t\t\r\n-\t\t\t}, function(current, total) {\r\n-\t\t\t\t// onprogress callback\r\n-\t\t\t});\t\t\r\n-\t\t}\r\n-\t};\r\n-\t\r\n-\t//Helper function to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\t\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\t\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar endRowTile = startRowTile + Math.floor((numRows-1)/rowsPerTile);\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endColTile = startColTile + Math.floor((numColumns-1)/colsPerTile);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/NGCHM_Util.js
--- a/MDAheatmap/oldstatic/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,8 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/SelectionManager.js
--- a/MDAheatmap/oldstatic/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,217 +0,0 @@
-/**
- * This code is responsible for handling changes in position of selected heat map region.
- * It handles mouse, keyboard, and button events that change the position of the selected
- * region.  It also tracks whether the display is in a single window or split into two
- * separate windows.  If in separate windows, local storage events are used to communicate
- * changes between the two windows.  
- */
-
-//Globals that provide information about heat map position selection.
-
-mode = null;          // Set to normal or ribbon verticle or ribbon horizontal
-currentRow=null;      // Top row of current selected position
-currentCol=null;      // Left column of the current selected position
-dataPerRow=null;      // How many rows are included in the current selection
-dataPerCol=null;      // How many columns in the current selection
-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.
-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.
-
-                      //isSub will be set to true if windows are split and this is the child.
-isSub = getURLParameter('sub') == 'true';  
-hasSub = false;       //hasSub set to true if windows are split and this is the parent.
-
-
-/* This routine is called when the selected row / column is changed.
- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,
- * and dataPerCol as desired. This method does redrawing and notification as necessary.  
- */
-function updateSelection() {
-
- if (!isSub) {
- //We have the summary heat map so redraw the yellow selection box.
- drawLeftCanvasBox();
- } 
- if (!hasSub) {
- //We have the detail heat map so redraw based on selection. 
- drawDetailHeatMap();
- } 
-
- if (isSub || hasSub) {
- //summary and detail as split into two browsers.  Communciate the selection change
- //to the other browser.
- localStorage.removeItem('event');
- localStorage.setItem('currentRow', '' + currentRow);
- localStorage.setItem('currentCol', '' + currentCol);
- localStorage.setItem('dataPerRow', '' + dataPerRow);
- localStorage.setItem('dataPerCol', '' + dataPerCol);
- localStorage.setItem('selectedStart', '' + selectedStart);
- localStorage.setItem('selectedStop', '' + selectedStop);
- localStorage.setItem('mode', mode);
- localStorage.setItem('event', 'changePosition');
- }
-}
-
-function changeMode(newMode) {
-
- if (!hasSub) {
- if (newMode == 'RIBBONH')
- detailHRibbon();
- if (newMode == 'RIBBONV')
- detailVRibbon();
- if (newMode == 'NORMAL')
- detailNormal();
- } else {
- localStorage.removeItem('event');
- localStorage.setItem('selectedStart', '' + selectedStart);
- localStorage.setItem('selectedStop', '' + selectedStop);
- localStorage.setItem('mode', newMode);
- localStorage.setItem('event', 'changeMode');
- }
-}
-
-/* Handle mouse scroll wheel events to zoom in / out.
- */
-function handleScroll(evt) {
- evt.preventDefault();
- if (evt.wheelDelta < 0 || evt.deltaY > 0) { //Zoom out
- if (!hasSub)
- detailDataZoomOut();
- else {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'zoomOut' )
- }
- } else { // Zoom in
- if (!hasSub)
- detailDataZoomIn();
- else {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'zoomIn' )
- }
- }
- return false;
-} 
-
-
-function keyNavigate(e){
- userHelpClose();
-    clearTimeout(detailPoint);
- e.preventDefault();
- switch(e.keyCode){
- case 37: // left key
- if (e.shiftKey){
- currentCol -= dataPerRow;
- } else {
- currentCol--;
- }
- break;
- case 38: // up key
- if (e.shiftKey){
- currentRow -= dataPerCol;
- } else {
- currentRow--;
- }
- break;
- case 39: // right key
- if (e.shiftKey){
- currentCol += dataPerRow;
- } else {
- currentCol++;
- }
- break;
- case 40: // down key
- if (e.shiftKey){
- currentRow += dataPerCol;
- } else {
- currentRow++;
- }
- break;
- default:
- break;
- }
-
- checkRow();
- checkColumn();
-    
-    updateSelection();
-}
-
-/* Local storage is used to communicate between two browser windows when the display is split. Set
- * up an event to be notified when contents of local storage are modified.
- */ 
-function setupLocalStorage () {
- window.addEventListener('storage', function (evt) {
- console.log('localstorage event ' + evt.key);
- if (evt.key == 'event') {
- handleLocalStorageEvent(evt);
- } 
- }, false);
-}
-
-//When the detail pane is in a separate window, local storage is used to send it updates from 
-//clicks in the summary view.
-function handleLocalStorageEvent(evt) {
- var type = localStorage.getItem('event');
- console.log('type ' + type);
- if (type == 'changePosition') {
- currentRow = Number(localStorage.getItem('currentRow'));
- currentCol = Number(localStorage.getItem('currentCol'));
- dataPerRow = Number(localStorage.getItem('dataPerRow'));
- dataPerCol = Number(localStorage.getItem('dataPerCol'));
- selectedStart = Number(localStorage.getItem('selectedStart'));
- selectedStop = Number(localStorage.getItem('selectedStop'));
- mode = localStorage.getItem('mode');
- if (hasSub) {
- // Redraw the yellow selection box.
- drawLeftCanvasBox ();
- } 
- if (isSub) {
- // Redraw detail view based on selection. 
- drawDetailHeatMap();
- } 
- } else if ((type == 'zoomIn') && (isSub)) {
- detailDataZoomIn();
- } else if ((type == 'zoomOut') && (isSub)) {
- detailDataZoomOut();
- } else if ((type == 'changeMode') && (isSub)) {
- var newMode = localStorage.getItem('mode');
- selectedStart = Number(localStorage.getItem('selectedStart'));
- selectedStop = Number(localStorage.getItem('selectedStop'));
- if (newMode == 'RIBBONH')
- detailHRibbon();
- if (newMode == 'RIBBONV')
- detailVRibbon();
- if (newMode == 'NORMAL')
- detailNormal();
- } else if ((type == 'join') && hasSub) {
- hasSub=false;
- detailJoin();
- }
-}
-
-//Called when a separate detail map window is joined back into the main chm browser window.
-function rejoinNotice() {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'join');
-}
-
-
-//Makes sure the currentRow setting is valid and adjusts if it is not.
-function checkRow() {
- var numRows = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);
- if ((currentRow < 1) || ((mode == 'RIBBONV') && (selectedStart==0))) currentRow = 1;
- if ((mode == 'RIBBONV') && (selectedStart != 0)) currentRow = selectedStart;
-    if (currentRow > ((numRows + 1) - dataPerCol)) currentRow = (numRows + 1) - dataPerCol;
-}
-
-function checkColumn() {
-    var numCols = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);
-    if ((currentCol < 1) || ((mode == 'RIBBONH') && selectedStart==0)) currentCol = 1;
-    if ((mode == 'RIBBONH') && selectedStart!= 0) currentCol = selectedStart;
-    if (currentCol > ((numCols + 1) - dataPerRow)) currentCol = (numCols + 1) - dataPerRow;
-}
-
-
-
-
-
-
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js
--- a/MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,891 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var rowDendroHeight = 105;\r\n-var columnDendroHeight = 105;\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-\r\n-var colDendroBars;\r\n-var rowDendroBars;\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {\r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tclassBars = heatMap.getClassifications();\r\n-\t\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\t\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\t\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\t\r\n-\t\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\t\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\t\trowEmptySpace = summaryMatrixWidth/2 - summaryMatrixHeight;\r\n-\t\telse if (summaryMatrixHeight > summaryMatrixWidth && summaryMatrixHeight/summaryMatrixWidth > 2)\r\n-\t\t\tcolEmptySpace = summaryMatrixHeight/2 - summaryMatrixWidth;\r\n-\t\t\r\n-\t\tcalcTotalSize();\r\n-\r\n-\t\tcanvas.width =  summaryTotalWidth;\r\n-\t\tcanvas.height = summaryTotalHeight;\r\n-\t\tsetupGl();\r\n-\t\tinitGl();\r\n-\t\tbuildSummaryTexture();\r\n-\t\tleftCanvasBoxVertThick = (1+Math.floor(summaryMatrixWidth/250))/1000;\r\n-\t\tleftCanvasBoxHorThick = (2+Math.floor(summaryMatrixHeight/250))/1000;\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//Summary tile - wait a bit to see if we get another tile quickly, then draw\r\n-\t\tif (eventTimer != 0) {\r\n-\t\t\t//New tile arrived - reset timer\r\n-\t\t\tclearTimeout(eventTimer);\r\n-\t\t}\r\n-\t\teventTimer = setTimeout(buildSummaryTexture, 200);\r\n-\t} \r\n-\t//Ignore updates to other tile types.\r\n-}\r\n-\r\n-//Set the variables for the total size of the summary heat map - used to set canvas, WebGL texture, and viewport size.\r\n-function calcTotalSize() {\r\n-\tsummaryTotalHeight = summaryMatrixHeight + rowEmptySpace + summaryViewBorderWidth + colClassBarHeight + columnDendroHeight;\r\n-\tsummaryTotalWidth = summaryMatrixWidth + colEmptySpace + summaryViewBorderWidth + rowClassBarWidth + rowDendroHeight;\r\n-}\r\n-\r\n-function buildSummaryTexture() {\r\n-\teventTimer = 0;\r\n-\tvar colorMap = heatMap.getColorMapMan'..b'roBoxLeftTopArray = new Float32Array([leftMin, 1-rightExtreme/canvas.height-topMin]);\r\n-\tdendroBoxRightBottomArray = new Float32Array([1-matrixRight, 1-leftExtreme/canvas.height-topMin]);\r\n-\r\n-\tselectedStart = leftExtreme;\r\n-\tselectedStop = rightExtreme;\r\n-}\r\n-\r\n-function highlightColumnDendrogram(dataBuffer, selectedNode){\r\n-\tvar interval = heatMap.getDendrogram()["interval"];\r\n-\tvar highlightedBars = [];\r\n-\tvar mapAndClassBarHeight = summaryTotalHeight - columnDendroHeight;\r\n-\tvar startPos = summaryTotalWidth*(mapAndClassBarHeight+1)*BYTE_PER_RGBA + (rowClassBarWidth+rowDendroHeight+summaryViewBorderWidth/2)*BYTE_PER_RGBA; // bottom left corner of the dendro space\r\n-\tvar leftExtreme = getTranslatedLocation(colDendroBars[selectedNode].left);\r\n-\tvar rightExtreme = getTranslatedLocation(colDendroBars[selectedNode].right);\r\n-\tfor (var i = selectedNode; i > 0; i--){ // DRAW THE HORIZONTAL BARS FIRST\t\r\n-\t\tvar bar = colDendroBars[i];\r\n-\t\tvar leftLoc = getTranslatedLocation(bar.left/interval);\r\n-\t\tvar rightLoc = getTranslatedLocation(bar.right/interval);\r\n-\t\tvar height = bar.height;\r\n-\t\tif (rightLoc < leftExtreme || leftLoc > rightExtreme){ // if this bar isn\'t located within the extreme bounds, skip it\r\n-\t\t\tcontinue;\r\n-\t\t} else if (rightLoc > leftExtreme && leftLoc < leftExtreme ){ // if this bar starts in the extreme bounds, but goes beyond the current extreme, update the extreme value\r\n-\t\t\tleftExtreme = leftLoc;\r\n-\t\t} else if (leftLoc < rightExtreme && rightLoc > rightExtreme){\r\n-\t\t\trightExtreme = rightLoc;\r\n-\t\t}\r\n-\t\thighlightedBars.push(bar);\r\n-\t\tvar barLength = (rightLoc-leftLoc);\r\n-\t\tvar pos = startPos;\r\n-\t\tpos += leftLoc*BYTE_PER_RGBA;\t// get in the proper left location\r\n-\t\tpos += height*summaryTotalWidth*BYTE_PER_RGBA; // go to the proper height\r\n-\t\tfor (var j = 0; j < barLength; j++){ // draw line going across\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos += BYTE_PER_RGBA;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\tfor (var i = 0; i < highlightedBars.length; i++){// DRAW THE LINES GOING DOWN\r\n-\t\tvar bar = highlightedBars[i];\r\n-\t\tvar pos =  startPos;\r\n-\t\tvar leftLoc = getTranslatedLocation(bar.left/interval);\r\n-\t\tvar rightLoc = getTranslatedLocation(bar.right/interval);\r\n-\t\tvar height = bar.height;\r\n-\t\tpos += leftLoc*BYTE_PER_RGBA; // draw the left side lines\r\n-\t\tpos += (height-1)*summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\twhile (pos > startPos && dataBuffer[pos] == 3){\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos -= summaryTotalWidth*BYTE_PER_RGBA; // jump down to the next row until it hits a horizontal line\r\n-\t\t}\r\n-\t\tpos = startPos; // draw the right side lines\r\n-\t\tpos += rightLoc*BYTE_PER_RGBA;\r\n-\t\tpos += height*summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\twhile (pos > startPos && dataBuffer[pos] == 3){\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos -= summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\tvar matrixBottom = rowEmptySpace / canvas.height + leftCanvasBoxHorThick;\r\n-\tvar matrixRight = colEmptySpace / canvas.width + leftCanvasBoxVertThick;\r\n-\tvar leftMin = leftCanvasBoxVertThick + ((rowClassBarWidth+rowDendroHeight)/canvas.width);\r\n-\tvar topMin = leftCanvasBoxHorThick + ((colClassBarHeight+columnDendroHeight)/canvas.height);\r\n-\r\n-\tdendroBoxLeftTopArray = new Float32Array([leftExtreme/canvas.width+leftMin, 0]); \r\n-\tdendroBoxRightBottomArray = new Float32Array([rightExtreme/canvas.width+leftMin, 1-topMin]);\r\n-\t\r\n-\tselectedStart = leftExtreme;\r\n-\tselectedStop = rightExtreme;\r\n-}\r\n-\r\n-\r\n-function clearDendroSelection(){\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\tdrawRowDendrogram(TexPixels);\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/lib/deflate.js
--- a/MDAheatmap/oldstatic/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/lib/inflate.js
--- a/MDAheatmap/oldstatic/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/lib/z-worker.js
--- a/MDAheatmap/oldstatic/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/lib/zip.js
--- a/MDAheatmap/oldstatic/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/oldstatic/javascript/temp.js
--- a/MDAheatmap/oldstatic/javascript/temp.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,49 +0,0 @@
-/**
- * 
- */
-
-function buildSomething () {
- var numRows = 10;
- var numCols = 10;
- var myMatrix = create2DArray(numRows, numCols);
-
- //Note 0 based - may need to modify for row - column ordering starting at 1
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Move data into a linear (texture) array - could change to colors at the same time
- var texture = new Array(numRows*numCols);
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- texture[row*numCols+col] = myMatrix[row][col];
- }
- }
-
- //For a sideways dendor - row dendro still do the 2D array normal way
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Then pull out one column at a time to put on the front of each texture row.
- var currentRow = 7;
- var textureRow = new Array(1000);
- pos = 700;
- for (var row = 0; row < numRows; row++) {
- textureRow[pos + col] = myMatrix[row][7];
- }
-}
-
-
-
-function create2DArray(rows, columns) {
- var matrix = new Array(rows);
- for (var i = 0; i < rows; i++) {
- matrix[i] = new Array(columns);
- }
- return matrix;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/css/NGCHM.css
--- a/MDAheatmap/static/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,291 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-
-#divider{
- height: 82%;
- width: 5px;
- vertical-align:top;
- display:inline-block;
- background: #666666;
- cursor: ew-resize;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    margin-left: 3px;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:98%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#detail_buttons {
- margin-top: 10px;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-#helpprefs {
-    margin: 5px !important;
-    padding: 8px 8px 8px 8px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    z-index: 10000;
-    text-align: center;
-    height: auto;
-    width: auto;
-    box-shadow: 5px 5px 5px #777777;
-    white-space: nowrap;
-}
-
-#prefprefs {
- position: relative;
-    display: inline-block;
-}
-
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
-
-table {
-    width: 100%;
-}
-
-td {
-    height: 0px;
- padding: 0px;
-    font-size: 80% !important;
-    font-family: Arial;
-    font-weight: normal;
-    color: #0843c1;
-    vertical-align: center;
-}
-
-.searchItem{
- background-color: yellow;
-}
-
-#searchError{
- border: 1px solid #1a1a1a;
-    border-radius: 10px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: red;
-    position: absolute;
-    width: 180px;
-    z-index:10;
-    /* height: 50px; */
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.labelMenu{
-    border: 1px solid #1a1a1a;
-    border-radius: 10px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    width: 240px;
-    height: 150px;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-    position:relative;
-}
-
-.labelMenuCaption{
- padding: .4em 1em;
- background: #0843c1;
- color: #ffffff;
- font-size: 90% !important;
-    font-family: Arial;
-    font-weight: bold;
-    text-align: left;
- border-top-left-radius: 10px;
-    border-top-right-radius: 10px;
-}
-
-.labelMenuClose{
- position: absolute;
- right: 2px;
- bottom:2px;
-}
-
-.labelMenuHeader tr{
- padding: 4em 1em;
- position:relative;
- margin: 0px 0px 0px 0px;
- background: #f8f3f1; 
- color: #0843c1;
- text-align: left;
- font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
- border-radius: 10px;
-}
-
-.labelMenuBody tr{
- height: 20px;
-}
-.labelMenuBody td{
- height:20px;
- position: absolute;
- font-size: 80% !important;
-    font-family: Arial;
-    font-weight: normal;
-    color: #0843c1;
-    cursor: pointer;
-}
-
-.labelMenuBody td:hover{
- font-weight: bold;
-}
-
-table.breakpointContainer {
-    border: none;
-    border-spacing: 0px;
-    border-collapse: collapse;
-}
-
-td.breakpointContainer
-th.breakpointContainer {
-    text-align: center;
-    margin: 0px;
-    padding: 0px 5px 0px 0px;
-    border-spacing: 0px;
-    border-collapse: collapse;    
-}
-
-#prefsPanel, #pdfPrefsPanel {
-    margin: 5px !important;
-    padding: 2px 2px 2px 2px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    z-index: 10000;
-    text-align: center;
-    height: auto;
-    width: auto;
-    box-shadow: 5px 5px 5px #777777;
-    white-space: nowrap;
-}
-#prefsHeader, #pdfPrefsHeader{
-    display: table;
-    font-size: 18px;
-    font-weight: bold;
-    color: #0843c1;
-    margin: auto;
-    width: 100%;
-    height: 30px;
-    line-height: 30px;
-    text-align: center;
-    border-top-left-radius: 15px;
-    border-top-right-radius: 15px;
-    background: #CBD1EA;
-}
-
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/addButton.png
b
Binary file MDAheatmap/static/images/addButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/breakButtonOff.png
b
Binary file MDAheatmap/static/images/breakButtonOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/breakButtonOn.png
b
Binary file MDAheatmap/static/images/breakButtonOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/cancel.png
b
Binary file MDAheatmap/static/images/cancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/classButtonOff.png
b
Binary file MDAheatmap/static/images/classButtonOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/classButtonOn.png
b
Binary file MDAheatmap/static/images/classButtonOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/closeButton.png
b
Binary file MDAheatmap/static/images/closeButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/covariateBarsOff.png
b
Binary file MDAheatmap/static/images/covariateBarsOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/covariateBarsOn.png
b
Binary file MDAheatmap/static/images/covariateBarsOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/createPdf.png
b
Binary file MDAheatmap/static/images/createPdf.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/dataLayersOff.png
b
Binary file MDAheatmap/static/images/dataLayersOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/dataLayersOn.png
b
Binary file MDAheatmap/static/images/dataLayersOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/filterClassButton.png
b
Binary file MDAheatmap/static/images/filterClassButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/full.png
b
Binary file MDAheatmap/static/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/full_selected.png
b
Binary file MDAheatmap/static/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/gear.png
b
Binary file MDAheatmap/static/images/gear.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/gearDis.png
b
Binary file MDAheatmap/static/images/gearDis.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/gear_big.png
b
Binary file MDAheatmap/static/images/gear_big.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/go.png
b
Binary file MDAheatmap/static/images/go.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/join.png
b
Binary file MDAheatmap/static/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/mdandersonlogo260x85.png
b
Binary file MDAheatmap/static/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/minusButton.png
b
Binary file MDAheatmap/static/images/minusButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/next.png
b
Binary file MDAheatmap/static/images/next.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/pdf.png
b
Binary file MDAheatmap/static/images/pdf.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/plusButton.png
b
Binary file MDAheatmap/static/images/plusButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/prefApply.png
b
Binary file MDAheatmap/static/images/prefApply.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/prefBack.png
b
Binary file MDAheatmap/static/images/prefBack.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/prefCancel.png
b
Binary file MDAheatmap/static/images/prefCancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/prefSave.png
b
Binary file MDAheatmap/static/images/prefSave.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/prev.png
b
Binary file MDAheatmap/static/images/prev.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/removeFilterClassButton.png
b
Binary file MDAheatmap/static/images/removeFilterClassButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/ribbonH.png
b
Binary file MDAheatmap/static/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/ribbonH_selected.png
b
Binary file MDAheatmap/static/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/ribbonV.png
b
Binary file MDAheatmap/static/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/ribbonV_selected.png
b
Binary file MDAheatmap/static/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/rowsColsOff.png
b
Binary file MDAheatmap/static/images/rowsColsOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/rowsColsOn.png
b
Binary file MDAheatmap/static/images/rowsColsOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/save.png
b
Binary file MDAheatmap/static/images/save.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/searchButton.png
b
Binary file MDAheatmap/static/images/searchButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/split.png
b
Binary file MDAheatmap/static/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/zoom-in.png
b
Binary file MDAheatmap/static/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/images/zoom-out.png
b
Binary file MDAheatmap/static/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/.gitignore
--- a/MDAheatmap/static/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/ColorMapManager.js
--- a/MDAheatmap/static/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,246 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- this.setThresholds = function(newthresholds){
- thresholds = newthresholds;
- }
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeys: This function calculates and returns an
-  * array containing 10 continuous threshold breakpoint keys from the original thresholds 
-  * submitted.  It is used only for rendering a continuous classification bar help.  
-  **********************************************************************************/
- this.getContinuousThresholdKeys = function(){
-     var conThresh = new Array();
-     var bottomThresh = thresholds[0];
-     var threshSize = this.getContinuousThresholdKeySize();
-     //Add first threshold from original threshold list
-     conThresh.push(bottomThresh);
-     //Calculate and create "interim" 8 thresholds
-     for (var i = 1; i <= 8; i++){
-      conThresh.push(bottomThresh+Math.floor(threshSize*i));
-     }
-     //Add last threshold from original threshold list
-     conThresh.push(thresholds[thresholds.length - 1]);  
-     return conThresh;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeySize: This function calculates the size 
-  * separating each "interim" threshold key for a continuous classification bar.  
-  **********************************************************************************/
- this.getContinuousThresholdKeySize = function(){
-     var bottomThresh = thresholds[0];
-     var topThresh = thresholds[thresholds.length - 1]; 
-     return (topThresh - bottomThresh) / 8;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.setColors = function(newcolors){
- colors = newcolors;
- }
- this.getType = function(){
- return type;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
- this.setMissingColor = function(color){
- missingColor = color;
- }
-
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- return color;
- }
- }
- return rgbaMissingColor;
- } else {
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else{
- color = this.getColor(value);
- }
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
- this.getRgbToHex = function(rgb) {
- var a = rgb.a
- var r = rgb.r
- var g = rgb.g
- var b = rgb.b
-     return ('#' + componentToHex(r) + componentToHex(g) + componentToHex(b));
- }
-
- function componentToHex(c) {
-     var hex = c.toString(16);
-     return hex.length == 1 ? "0" + hex : hex;
- }
-
-}
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
- this.setColorMap = function(colorMapName, colorMap){
- colorMapCollection[colorMapName].colors = colorMap.getColors();
- colorMapCollection[colorMapName].thresholds = colorMap.getThresholds();
- colorMapCollection[colorMapName].missing = colorMap.getMissingColor();
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/DetailHeatMapDisplay.js
--- a/MDAheatmap/static/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1616 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-\r\n-var detailDendroHeight = 105;\r\n-var detailDendroWidth = 105;\r\n-var normDetailDendroMatrixHeight = 200;\r\n-var rowDetailDendroMatrix,colDetailDendroMatrix;\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-var currentSearchItem;\r\n-var labelLastClicked;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'divider\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src= staticPath + "images/join.png";\r\n- \t\tdocument.getElementById(\'gear_btn\').src= staticPath + "images/gearDis.png";\r\n- \t\tdocument.getElementById(\'pdf_btn\').style.display = \'none\';\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(10);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  (detailDataViewWidth + calculateTotalClassBarHeight("row") + detailDendroWidth);\r\n-\t\tdetCanvas.height = (detailDataViewHeight + calculateTotalClassBarHeight("column") + detailDendroHeight);\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tcreateLabelMenus();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = clickStart;\r\n-\tdocument.onmouseup = clickEnd;\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.addEventListener("touchmove", function(e){\r\n-\t\te.preventDefault();\r\n-\t\tif (e.touches){\r\n-\t    \tif (e.touches.length > 1){\r\n-\t    \t\treturn false;\r\n-\t    \t}\r\n-\t    }\r\n-\t})\r\n-\tdetCanvas.addEventListener("touchstart", function(e){\r\n-\t\tuserHelpClose();\r\n-\t\tclickStart(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchmove", function(e){\r\n-\t\te.stopPropagation();\r\n-\t\te.preventDefault();\r\n-\t\thandleMove(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchend", function(e){clickEnd(e)}, false);\r\n-\t\r\n-\tdetCanvas.addEventListener("gestureend",function(e){\r\n-\t\tif (e.scale > 1){\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\t} else if (e.scale < 1){\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\t}\r\n-\t},false)\r\n-\t\r\n-\t\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function clickStart(e){\r\n-\tuserHelpClose();\r\n-\tdragOffsetX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tdragOffsetY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\r\n-    mouseDown = true;\r\n-}\r\n-function clickEnd(e){\r\n-\tmouseDown = false;\r\n-\tvar dragEndX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tvar dragEndY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\tvar rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\tif (Math.abs(dragEndX - dragOffsetX) < colElementSize/10 && Math.abs(dra'..b'\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row")+detailDendroWidth;\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column")+detailDendroHeight;\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/MatrixManager.js
--- a/MDAheatmap/static/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,568 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different \'zoom\' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = \'tn\';\r\n-MatrixManager.SUMMARY_LEVEL = \'s\';\r\n-MatrixManager.RIBBON_VERT_LEVEL = \'rv\';\r\n-MatrixManager.RIBBON_HOR_LEVEL = \'rh\';\r\n-MatrixManager.DETAIL_LEVEL = \'d\';\r\n-\r\n-MatrixManager.WEB_SOURCE = \'W\';\r\n-MatrixManager.FILE_SOURCE = \'F\';\r\n-\r\n-MatrixManager.Event_INITIALIZED = \'Init\';\r\n-MatrixManager.Event_JSON = \'Json\';\r\n-MatrixManager.Event_NEWDATA = \'NewData\';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar chm = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.isSaveAllowed = function(){\r\n-\t\tif (mode === "F") {\r\n-\t\t\treturn false;\r\n-\t\t} else {\r\n-\t\t\treturn true;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Return the row summary ratio for a given level\r\n-\tthis.getRowSummaryRatio = function(level){\r\n-\t\treturn datalayers[level].rowSummaryRatio;\r\n-\t}\r\n-\t\r\n-\t//Return the column summary ratio for a given level\r\n-\tthis.getColSummaryRatio = function(level){\r\n-\t\treturn datalayers[level].colSummaryRatio;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\tthis.saveHeatMapProperties = function () {\r\n-\t\tvar success = saveMapProperties("colorMap",JSON.stringify(colorMaps));\r\n-\t\tif (success !== "false") {\r\n-\t\t\tsaveMapProperties("classifications",JSON.stringify(classifications));\r\n-\t\t} \r\n-\t\tif (success !== "false") {\r\n-\t\t\tsaveMapProperties("dendrogram",JSON.stringify(dendrogram));\r\n-\t\t} \r\n-\t\treturn success;\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don\'t do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdata'..b' to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\t\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\r\n-    this.rowSummaryRatio = jsonData.row_summary_ratio;\r\n-    this.colSummaryRatio = jsonData.col_summary_ratio;\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endRowCalc = (row+(numRows-1))/rowsPerTile;\r\n-    \tvar endColCalc = (column+(numColumns-1))/colsPerTile;\r\n-\t\tvar endRowTile = Math.floor(endRowCalc)+(endRowCalc%1 > 0 ? 1 : 0);\r\n-\t\tvar endColTile = Math.floor(endColCalc)+(endColCalc%1 > 0 ? 1 : 0);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/NGCHM_Util.js
--- a/MDAheatmap/static/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,34 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
-
-/**********************************************************************************
- * FUNCTION - toTitleCase: The purpose of this function is to change the case of
- * the first letter of the first word in each sentence passed in.
- **********************************************************************************/
-function toTitleCase(string)
-{
-    // \u00C0-\u00ff for a happy Latin-1
-    return string.toLowerCase().replace(/_/g, ' ').replace(/\b([a-z\u00C0-\u00ff])/g, function (_, initial) {
-        return initial.toUpperCase();
-    }).replace(/(\s(?:de|a|o|e|da|do|em|ou|[\u00C0-\u00ff]))\b/ig, function (_, match) {
-        return match.toLowerCase();
-    });
-}
-
-/**********************************************************************************
- * FUNCTION - getStyle: The purpose of this function is to return the style 
- * property requested for a given screen object.
- **********************************************************************************/
-function getStyle(x,styleProp){
-    if (x.currentStyle)
-        var y = x.currentStyle[styleProp];
-    else if (window.getComputedStyle)
-        var y = document.defaultView.getComputedStyle(x,null).getPropertyValue(styleProp);
-    return y;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/PdfGenerator.js
--- a/MDAheatmap/static/javascript/PdfGenerator.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,389 +0,0 @@\n-function openPdfPrefs(e){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\tvar prefspanel = document.getElementById(\'pdfPrefsPanel\');\r\n-\t//Add prefspanel table to the main preferences DIV and set position and display\r\n-\tprefspanel.style.top = e.offsetTop + 15;\r\n-\tprefspanel.style.display="inherit";\r\n-\tprefspanel.style.left = e.offsetLeft - prefspanel.clientWidth;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - getPDF: This function is called when the "create pdf" button is pressed.\r\n- * It will check the checkboxes/radio buttons to see how the PDF is to be created using\r\n- * the isChecked function. for a full list of jsPDF functions, visit here:\r\n- * https://mrrio.github.io/jsPDF/doc/symbols/jsPDF.html#setLineCap\r\n- **********************************************************************************/\r\n-function getPDF(){\r\n-\t// canvas elements need to be converted to DataUrl to be loaded into PDF\r\n-\tupdateSelection(); // redraw the canvases because otherwise they can show up blank\r\n-\tvar sumImgData = canvas.toDataURL(\'image/png\');\r\n-\tvar detImgData = detCanvas.toDataURL(\'image/png\');\r\n-\tvar mapsToShow = isChecked("pdfInputSummaryMap") ? "S" : isChecked("pdfInputDetailMap") ? "D" : "B";\r\n-\tvar doc = isChecked("pdfInputPortrait") ? new jsPDF("p","pt") :new jsPDF("l","pt"); // landscape or portrait?\r\n-\tvar pageHeight = doc.internal.pageSize.height;\r\n-\tvar pageWidth = doc.internal.pageSize.width;\r\n-\t\r\n-\tdoc.setFont("times");\r\n-//\tdoc.setFont("helvetica");\r\n-\t// convert longest label units to actual length (11 is the max font size of the labels)\r\n-\t// these will be the bottom and left padding space for the detail Heat Map\r\n-\tvar allLabels = document.getElementsByClassName("DynamicLabel");\r\n-\tvar longestRowLabelUnits = 10, longestColLabelUnits = 5;\r\n-\tfor (var i = 0; i < allLabels.length; i++){ // go through all the labels and find the one that takes the most space\r\n-\t\tvar label = allLabels[i];\r\n-\t\tif (label.getAttribute(\'axis\') == "Row"){\r\n-\t\t\tlongestRowLabelUnits = Math.max(doc.getStringUnitWidth(label.innerHTML),longestRowLabelUnits);\r\n-\t\t} else {\r\n-\t\t\tlongestColLabelUnits = Math.max(doc.getStringUnitWidth(label.innerHTML),longestColLabelUnits);\r\n-\t\t}\r\n-\t}\r\n-\tlongestColLabelUnits *= 11;\r\n-\tlongestRowLabelUnits *= 11;\r\n-\t\r\n-\t// header\r\n-\tvar headerCanvas = document.createElement(\'CANVAS\'); // load the MDAnderson logo into a canvas, since you can\'t load an img directly\r\n-\tvar headerCtx = headerCanvas.getContext(\'2d\'); \r\n-\tvar header = document.getElementsByClassName(\'mdaServiceHeaderLogo\')[0];\r\n-\theaderCanvas.height = 85; // logo png\'s actual dimensions\r\n-\theaderCanvas.width = 260;\r\n-\theaderCtx.drawImage(header.children[0], 0, 0);\r\n-\tvar headerData = headerCanvas.toDataURL(\'image/png\');\r\n-\tvar headerHeight = header.clientHeight + 5;\r\n-\tcreateHeader();\r\n-\t\r\n-\t// maps\r\n-\tvar paddingLeft = 5, paddingTop = headerHeight+10; // these are the variables that we will be using repeatedly to place items\r\n-\tvar sumImgW,sumImgH,detImgW,detImgH;\r\n-\tvar detImgL = paddingLeft;\r\n-\tif (mapsToShow == "S"){\r\n-\t\tsumImgW = pageWidth - 2*paddingLeft, sumImgH = pageHeight - paddingTop - 2*paddingLeft;\r\n-\t\tdoc.addImage(sumImgData, \'PNG\', paddingLeft, paddingTop, sumImgW,sumImgH);\r\n-\t} else if (mapsToShow == "D"){\r\n-\t\tdetImgW = pageWidth - 2*paddingLeft - longestRowLabelUnits, detImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\tdoc.addImage(detImgData, \'PNG\', paddingLeft, paddingTop, detImgW,detImgH);\r\n-\t} else {\r\n-\t\tif (!isChecked("pdfInputPages")){\r\n-\t\t\tsumImgW = (pageWidth - longestRowLabelUnits - 2*paddingLeft)/2, sumImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\t\tdetImgW = (pageWidth - longestRowLabelUnits - 2*paddingLeft)/2, detImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\t\tdetImgL = sumImgW + 2*paddingLeft;\r\n-\t\t\tdoc.addImage(sumImgData, \'PNG\', paddingLeft, paddingTop, sumImgW,sumImgH);\r\n-\t\t\tdoc.addImage(detImgData, \'PNG\', detImgL, paddingTop, detImg'..b'ds = colorMap.getThresholds();\r\n-\t\tvar barHeight = !condenseClassBars ? classBarFigureH/(thresholds.length+1) : 10;\r\n-\t\tvar counts = {}, maxCount = 0, maxLabelLength = doc.getStringUnitWidth("Missing Value")*classBarLegendTextSize;\r\n-\t\t// get the number N in each threshold\r\n-\t\tfor(var i = 0; i< classBar.values.length; i++) {\r\n-\t\t    var num = classBar.values[i];\r\n-\t\t    counts[num] = counts[num] ? counts[num]+1 : 1;\r\n-\t\t}\r\n-\t\tfor (var val in counts){\r\n-\t\t\tmaxCount = Math.max(maxCount, counts[val]);\r\n-\t\t\tmaxLabelLength = Math.max(maxLabelLength, doc.getStringUnitWidth(val.length)*classBarLegendTextSize);\r\n-\t\t}\r\n-\t\t\t\r\n-\t\tvar bartop = topOff+5;\r\n-\t\t//\xc2\xa0NOTE: missingCount will contain all elements that are not accounted for in the thresholds\r\n-\t\t// ie: thresholds = [type1, type2, type3], typeX will get included in the missingCount\r\n-\t\tvar missingCount = classBar.values.length;\r\n-\t\t// draw the bars\r\n-\t\tfor (var j = 0; j < thresholds.length; j++){ // make a gradient stop (and also a bucket for continuous)\r\n-\t\t\tvar rgb = colorMap.getClassificationColor(thresholds[j]);\r\n-\t\t\tdoc.setFillColor(rgb.r,rgb.g,rgb.b);\r\n-\t\t\tdoc.setDrawColor(0,0,0);\r\n-\t\t\tif (condenseClassBars){\r\n-\t\t\t\tvar barW = 10;\r\n-\t\t\t\tdoc.rect(leftOff, bartop, barW, barHeight, "FD");\r\n-\t\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\t\tdoc.text(leftOff +barW + 5, bartop + classBarLegendTextSize, thresholds[j].toString() + "   " + "n = " + counts[thresholds[j]] , null);\r\n-\t\t\t} else {\r\n-\t\t\t\tvar barW = counts[thresholds[j]]/maxCount*classBarFigureW;\r\n-\t\t\t\tdoc.rect(leftOff + maxLabelLength, bartop, barW, barHeight, "FD");\r\n-\t\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\t\tdoc.text(leftOff + maxLabelLength - doc.getStringUnitWidth(thresholds[j].toString())*classBarLegendTextSize - 4, bartop + barHeight/2, thresholds[j].toString() , null);\r\n-\t\t\t\tdoc.text(leftOff + maxLabelLength +barW + 5, bartop + barHeight/2, "n = " + counts[thresholds[j]] , null);\r\n-\t\t\t}\r\n-\t\t\t\r\n-\t\t\tmissingCount -= counts[thresholds[j]];\r\n-\t\t\tbartop+=barHeight;\r\n-\t\t}\r\n-\t\t\t\r\n-\t\tvar rgb = colorMap.getClassificationColor("Missing Value");\r\n-\t\tdoc.setFillColor(rgb.r,rgb.g,rgb.b);\r\n-\t\tdoc.setDrawColor(0,0,0);\r\n-\t\tif (condenseClassBars){\r\n-\t\t\tvar barW = 10;\r\n-\t\t\tdoc.rect(leftOff, bartop, barW, barHeight, "FD");\r\n-\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\tdoc.text(leftOff +barW + 5, bartop + classBarLegendTextSize, "Missing Value n = " + missingCount , null);\r\n-\t\t} else {\r\n-\t\t\tvar barW = missingCount/maxCount*classBarFigureW;\r\n-\t\t\tdoc.rect(leftOff + maxLabelLength, bartop, barW, barHeight, "FD");\r\n-\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\tdoc.text(leftOff + maxLabelLength - doc.getStringUnitWidth("Missing Value")*classBarLegendTextSize - 4, bartop + barHeight/2, "Missing Value" , null);\r\n-\t\t\tdoc.text(leftOff + maxLabelLength +barW + 5, bartop + barHeight/2, "n = " + missingCount , null);\r\n-\t\t}\r\n-\t\t\r\n-\t\tif (thresholds.length > 15){ // in case a discrete classbar has over 15 categories, make the topOff increment bigger\r\n-\t\t\tclassBarFigureH = (1+thresholds.length)*10;\r\n-\t\t}\r\n-\t\tleftOff+= classBarFigureW + maxLabelLength + 50;\r\n-\t\tif (leftOff + classBarFigureW > pageWidth){ // if the next class bar figure will go beyond the width of the page...\r\n-\t\t\tleftOff = 10; // ...reset leftOff...\r\n-\t\t\ttopOff += classBarFigureH+classBarHeaderSize; // ... and move the next figure to the line below\r\n-\t\t\tclassBarFigureH = 150; // return class bar height to original value in case it got changed in this row\r\n-\t\t\tif (topOff + classBarFigureH > pageHeight){ // if the next class bar goes off the page vertically...\r\n-\t\t\t\tdoc.addPage(); // ... make a new page and reset topOff\r\n-\t\t\t\tcreateHeader();\r\n-\t\t\t\ttopOff = paddingTop + 10;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-\tfunction isChecked(el){\r\n-\t\tif(document.getElementById(el))\r\n-\t\treturn document.getElementById(el).checked;\r\n-\t}\r\n-}\r\n-\r\n-function pdfCancelButton(){\r\n-\tvar prefspanel = document.getElementById(\'pdfPrefsPanel\');\r\n-\tprefspanel.style.display = "none";\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/SelectionManager.js
--- a/MDAheatmap/static/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,449 +0,0 @@\n-/**\r\n- * This code is responsible for handling changes in position of selected heat map region.\r\n- * It handles mouse, keyboard, and button events that change the position of the selected\r\n- * region.  It also tracks whether the display is in a single window or split into two\r\n- * separate windows.  If in separate windows, local storage events are used to communicate\r\n- * changes between the two windows.  \r\n- */\r\n-\r\n-//Globals that provide information about heat map position selection.\r\n-\r\n-mode = null;          // Set to normal or ribbon vertical or ribbon horizontal \r\n-currentRow=null;      // Top row of current selected position\r\n-currentCol=null;      // Left column of the current selected position\r\n-dataPerRow=null;      // How many rows are included in the current selection\r\n-dataPerCol=null;      // How many columns in the current selection\r\n-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.\r\n-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.\r\n-var searchItems=[];   // Valid labels found from a user search\r\n-\r\n-                      //isSub will be set to true if windows are split and this is the child.\r\n-isSub = getURLParameter('sub') == 'true';  \r\n-hasSub = false;       //hasSub set to true if windows are split and this is the parent.\r\n-\r\n-\r\n-/* This routine is called when the selected row / column is changed.\r\n- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,\r\n- * and dataPerCol as desired. This method does redrawing and notification as necessary.  \r\n- */\r\n-function updateSelection() {\r\n-\tif (!isSub) {\r\n-\t\t//We have the summary heat map so redraw the yellow selection box.\r\n-\t\tdrawLeftCanvasBox();\r\n-\t} \r\n-\tif (!hasSub) {\r\n-\t\t// Redraw based on mode type and selection. \r\n-\t\theatMap.setReadWindow(getLevelFromMode(MatrixManager.DETAIL_LEVEL),getCurrentDetRow(),getCurrentDetCol(),getCurrentDetDataPerCol(),getCurrentDetDataPerRow());\r\n-\t\tdrawDetailHeatMap();\r\n-\t} \r\n-\t\r\n- \t//If summary and detail as split into two browsers.  Communicate the selection change\r\n-\t//to the other browser.\r\n-\tif (isSub || hasSub) {\r\n-\t\tlocalStorage.removeItem('event');\r\n-\t\tlocalStorage.setItem('currentRow', '' + currentRow);\r\n-\t\tlocalStorage.setItem('currentCol', '' + currentCol);\r\n-\t\tlocalStorage.setItem('dataPerRow', '' + dataPerRow);\r\n-\t\tlocalStorage.setItem('dataPerCol', '' + dataPerCol);\r\n-\t\tlocalStorage.setItem('selectedStart', '' + selectedStart);\r\n-\t\tlocalStorage.setItem('selectedStop', '' + selectedStop);\r\n-\t\tlocalStorage.setItem('mode', mode);\r\n-\t\tlocalStorage.setItem('selected', JSON.stringify(searchItems));\r\n-\t\tlocalStorage.setItem('event', 'changePosition');\r\n-\t}\t\t\r\n-}\r\n-\r\n-function changeMode(newMode) {\r\n-\t\r\n-\tif (!hasSub) {\r\n-\t\tif (newMode == 'RIBBONH')\r\n-\t\t\tdetailHRibbon();\r\n-\t\tif (newMode == 'RIBBONV')\r\n-\t\t\tdetailVRibbon();\r\n-\t\tif (newMode == 'NORMAL')\r\n-\t\t\tdetailNormal();\r\n-\t} else {\r\n-\t\tlocalStorage.removeItem('event');\r\n-\t\tlocalStorage.setItem('selectedStart', '' + selectedStart);\r\n-\t\tlocalStorage.setItem('selectedStop', '' + selectedStop);\r\n-\t\tlocalStorage.setItem('mode', newMode);\r\n-\t\tlocalStorage.setItem('event', 'changeMode');\r\n-\t}\r\n-}\r\n-\r\n-/* Handle mouse scroll wheel events to zoom in / out.\r\n- */\r\n-function handleScroll(evt) {\r\n-\tevt.preventDefault();\r\n-\tif (evt.wheelDelta < 0 || evt.deltaY > 0 || evt.scale < 1) { //Zoom out\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem('event');\r\n-\t\t\tlocalStorage.setItem('event', 'zoomOut' )\r\n-\t\t}\r\n-\t} else { // Zoom in\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem('event');\r\n-\t\t\tlocalStorage.setItem('event', 'zoomIn' )\r\n-\t\t}\r\n-\t}\t\r\n-\treturn false;\r\n-} \t\t\r\n-\r\n-\r\n-function keyNavigate(e){\r\n-\tuserHelpClose();\r\n-    clearTimeout(detailPoint);\r\n-\tswitch(e.keyCode){ // prevent default added redundantly to each case so that other key inputs w"..b"ated on the summary heat map when drawing the \r\n- * leftCanvasBox on that side of the screen.\r\n- **********************************************************************************/\r\n-function getCurrentSumDataPerRow() {\r\n-\tvar rowSummaryRatio = heatMap.getRowSummaryRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\t// Summary data per row for  using the summary ration for that level\r\n-\tvar\tsumDataPerRow = Math.floor(dataPerRow/rowSummaryRatio);\r\n-\treturn sumDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumDataPerCol() {\r\n-\tvar colSummaryRatio = heatMap.getColSummaryRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tvar\tsumDataPerCol = Math.floor(dataPerCol/colSummaryRatio);\r\n-\treturn sumDataPerCol;\r\n-}\r\n-\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentDetRow(): These functions perform the conversion of \r\n- * currentRow and currentCol coordinates from full matrix position to detail view\r\n- * position.  This is usually the same but when in ribbon view on a large matrix, \r\n- * the positions are scaled.\r\n- **********************************************************************************/\r\n-function getCurrentDetRow() {\r\n-\tvar detRow = currentRow;\r\n-\tif ((mode == 'RIBBONV') && (selectedStart >= 1)) {\r\n-\t\tvar rvRatio = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tdetRow = Math.round(selectedStart/rvRatio);\r\n-\t}\r\n-\treturn  detRow;\r\n-}\r\n-//Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentDetCol() {\r\n-\tvar detCol = currentCol;\r\n-\tif ((mode == 'RIBBONH') && (selectedStart >= 1)) {\r\n-\t\tvar rhRatio = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tdetCol = Math.round(selectedStart/rhRatio);\r\n-\t}\r\n-\treturn  detCol;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentDetDataPerRow(): DataPerRow/Col is in full matrix coordinates\r\n- * and usually the detail view uses this value directly unless we are in ribbon\r\n- * view where the value needs to be scaled in one dimension.\r\n- **********************************************************************************/\r\n-function getCurrentDetDataPerRow() {\r\n-\tvar\tdetDataPerRow = dataPerRow;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rate = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tdetDataPerRow = Math.round(detDataPerRow/rate);\r\n-\t} \r\n-\treturn detDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentDetDataPerCol() {\r\n-\tvar\tdetDataPerCol = dataPerCol;\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rate = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tdetDataPerCol = Math.round(detDataPerCol/rate);\r\n-\t} \r\n-\treturn detDataPerCol;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - setDataPerRowFromDet(): DataPerRow/Col is in full matrix coordinates\r\n- * so sometimes in ribbon view this needs to be translated to full coordinates.\r\n- **********************************************************************************/\r\n-function setDataPerRowFromDet(detDataPerRow) {\r\n-\tdataPerRow = detDataPerRow;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tif (selectedStart==0) {\r\n-\t\t\tdataPerRow = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);\r\n-\t\t} else {\r\n-\t\t\tvar rate = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\t\tdataPerRow = detDataPerRow * rate;\r\n-\t\t}\r\n-\t} \r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function setDataPerColFromDet(detDataPerCol) {\r\n-\tdataPerCol = detDataPerCol;\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tif (selectedStart==0) {\r\n-\t\t\tdataPerCol = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);\r\n-\t\t} else {\r\n-\t\t\tvar rate = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\t\tdataPerCol = detDataPerCol * rate;\r\n-\t\t}\r\n-\t} \r\n-}\r\n-\r\n-\r\n-\r\n-\r\n-\r\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/SummaryHeatMapDisplay.js
--- a/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1026 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var dendroPaddingHeight = 1;\r\n-var rowDendroHeight = 102; // this is the height of the row dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var columnDendroHeight = 102; // this is the height of the col dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var normDendroMatrixHeight = 500; // this is the height of the dendro matrices created in buildDendroMatrix\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-\r\n-var rowDendroBars;\r\n-var colDendroBars;\r\n-var colDendroMatrix;\r\n-var rowDendroMatrix;\r\n-var chosenBar = {axis: null, index: null};\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcanvas.onmousemove = handleMove;\r\n-\t// set the position to (1,1) so that the detail pane loads at the top left corner of the summary.\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {   \r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tsummaryInit();\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//Summary tile - wait a bit to see if we get another tile quickly, then draw\r\n-\t\tif (eventTimer != 0) {\r\n-\t\t\t//New tile arrived - reset timer\r\n-\t\t\tclearTimeout(eventTimer);\r\n-\t\t}\r\n-\t\teventTimer = setTimeout(buildSummaryTexture, 200);\r\n-\t} \r\n-\t//Ignore updates to other tile types.\r\n-}\r\n-\r\n-// Perform all initialization functions for Summary heat map\r\n-function summaryInit() {\r\n-\tvar dendroGram = heatMap.getDendrogram();\r\n-\trowDendroHeight = parseInt(dendroGram[\'row_dendro_height\'])+2;\r\n-\tcolumnDendroHeight = parseInt(dendroGram[\'col_dendro_height\'])+2;\r\n-\tif (heatMap.showRowDendrogram("SUMMARY")) {\r\n-\t\trowDendroMatrix = buildDendroMatrix(dendroGram,\'Row\'); // create array with the bars\r\n-\t}\r\n-\tif (heatMap.showColDendrogram("SUMMARY")) {\r\n-\t\tcolDendroMatrix = buildDendroMatrix(dendroGram,\'Column\'); // create array with the bars\r\n-\t}\r\n-\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\r\n-\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\trowEmptySpace = summaryMatrixWidth/2 - sum'..b'= 2;\r\n-\t\t}\r\n-\t}\r\n-\treturn j;\r\n-}\r\n-\r\n-function highlightAllBranchesInRange(height,leftExtreme,rightExtreme,dendroMatrix){\r\n-\tfor (var i = height; i >= 0; i--){\r\n-\t\tfor (var loc in dendroMatrix[i]){\r\n-\t\t\tif (leftExtreme < loc && loc < rightExtreme){\r\n-\t\t\t\tdendroMatrix[i][loc] = 2;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function clearDendroSelection(){\r\n-\tchosenBar = {axis: null, index: null};\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tif (heatMap.showColDendrogram("summary")) {\r\n-\t\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\');\r\n-\t\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\t}\r\n-\t\tif (heatMap.showRowDendrogram("summary")) {\r\n-\t\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),"Row");\r\n-\t\t\tdrawRowDendrogram(TexPixels);\r\n-\t\t}\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\r\n-\r\n-\r\n-//***************************//\r\n-//Selection Label Functions *//\r\n-//***************************//\r\n-function summaryResize() {\r\n-\tclearSelectionMarks();\r\n-\tdrawRowSelectionMarks();\r\n-\tdrawColSelectionMarks();\r\n-}\r\n-\r\n-\r\n-function drawRowSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalHeight - summaryMatrixHeight;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedRows = getSearchRows();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedRows.length; i++) {\r\n-\t\tvar xPos = (1-colEmptySpace/canvas.width)*canvas.clientWidth + 3;\r\n-\t\tvar position = headerSize + (selectedRows[i]/heatMap.getRowSummaryRatio(MatrixManager.SUMMARY_LEVEL));\r\n-\t\tvar yPos = ((position /summaryTotalHeight-(rowEmptySpace/canvas.height))* canvas.clientHeight) - fontSize;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'F\');\r\n-\t}\r\n-}\r\n-\r\n-function drawColSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalWidth - summaryMatrixWidth;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedCols = getSearchCols();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedCols.length; i++) {\r\n-\t\tvar position = headerSize + (selectedCols[i]/heatMap.getColSummaryRatio(MatrixManager.SUMMARY_LEVEL));\r\n-\t\tvar xPos = ((position / summaryTotalWidth-(colEmptySpace/canvas.width))*(canvas.clientWidth)) + fontSize/2;\r\n-\t\tvar yPos = (1-rowEmptySpace/canvas.height)*canvas.clientHeight + 4;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'T\');\r\n-\t}\r\n-}\r\n-\r\n-function clearSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar oldMarks = document.getElementsByClassName("MarkLabel");\r\n-\twhile (oldMarks.length > 0) {\r\n-\t\tmarkElement.removeChild(oldMarks[0]);\r\n-\t}\r\n-\r\n-}\r\n-\r\n-\r\n-function dividerStart(){\r\n-\tuserHelpClose();\r\n-\tdocument.addEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.addEventListener(\'touchmove\', dividerMove);\r\n-\tdocument.addEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.addEventListener(\'touchend\',dividerEnd);\r\n-}\r\n-function dividerMove(e){\r\n-\tvar divider = document.getElementById(\'divider\');\r\n-\tif (e.touches){\r\n-    \tif (e.touches.length > 1){\r\n-    \t\treturn false;\r\n-    \t}\r\n-    }\r\n-\tvar Xmove = e.touches ? divider.offsetLeft - e.touches[0].pageX : divider.offsetLeft - e.pageX;\r\n-\tvar summary = document.getElementById(\'summary_chm\');\r\n-\tvar summaryX = summary.offsetWidth - Xmove;\r\n-\tsummary.setAttribute("style","position: relative; width:" + summaryX + "px");\r\n-\tvar detail = document.getElementById(\'detail_chm\');\r\n-\tvar detailX = detail.offsetWidth + Xmove;\r\n-\tdetail.setAttribute("style","position: relative; width:" + detailX + "px");\r\n-\tclearLabels();\r\n-\tclearSelectionMarks();\r\n-}\r\n-function dividerEnd(){\r\n-\tdocument.removeEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.removeEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.removeEventListener(\'touchmove\',dividerMove);\r\n-\tdocument.removeEventListener(\'touchend\',dividerEnd);\r\n-\tdetailResize();\r\n-\tsummaryResize();\r\n-}\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/UserHelpManager.js
--- a/MDAheatmap/static/javascript/UserHelpManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,527 +0,0 @@\n-/**********************************************************************************\r\n- * USER HELP FUNCTIONS:  The following functions handle the processing \r\n- * for user help popup windows for the detail canvas and the detail canvas buttons.\r\n- **********************************************************************************/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - userHelpOpen: This function handles all of the tasks necessary to \r\n- * generate help pop-up panels for the detail heat map and the detail heat map \r\n- * classification bars.  \r\n- **********************************************************************************/\r\n-function userHelpOpen(e){ \r\n-    userHelpClose();\r\n-    clearTimeout(detailPoint);\r\n-    var orgW = window.innerWidth+window.pageXOffset;\r\n-    var orgH = window.innerHeight+window.pageYOffset;\r\n-    var helptext = getDivElement("helptext");    \r\n-    helptext.style.position = "absolute";\r\n-    document.getElementsByTagName(\'body\')[0].appendChild(helptext);\r\n-    var rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width; // px/Glpoint\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\r\n-    // pixels\r\n-    var rowClassWidthPx = getRowClassPixelWidth();\r\n-    var colClassHeightPx = getColClassPixelHeight();\r\n-    var rowDendroWidthPx =  getRowDendroPixelWidth();\r\n-    var colDendroHeightPx = getColDendroPixelHeight();\r\n-\tvar mapLocY = e.layerY - colClassHeightPx - colDendroHeightPx;\r\n-\tvar mapLocX = e.layerX - rowClassWidthPx - rowDendroWidthPx;\r\n-\t\r\n-    if (isOnObject(e,"map")) {\r\n-    \tvar row = Math.floor(currentRow + (mapLocY/colElementSize)*getSamplingRatio(\'row\'));\r\n-    \tvar col = Math.floor(currentCol + (mapLocX/rowElementSize)*getSamplingRatio(\'col\'));\r\n-    \tvar rowLabels = heatMap.getRowLabels().labels;\r\n-    \tvar colLabels = heatMap.getColLabels().labels;\r\n-    \tvar classBars = heatMap.getClassifications();\r\n-    \tvar helpContents = document.createElement("TABLE");\r\n-    \tsetTableRow(helpContents, ["<u>"+"Data Details"+"</u>", "&nbsp;"], 2);\r\n-    \tsetTableRow(helpContents,["&nbsp;Value:", heatMap.getValue(MatrixManager.DETAIL_LEVEL,row,col).toFixed(5)]);\r\n-    \tsetTableRow(helpContents,[ "&nbsp;Row:", rowLabels[row-1]]);\r\n-    \tsetTableRow(helpContents,["&nbsp;Column:", colLabels[col-1]]);\r\n-    \thelpContents.insertRow().innerHTML = formatBlankRow();\r\n-    \tvar rowCtr = 8;\r\n-    \tvar writeFirstCol = true;\r\n-    \tvar pos = col;\r\n-    \tvar classLen = Object.keys(classBars).length;\r\n-    \tif (classLen > 0) {\r\n-\t\t\tsetTableRow(helpContents, ["&nbsp;<u>"+"Row Classifications"+"</u>", "&nbsp;"], 2);\r\n-\t    \tfor (var key in classBars){\r\n-\t    \t\tif (classBars[key].position == "column") {\r\n-\t    \t\t\tif (writeFirstCol) {\r\n-\t    \t\t    \thelpContents.insertRow().innerHTML = formatBlankRow();\r\n-\t    \t\t\t\tsetTableRow(helpContents, ["&nbsp;<u>"+"Column Classifications"+"</u>", "&nbsp;"], 2);\r\n-\t    \t\t\t\twriteFirstCol = false;\r\n-\t    \t\t\t}\r\n-\t        \t\tpos = row;\r\n-\t        \t\trowCtr = rowCtr++;\r\n-\t    \t\t}\r\n-\t    \t\tsetTableRow(helpContents,["&nbsp;&nbsp;&nbsp;"+key+":"+"</u>", classBars[key].values[pos-1]]);\t    \t\t\r\n-\t    \t\trowCtr++;\r\n-\t    \t}\r\n-    \t}\r\n-        helptext.style.display="inherit";\r\n-    \thelptext.appendChild(helpContents);\r\n-    \tlocateHelpBox(e, helptext);\r\n-    } else if (isOnObject(e,"rowClass") || isOnObject(e,"colClass")) {\r\n-    \tvar pos, classInfo, names, colorSchemes, value;\r\n-    \tvar classBars = heatMap.getClassifications();\r\n-    \tvar hoveredBar, hoveredBarColorScheme;                                                     //coveredWidth = 0, coveredHeight = 0;\r\n-    \tif (isOnObject(e,"colClass")) {\r\n-    \t\tvar coveredHeight = detCanvas.clientHeight*detailDendroHeight/detCanvas.height\r\n-    \t\tpos = Math.floor(currentCol + (mapLocX/rowElementSize));\r\n-    \t\tclassInfo = getClassBarsToDraw("column");\r\n-        \tnames = classInfo["bars"];\r\n-        \tcolorSche'..b'have these inputs!\r\n-\t};\r\n-\tcell.addEventListener(\'click\', functionWithParams);\r\n-}\r\n-\r\n-function getDefaultLinkouts(){\r\n-\taddLinkout("Copy " + heatMap.getColLabels()["label_type"] +" to Clipboard", heatMap.getColLabels()["label_type"], "labels", copyToClipBoard,0);\r\n-\taddLinkout("Copy " +heatMap.getRowLabels()["label_type"] + " to Clipboard", heatMap.getRowLabels()["label_type"], "labels", copyToClipBoard,0);\r\n-\taddLinkout("Copy bar data for all labels to Clipboard", "ColumnClass", "labels",copyEntireClassBarToClipBoard,0);\r\n-\taddLinkout("Copy bar data for selected labels to Clipboard", "ColumnClass", "labels",copyPartialClassBarToClipBoard,1);\r\n-\taddLinkout("Copy bar data for all labels to Clipboard", "RowClass", "labels",copyEntireClassBarToClipBoard,0);\r\n-\taddLinkout("Copy bar data for selected labels to Clipboard", "RowClass", "labels",copyPartialClassBarToClipBoard,1);\r\n-}\r\n-\r\n-function linkout (title, inputType, callback){ // the linkout object\r\n-\tthis.title = title;\r\n-\tthis.inputType = inputType; // input type of the callback function\r\n-\tthis.callback = callback;\r\n-}\r\n-\r\n-function addLinkout(name, labelType, inputType, callback, index){ // adds linkout objects to the linkouts global variable\r\n-\tif (!linkouts[labelType]){\r\n-\t\tlinkouts[labelType] = [new linkout(name, inputType,callback)];\r\n-\t} else {\r\n-\t\tif (index !== undefined){\r\n-\t\t\tlinkouts[labelType].splice(index, 0, new linkout(name,inputType,callback)); \r\n-\t\t}else {\r\n-\t\t\tlinkouts[labelType].push(new linkout(name,inputType,callback));\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function copyToClipBoard(labels,axis){\r\n-\twindow.open("","",\'width=335,height=330,resizable=1\').document.write(labels.join(", "));\r\n-}\r\n-\r\n-function copyEntireClassBarToClipBoard(labels,axis){\r\n-\tvar newWindow = window.open("","",\'width=335,height=330,resizable=1\');\r\n-\tvar newDoc = newWindow.document;\r\n-\tvar axisLabels = axis == "ColumnClass" ? heatMap.getColLabels()["labels"] : heatMap.getRowLabels()["labels"]; \r\n-\tvar classifications = heatMap.getClassifications();\r\n-\tnewDoc.write("Sample&emsp;" + labels.join("&emsp;") + ":<br>");\r\n-\tfor (var i = 0; i < axisLabels.length; i++){\r\n-\t\tnewDoc.write(axisLabels[i] + "&emsp;");\r\n-\t\tfor (var j = 0; j < labels.length; j++){\r\n-\t\t\tnewDoc.write(classifications[labels[j]].values[i] + "&emsp;");\r\n-\t\t}\r\n-\t\tnewDoc.write("<br>");\r\n-\t}\r\n-}\r\n-\r\n-function copyPartialClassBarToClipBoard(labels,axis){\r\n-\tvar newWindow = window.open("","",\'width=335,height=330,resizable=1\');\r\n-\tvar newDoc = newWindow.document;\r\n-\tvar axisLabels = axis == "ColumnClass" ? getSearchLabelsByAxis("Column") : getSearchLabelsByAxis("Row");\r\n-\tvar labelIndex = axis == "ColumnClass" ? getSearchCols() : getSearchRows(); \r\n-\tvar classifications = heatMap.getClassifications();\r\n-\tnewDoc.write("Sample&emsp;" + labels.join("&emsp;") + ":<br>");\r\n-\tfor (var i = 0; i < axisLabels.length; i++){\r\n-\t\tnewDoc.write(axisLabels[i] + "&emsp;");\r\n-\t\tfor (var j = 0; j < labels.length; j++){\r\n-\t\t\tnewDoc.write(classifications[labels[j]].values[labelIndex[i]-1] + "&emsp;");\r\n-\t\t}\r\n-\t\tnewDoc.write("<br>");\r\n-\t}\r\n-}\r\n-\r\n-//===========================\r\n-// LABEL MENU FUNCTIONS END \r\n-//===========================\r\n-\r\n-function showSearchError(type){\r\n-\tvar searchError = getDivElement(\'searchError\');\r\n-\tsearchError.style.display = \'inherit\';\r\n-\tvar searchBar = document.getElementById(\'search_text\');\r\n-\tsearchError.style.top = searchBar.offsetTop + searchBar.offsetHeight;\r\n-\tsearchError.style.left = searchBar.offsetLeft + searchBar.offsetWidth;\r\n-\tswitch (type){\r\n-\t\tcase 0: searchError.innerHTML = "No matching labels found"; break;\r\n-\t\tcase 1: searchError.innerHTML = "Exit dendrogram selection to go to " + currentSearchItem.label;break;\r\n-\t\tcase 2: searchError.innerHTML = "All " + currentSearchItem.axis +  " items are visible. Change the view mode to see " + currentSearchItem.label;break;\r\n-\t}\r\n-\tdocument.body.appendChild(searchError);\r\n-\tsetTimeout(function(){\r\n-\t\tsearchError.remove();\r\n-\t}, 2000);\r\n-\t\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/UserPreferenceManager.js
--- a/MDAheatmap/static/javascript/UserPreferenceManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1159 +0,0 @@\n-/**********************************************************************************\r\n- * USER PREFERENCE FUNCTIONS:  The following functions handle the processing \r\n- * for user preference editing. \r\n- **********************************************************************************/\r\n-\r\n-//Global variables for preference processing\r\n-var maxRows = 0;\r\n-var helpRowSize = 0;\r\n-var bkpColorMap = null;\r\n-var filterVal;\r\n-var searchPerformed = false;\r\n-\r\n-/*===================================================================================\r\n- *  COMMON PREFERENCE PROCESSING FUNCTIONS\r\n- *  \r\n- *  The following functions are utilized to present the entire heat map preferences\r\n- *  dialog and, therefore, sit above those functions designed specifically for processing\r\n- *  individual data layer and covariate classification bar preferences:\r\n- *  \t- editPreferences\r\n- *  \t- setPrefsDivSizing\r\n- *  \t- showLayerPrefs\r\n- *      - showClassPrefs\r\n- *      - showRowsColsPrefs\r\n- *      - prefsCancel\r\n- *      - prefsApply\r\n- *      - prefsValidate\r\n- *      - prefsValidateBreakPoints\r\n- *      - prefsValidateBreakColors\r\n- *      - prefsApplyBreaks\r\n- *      - getNewBreakColors\r\n- *      - getNewBreakThresholds  \r\n- *      - prefsSave\r\n- =================================================================================*/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - editPreferences: This is the MAIN driver function for edit \r\n- * preferences processing.  It is called under two conditions (1) The Edit \r\n- * preferences "gear" button is pressed on the main application screen \r\n- * (2) User preferences have been applied BUT errors have occurred.\r\n- * \r\n- * Processing for this function is documented in detail in the body of the function.\r\n- **********************************************************************************/\r\n-function editPreferences(e,errorMsg){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\r\n-\t// If helpPrefs element already exists, the user is pressing the gear button\r\n-\t// when preferences are already open. Disregard.\r\n-\tvar helpExists = document.getElementById(\'prefsPanel\');\r\n-\tif ((isSub) || (helpExists !== null)) {\r\n-\t\treturn;\r\n-\t}\r\n-\r\n-\t//If first time thru, save the dataLayer colorMap\r\n-\t//This is done because the colorMap must be edited to add/delete breakpoints while retaining their state\r\n-\tvar colorMap = heatMap.getColorMapManager().getColorMap("dl1"); //TODO - Modify when multiple data layers (flick) are added\r\n-\tif (bkpColorMap === null) {\r\n-\t\tbkpColorMap = colorMap;\r\n-\t} \r\n-\r\n-\t//Create a "master" DIV for displaying edit preferences\r\n-\tvar prefspanel = getDivElement("prefsPanel");\r\n-\tdocument.getElementsByTagName(\'body\')[0].appendChild(prefspanel);\r\n-\t\r\n-\t//Create a one cell table and populate the header and tab elements in the first 3 table rows\r\n-\tvar prefContents = document.createElement("TABLE");\r\n-\tvar headDiv = document.createElement(\'div\');\r\n-\theadDiv.className = \'prefsHeader\';\r\n-\theadDiv.id = \'prefsHeader\';\r\n-\tprefspanel.appendChild(headDiv);\r\n-\theadDiv.textContent = \'Heat Map Display Properties\';\r\n-\t\r\n-\tprefContents.insertRow().innerHTML = formatBlankRow();\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'line-height:30px;\'>&nbsp;</td>";\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'border-bottom-style:solid;border-bottom-width:2px;position: relative;\'><div id=\'prefTab_buttons\' style=\'position: absolute; bottom: 0;\' align=\'left\'><img id=\'prefRowsCols_btn\' src=\'" + staticPath + "rowsColsOn.png\' alt=\'Edit Rows & Columns\' onclick=\'showRowsColsPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefLayer_btn\' src=\'" + staticPath + "images/dataLayersOff.png\' alt=\'Edit Data Layers\' onclick=\'showLayerPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefClass_btn\' src=\'" + staticPath+ "images/covariateBarsOff.png\' alt=\'Edit Classifications\' onclick=\'showClassPrefs();\' align=\'top\'/></div></td>";\r\n-\t//Initialize rowCtr variable\r\n-\tvar rowCtr = 3;\r\n-\r\n-\t//Cr'..b'******************************************/\r\n-function showDendroSelections() {\r\n-\tvar dendrogram = heatMap.getDendrogram();\r\n-\tvar rowLabels = heatMap.getRowLabels();\r\n-\tvar rowOrder = rowLabels[\'order_method\'];\r\n-\tif (rowOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'row_dendro_show\'];\r\n-\t\tdocument.getElementById("rowDendroShowPref").value = dendroShowVal;\r\n-\t\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = rowHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\trowHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\trowHeightPref.add(option);\r\n-\t\t\trowHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\trowHeightPref.value = dendrogram[\'row_dendro_height\'];\r\n-\t}\r\n-\tvar colLabels = heatMap.getColLabels();\r\n-\tvar colOrder = colLabels[\'order_method\'];\r\n-\tif (colOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'col_dendro_show\'];\r\n-\t\tdocument.getElementById("colDendroShowPref").value = dendroShowVal;\r\n-\t\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = colHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\tcolHeightPref.add(option);\r\n-\t\t\tcolHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\tcolHeightPref.value = dendrogram[\'col_dendro_height\'];\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroRowShowChange() {\r\n-\tvar newValue = document.getElementById("rowDendroShowPref").value;\r\n-\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\trowHeightPref.add(option);\r\n-\t\trowHeightPref.value = \'10\';\r\n-\t\trowHeightPref.disabled = true;\r\n-\t} else if (rowHeightPref.disabled) {\r\n-\t\tvar opt = rowHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\trowHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\trowHeightPref.value = \'100\';\r\n-\t\trowHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroColShowChange() {\r\n-\tvar newValue = document.getElementById("colDendroShowPref").value;\r\n-\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\tcolHeightPref.add(option);\r\n-\t\tcolHeightPref.value = \'10\';\r\n-\t\tcolHeightPref.disabled = true;\r\n-\t} else if (colHeightPref.disabled) {\r\n-\t\tvar opt = colHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\tcolHeightPref.value = \'100\';\r\n-\t\tcolHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/UserPreferenceManager.js.sav
--- a/MDAheatmap/static/javascript/UserPreferenceManager.js.sav Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1159 +0,0 @@\n-/**********************************************************************************\r\n- * USER PREFERENCE FUNCTIONS:  The following functions handle the processing \r\n- * for user preference editing. \r\n- **********************************************************************************/\r\n-\r\n-//Global variables for preference processing\r\n-var maxRows = 0;\r\n-var helpRowSize = 0;\r\n-var bkpColorMap = null;\r\n-var filterVal;\r\n-var searchPerformed = false;\r\n-\r\n-/*===================================================================================\r\n- *  COMMON PREFERENCE PROCESSING FUNCTIONS\r\n- *  \r\n- *  The following functions are utilized to present the entire heat map preferences\r\n- *  dialog and, therefore, sit above those functions designed specifically for processing\r\n- *  individual data layer and covariate classification bar preferences:\r\n- *  \t- editPreferences\r\n- *  \t- setPrefsDivSizing\r\n- *  \t- showLayerPrefs\r\n- *      - showClassPrefs\r\n- *      - showRowsColsPrefs\r\n- *      - prefsCancel\r\n- *      - prefsApply\r\n- *      - prefsValidate\r\n- *      - prefsValidateBreakPoints\r\n- *      - prefsValidateBreakColors\r\n- *      - prefsApplyBreaks\r\n- *      - getNewBreakColors\r\n- *      - getNewBreakThresholds  \r\n- *      - prefsSave\r\n- =================================================================================*/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - editPreferences: This is the MAIN driver function for edit \r\n- * preferences processing.  It is called under two conditions (1) The Edit \r\n- * preferences "gear" button is pressed on the main application screen \r\n- * (2) User preferences have been applied BUT errors have occurred.\r\n- * \r\n- * Processing for this function is documented in detail in the body of the function.\r\n- **********************************************************************************/\r\n-function editPreferences(e,errorMsg){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\r\n-\t// If helpPrefs element already exists, the user is pressing the gear button\r\n-\t// when preferences are already open. Disregard.\r\n-\tvar helpExists = document.getElementById(\'prefsPanel\');\r\n-\tif ((isSub) || (helpExists !== null)) {\r\n-\t\treturn;\r\n-\t}\r\n-\r\n-\t//If first time thru, save the dataLayer colorMap\r\n-\t//This is done because the colorMap must be edited to add/delete breakpoints while retaining their state\r\n-\tvar colorMap = heatMap.getColorMapManager().getColorMap("dl1"); //TODO - Modify when multiple data layers (flick) are added\r\n-\tif (bkpColorMap === null) {\r\n-\t\tbkpColorMap = colorMap;\r\n-\t} \r\n-\r\n-\t//Create a "master" DIV for displaying edit preferences\r\n-\tvar prefspanel = getDivElement("prefsPanel");\r\n-\tdocument.getElementsByTagName(\'body\')[0].appendChild(prefspanel);\r\n-\t\r\n-\t//Create a one cell table and populate the header and tab elements in the first 3 table rows\r\n-\tvar prefContents = document.createElement("TABLE");\r\n-\tvar headDiv = document.createElement(\'div\');\r\n-\theadDiv.className = \'prefsHeader\';\r\n-\theadDiv.id = \'prefsHeader\';\r\n-\tprefspanel.appendChild(headDiv);\r\n-\theadDiv.textContent = \'Heat Map Display Properties\';\r\n-\t\r\n-\tprefContents.insertRow().innerHTML = formatBlankRow();\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'line-height:30px;\'>&nbsp;</td>";\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'border-bottom-style:solid;border-bottom-width:2px;position: relative;\'><div id=\'prefTab_buttons\' style=\'position: absolute; bottom: 0;\' align=\'left\'><img id=\'prefRowsCols_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/rowsColsOn.png\' alt=\'Edit Rows & Columns\' onclick=\'showRowsColsPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefLayer_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/dataLayersOff.png\' alt=\'Edit Data Layers\' onclick=\'showLayerPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefClass_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/covariateBarsOff.png\' alt=\'Edit Classifications\' onclick=\'showClassPrefs();\' align=\'t'..b'******************************************/\r\n-function showDendroSelections() {\r\n-\tvar dendrogram = heatMap.getDendrogram();\r\n-\tvar rowLabels = heatMap.getRowLabels();\r\n-\tvar rowOrder = rowLabels[\'order_method\'];\r\n-\tif (rowOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'row_dendro_show\'];\r\n-\t\tdocument.getElementById("rowDendroShowPref").value = dendroShowVal;\r\n-\t\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = rowHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\trowHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\trowHeightPref.add(option);\r\n-\t\t\trowHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\trowHeightPref.value = dendrogram[\'row_dendro_height\'];\r\n-\t}\r\n-\tvar colLabels = heatMap.getColLabels();\r\n-\tvar colOrder = colLabels[\'order_method\'];\r\n-\tif (colOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'col_dendro_show\'];\r\n-\t\tdocument.getElementById("colDendroShowPref").value = dendroShowVal;\r\n-\t\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = colHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\tcolHeightPref.add(option);\r\n-\t\t\tcolHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\tcolHeightPref.value = dendrogram[\'col_dendro_height\'];\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroRowShowChange() {\r\n-\tvar newValue = document.getElementById("rowDendroShowPref").value;\r\n-\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\trowHeightPref.add(option);\r\n-\t\trowHeightPref.value = \'10\';\r\n-\t\trowHeightPref.disabled = true;\r\n-\t} else if (rowHeightPref.disabled) {\r\n-\t\tvar opt = rowHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\trowHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\trowHeightPref.value = \'100\';\r\n-\t\trowHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroColShowChange() {\r\n-\tvar newValue = document.getElementById("colDendroShowPref").value;\r\n-\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\tcolHeightPref.add(option);\r\n-\t\tcolHeightPref.value = \'10\';\r\n-\t\tcolHeightPref.disabled = true;\r\n-\t} else if (colHeightPref.disabled) {\r\n-\t\tvar opt = colHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\tcolHeightPref.value = \'100\';\r\n-\t\tcolHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/custom.js
--- a/MDAheatmap/static/javascript/custom.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,42 +0,0 @@
-/*
- *  TO DO: give custom.js its own namespace so it can't modify variables used outside
- *  Only outside function/variable it should be able to access right now is addLinkout and the inputs of each custom function (label text or index)
- */
-
-addLinkout("Search Google", "Samples", "labels", searchGoogle);
-
-addLinkout("Search Google", "Genes", "labels", searchGoogle);
-addLinkout("Search GeneCards", "Genes", "labels", searchGeneCards);
-addLinkout("Search PubMed for All", "Genes", "labels", searchPubMedForAll);
-addLinkout("Search PubMed for Any", "Genes", "labels", searchPubMedForAny);
-
-function searchGoogle(selection, axis){
- window.open('https://www.google.com/#q=' + selection.join("+"));
-}
-
-function searchGeneCards(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(1);
- window.open('http://www.genecards.org/Search/Keyword?queryString=' + searchTerm);
-}
-
-function searchPubMedForAll(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+AND+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(5);
- window.open("http://www.ncbi.nlm.nih.gov/pubmed/?term=" + searchTerm)
-}
-
-function searchPubMedForAny(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+OR+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(4);
- window.open("http://www.ncbi.nlm.nih.gov/pubmed/?term=" + searchTerm)
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/lib/deflate.js
--- a/MDAheatmap/static/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/lib/inflate.js
--- a/MDAheatmap/static/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/lib/jspdf.debug.js
--- a/MDAheatmap/static/javascript/lib/jspdf.debug.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,9359 +0,0 @@\n-/** @preserve\r\n- * jsPDF - PDF Document creation from JavaScript\r\n- * Version 1.0.272-git Built on 2014-09-29T15:09\r\n- *                           CommitID d4770725ca\r\n- *\r\n- * Copyright (c) 2010-2014 James Hall, https://github.com/MrRio/jsPDF\r\n- *               2010 Aaron Spike, https://github.com/acspike\r\n- *               2012 Willow Systems Corporation, willow-systems.com\r\n- *               2012 Pablo Hess, https://github.com/pablohess\r\n- *               2012 Florian Jenett, https://github.com/fjenett\r\n- *               2013 Warren Weckesser, https://github.com/warrenweckesser\r\n- *               2013 Youssef Beddad, https://github.com/lifof\r\n- *               2013 Lee Driscoll, https://github.com/lsdriscoll\r\n- *               2013 Stefan Slonevskiy, https://github.com/stefslon\r\n- *               2013 Jeremy Morel, https://github.com/jmorel\r\n- *               2013 Christoph Hartmann, https://github.com/chris-rock\r\n- *               2014 Juan Pablo Gaviria, https://github.com/juanpgaviria\r\n- *               2014 James Makes, https://github.com/dollaruw\r\n- *               2014 Diego Casorran, https://github.com/diegocr\r\n- *\r\n- * Permission is hereby granted, free of charge, to any person obtaining\r\n- * a copy of this software and associated documentation files (the\r\n- * "Software"), to deal in the Software without restriction, including\r\n- * without limitation the rights to use, copy, modify, merge, publish,\r\n- * distribute, sublicense, and/or sell copies of the Software, and to\r\n- * permit persons to whom the Software is furnished to do so, subject to\r\n- * the following conditions:\r\n- *\r\n- * The above copyright notice and this permission notice shall be\r\n- * included in all copies or substantial portions of the Software.\r\n- *\r\n- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r\n- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r\n- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r\n- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\r\n- * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\r\n- * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\r\n- * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r\n- *\r\n- * Contributor(s):\r\n- *    siefkenj, ahwolf, rickygu, Midnith, saintclair, eaparango,\r\n- *    kim3er, mfo, alnorth,\r\n- */\r\n-\r\n-/**\r\n- * Creates new jsPDF document object instance.\r\n- *\r\n- * @class\r\n- * @param orientation One of "portrait" or "landscape" (or shortcuts "p" (Default), "l")\r\n- * @param unit        Measurement unit to be used when coordinates are specified.\r\n- *                    One of "pt" (points), "mm" (Default), "cm", "in"\r\n- * @param format      One of \'pageFormats\' as shown below, default: a4\r\n- * @returns {jsPDF}\r\n- * @name jsPDF\r\n- */\r\n-var jsPDF = (function(global) {\r\n-\t\'use strict\';\r\n-\tvar pdfVersion = \'1.3\',\r\n-\t\tpageFormats = { // Size in pt of various paper formats\r\n-\t\t\t\'a0\'  : [2383.94, 3370.39], \'a1\'  : [1683.78, 2383.94],\r\n-\t\t\t\'a2\'  : [1190.55, 1683.78], \'a3\'  : [ 841.89, 1190.55],\r\n-\t\t\t\'a4\'  : [ 595.28,  841.89], \'a5\'  : [ 419.53,  595.28],\r\n-\t\t\t\'a6\'  : [ 297.64,  419.53], \'a7\'  : [ 209.76,  297.64],\r\n-\t\t\t\'a8\'  : [ 147.40,  209.76], \'a9\'  : [ 104.88,  147.40],\r\n-\t\t\t\'a10\' : [  73.70,  104.88], \'b0\'  : [2834.65, 4008.19],\r\n-\t\t\t\'b1\'  : [2004.09, 2834.65], \'b2\'  : [1417.32, 2004.09],\r\n-\t\t\t\'b3\'  : [1000.63, 1417.32], \'b4\'  : [ 708.66, 1000.63],\r\n-\t\t\t\'b5\'  : [ 498.90,  708.66], \'b6\'  : [ 354.33,  498.90],\r\n-\t\t\t\'b7\'  : [ 249.45,  354.33], \'b8\'  : [ 175.75,  249.45],\r\n-\t\t\t\'b9\'  : [ 124.72,  175.75], \'b10\' : [  87.87,  124.72],\r\n-\t\t\t\'c0\'  : [2599.37, 3676.54], \'c1\'  : [1836.85, 2599.37],\r\n-\t\t\t\'c2\'  : [1298.27, 1836.85], \'c3\'  : [ 918.43, 1298.27],\r\n-\t\t\t\'c4\'  : [ 649.13,  918.43], \'c5\'  : [ 459.21,  649.13],\r\n-\t\t\t\'c6\'  : [ 323.15,  459.21], \'c7\'  : [ 229.61,  323.15],\r\n-\t\t\t\'c8\'  : [ 161.57,  229.61], \'c9\'  : [ 113.39,  161.57],\r\n-\t\t\t\'c10\' : [  79.37,  113.39], \'dl\'  : ['..b'\t\t\t//    input by: Aman Gupta\r\n-\t\t\t//    input by: Brett Zamir (http://brett-zamir.me)\r\n-\t\t\t// bugfixed by: Onno Marsman\r\n-\t\t\t// bugfixed by: Pellentesque Malesuada\r\n-\t\t\t// bugfixed by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)\r\n-\t\t\t//   example 1: base64_decode(\'S2V2aW4gdmFuIFpvbm5ldmVsZA==\');\r\n-\t\t\t//   returns 1: \'Kevin van Zonneveld\'\r\n-\r\n-\t\t\tvar o1,o2,o3,h1,h2,h3,h4,bits,i = 0,ac = 0,dec = \'\',tmp_arr = [];\r\n-\r\n-\t\t\tif (!data) {\r\n-\t\t\t\treturn data;\r\n-\t\t\t}\r\n-\r\n-\t\t\tdata += \'\';\r\n-\r\n-\t\t\tdo { // unpack four hexets into three octets using index points in b64\r\n-\t\t\t\th1 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th2 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th3 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th4 = b64.indexOf(data.charAt(i++));\r\n-\r\n-\t\t\t\tbits = h1 << 18 | h2 << 12 | h3 << 6 | h4;\r\n-\r\n-\t\t\t\to1 = bits >> 16 & 0xff;\r\n-\t\t\t\to2 = bits >> 8 & 0xff;\r\n-\t\t\t\to3 = bits & 0xff;\r\n-\r\n-\t\t\t\tif (h3 == 64) {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1);\r\n-\t\t\t\t} else if (h4 == 64) {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1, o2);\r\n-\t\t\t\t} else {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1, o2, o3);\r\n-\t\t\t\t}\r\n-\t\t\t} while (i < data.length);\r\n-\r\n-\t\t\tdec = tmp_arr.join(\'\');\r\n-\r\n-\t\t\treturn dec;\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Array.prototype.map) {\r\n-\t\tArray.prototype.map = function(fun /*, thisArg */) {\r\n-\t\t\tif (this === void 0 || this === null || typeof fun !== "function")\r\n-\t\t\t\tthrow new TypeError();\r\n-\r\n-\t\t\tvar t = Object(this), len = t.length >>> 0, res = new Array(len);\r\n-\t\t\tvar thisArg = arguments.length > 1 ? arguments[1] : void 0;\r\n-\t\t\tfor (var i = 0; i < len; i++) {\r\n-\t\t\t\t// NOTE: Absolute correctness would demand Object.defineProperty\r\n-\t\t\t\t//       be used.  But this method is fairly new, and failure is\r\n-\t\t\t\t//       possible only if Object.prototype or Array.prototype\r\n-\t\t\t\t//       has a property |i| (very unlikely), so use a less-correct\r\n-\t\t\t\t//       but more portable alternative.\r\n-\t\t\t\tif (i in t)\r\n-\t\t\t\t\tres[i] = fun.call(thisArg, t[i], i, t);\r\n-\t\t\t}\r\n-\r\n-\t\t\treturn res;\r\n-\t\t};\r\n-\t}\r\n-\r\n-\r\n-\tif(!Array.isArray) {\r\n-\t\tArray.isArray = function(arg) {\r\n-\t\t\treturn Object.prototype.toString.call(arg) === \'[object Array]\';\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Array.prototype.forEach) {\r\n-\t\tArray.prototype.forEach = function(fun, thisArg) {\r\n-\t\t\t"use strict";\r\n-\r\n-\t\t\tif (this === void 0 || this === null || typeof fun !== "function")\r\n-\t\t\t\tthrow new TypeError();\r\n-\r\n-\t\t\tvar t = Object(this), len = t.length >>> 0;\r\n-\t\t\tfor (var i = 0; i < len; i++) {\r\n-\t\t\t\tif (i in t)\r\n-\t\t\t\t\tfun.call(thisArg, t[i], i, t);\r\n-\t\t\t}\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Object.keys) {\r\n-\t\tObject.keys = (function () {\r\n-\t\t\t\'use strict\';\r\n-\r\n-\t\t\tvar hasOwnProperty = Object.prototype.hasOwnProperty,\r\n-\t\t\t\thasDontEnumBug = !({toString: null}).propertyIsEnumerable(\'toString\'),\r\n-\t\t\t\tdontEnums = [\'toString\',\'toLocaleString\',\'valueOf\',\'hasOwnProperty\',\r\n-\t\t\t\t\t\'isPrototypeOf\',\'propertyIsEnumerable\',\'constructor\'],\r\n-\t\t\t\tdontEnumsLength = dontEnums.length;\r\n-\r\n-\t\t\treturn function (obj) {\r\n-\t\t\t\tif (typeof obj !== \'object\' && (typeof obj !== \'function\' || obj === null)) {\r\n-\t\t\t\t\tthrow new TypeError();\r\n-\t\t\t\t}\r\n-\t\t\t\tvar result = [], prop, i;\r\n-\r\n-\t\t\t\tfor (prop in obj) {\r\n-\t\t\t\t\tif (hasOwnProperty.call(obj, prop)) {\r\n-\t\t\t\t\t\tresult.push(prop);\r\n-\t\t\t\t\t}\r\n-\t\t\t\t}\r\n-\r\n-\t\t\t\tif (hasDontEnumBug) {\r\n-\t\t\t\t\tfor (i = 0; i < dontEnumsLength; i++) {\r\n-\t\t\t\t\t\tif (hasOwnProperty.call(obj, dontEnums[i])) {\r\n-\t\t\t\t\t\t\tresult.push(dontEnums[i]);\r\n-\t\t\t\t\t\t}\r\n-\t\t\t\t\t}\r\n-\t\t\t\t}\r\n-\t\t\t\treturn result;\r\n-\t\t\t};\r\n-\t\t}());\r\n-\t}\r\n-\r\n-\tif (!String.prototype.trim) {\r\n-\t\tString.prototype.trim = function () {\r\n-\t\t\treturn this.replace(/^\\s+|\\s+$/g, \'\');\r\n-\t\t};\r\n-\t}\r\n-\tif (!String.prototype.trimLeft) {\r\n-\t\tString.prototype.trimLeft = function() {\r\n-\t\t\treturn this.replace(/^\\s+/g, "");\r\n-\t\t};\r\n-\t}\r\n-\tif (!String.prototype.trimRight) {\r\n-\t\tString.prototype.trimRight = function() {\r\n-\t\t\treturn this.replace(/\\s+$/g, "");\r\n-\t\t};\r\n-\t}\r\n-\r\n-})(typeof self !== "undefined" && self || typeof window !== "undefined" && window || this);\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/lib/z-worker.js
--- a/MDAheatmap/static/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/static/javascript/lib/zip.js
--- a/MDAheatmap/static/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/templates/MDAheatmap.mako
--- a/MDAheatmap/templates/MDAheatmap.mako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,145 +0,0 @@\n-<HTML>\r\n-   <HEAD>\r\n-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserHelpManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserPreferenceManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/PdfGenerator.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/jspdf.debug.js"></script>\r\n- \t <script src="/plugins/visualizations/MDAheatmap/static/javascript/custom.js"></script>\r\n-\r\n-\t <meta id=\'viewport\' name ="viewport" content="">\r\n-\r\n-   </HEAD>\r\n-   \r\n-   <BODY onresize="chmResize()">\r\n-    <%\r\n-       from galaxy import model\r\n-       users_current_history = trans.history\r\n-       url_dict = { }\r\n-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]\r\n-       output_datasets = hda.creating_job.output_datasets\r\n-       for o in output_datasets:\r\n-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )\r\n-    %>\r\n-\r\n-    <script>\r\n-       heatMap = null;  //global - heatmap object.\r\n- \t  staticPath = "/plugins/visualizations/MDAheatmap/static/"; //path for static web content - changes in galaxy.\r\n-\r\n-       var url_dict = ${ h.dumps( url_dict ) };\r\n-       var hdaId   = \'${trans.security.encode_id( hda.id )}\';\r\n-       var hdaExt  = \'${hda.ext}\';\r\n-       var ajaxUrl = "${h.url_for( controller=\'/datasets\', action=\'index\')}/" + hdaId + "/display?to_ext=" + hdaExt;\r\n-\r\n-       var xmlhttp=new XMLHttpRequest();\r\n-       xmlhttp.open("GET", ajaxUrl, true);\r\n-       xmlhttp.responseType = \'blob\';\r\n-       xmlhttp.onload = function(e) {\r\n-           if (this.status == 200) {\r\n-               var blob = new Blob([this.response], {type: \'compress/zip\'});\r\n-               zip.useWebWorkers = false;\r\n-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);\r\n-               var name = this.getResponseHeader("Content-Disposition");\r\n-               if (name.indexOf(\'[\') > -1) {\r\n-                 name = name.substring(name.indexOf(\'[\')+1, name.indexOf(\']\'));\r\n-               }               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);\r\n-               heatMap.addEventListener(processDetailMapUpdate);\r\n-               initSummaryDisplay();\r\n-               initDetailDisplay()\r\n-           }\r\n-       };\r\n-       xmlhttp.send();\r\n-\r\n-       function chmResize() {\r\n-          detailResize();\r\n-       }\r\n-\r\n-    </script>\r\n-\r\n-    <div class="mdaServiceHeader">\r\n-        <div class="mdaServiceHeaderLogo">\r\n-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">\r\n-        </div>\r\n-      \r\n-\t   <div id=\'detail_buttons\' align="center" style="display:none">\r\n- \t\t    <img id=\'zoomOut_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/zoom-out.png\' alt=\'Zoom Out\' onmouseover=\'detailDataToolHelp(this,"Zoom Out")\' onclick=\'detailDataZoomOut();\'   align="top"   />\r\n-\t\t    <img id=\'zoomIn_btn\' src=\'/plugins/visualizati'..b'MDAheatmap/static/images/prev.png\' alt=\'Previous\' onmouseover=\'userHelpClose();\' style="display:none;" onclick=\'searchPrev();\'  align="top"  />\r\n-\t\t    <img id=\'next_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/next.png\' alt=\'Next\' onmouseover=\'userHelpClose();\' style="display:none;" onclick=\'searchNext();\'  align="top"  />\r\n-\t\t    <img id=\'cancel_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/cancel.png\' alt=\'Cancel\' onmouseover=\'detailDataToolHelp(this,"Clear current search")\' style="display:none;" onclick=\'clearSearch();\'  align="top"  />\r\n-\t\t    <img id=\'pdf_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/pdf.png\' alt=\'go\' onmouseover=\'detailDataToolHelp(this,"Save as PDF")\' onclick=\'openPdfPrefs(this,null);\'  align="top" style="position: absolute; right: 60;"  />\r\n- \t    \t    <img id=\'gear_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/gear.png\' alt=\'Modify Map\' onmouseover=\'detailDataToolHelp(this,"Modify Map Preferences")\' onclick=\'editPreferences(this,null);\' align="top" style="position: absolute; right: 30;"  />\r\n-       </div>\r\n-    </div>\r\n-\r\n-    <div id="container">\r\n-\r\n-       <div id=\'summary_chm\' style=\'position: relative;\'>\r\n-          <canvas id=\'summary_canvas\'></canvas>\r\n-\t\t<div id=\'sumlabelDiv\' style="display: inline-block"></div>\r\n-       </div>\r\n-\r\n-\t  <div id= \'divider\' style=\'position: relative;\' onmousedown="dividerStart()" ontouchstart="dividerStart()">\r\n-\t  </div>\r\n-\r\n-       <div id=\'detail_chm\' style=\'position: relative;\'>\r\n-          <canvas id=\'detail_canvas\' style=\'display: inline-block\'></canvas>\r\n-          <div id=\'labelDiv\' style="display: inline-block"></div>\r\n-       </div>\r\n-   </div>\r\n-\r\n-\t<div id="pdfPrefsPanel" style="display: none; position: absolute; background-color: rgb(203, 219, 246);">\r\n-\t\t<div class="prefsHeader" id="pdfPrefsHeader">PDF Generation</div>\r\n-\t\t<table>\r\n-\t\t\t<tbody>\r\n-\t\t\t\t<tr>\r\n-\t\t\t\t\t<td>\r\n-\t\t\t\t\t\t<div id="pdfprefprefs" style="display: block; background-color: rgb(203, 219, 246);">\r\n-\t\t\t\t\t\t\t<div style="display: inherit; width: 220px; height: 220px;">\r\n-\t\t\t\t\t\t\t\t<h3 style="margin-bottom:0px;">Show maps:</h3>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputSummaryMap" type="radio" name="pages" value="summary"> Summary<br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputDetailMap" type="radio" name="pages" value="detail"> Detail<br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputBothMaps" type="radio" name="pages" value="both" checked> Both<br><br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputPages" type="checkbox" name="pages" value="separate"> Show maps on separate pages<br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputPortrait" type="radio" name="orientation" value="portrait"> Portrait \r\n-\t\t\t\t\t\t\t\t<input id="pdfInputLandscape" type="radio" name="orientation" value="Landscape" checked> Landscape <br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<h3 style="margin-bottom:0px;">Show classification bars:</h3>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputCondensed" type="radio" name="condensed" value="condensed"> Condensed \r\n-\t\t\t\t\t\t\t\t<input id="pdfInputHistogram" type="radio" name="condensed" value="histogram" checked> Histogram <br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputColumn" type="checkbox" name="class" value="row" checked> Column<br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputRow" type="checkbox" name="class" value="column" checked> Row\r\n-\t\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t\t\t<table>\r\n-\t\t\t\t\t\t\t\t<tbody>\r\n-\t\t\t\t\t\t\t\t\t<tr>\r\n-\t\t\t\t\t\t\t\t\t\t<td style="font-weight: bold;">\r\n-\t\t\t\t\t\t\t\t\t\t\t<div id="pref_buttons" align="right">\r\n-\t\t\t\t\t\t\t\t\t\t\t\t<img id="prefCancel_btn" src="/plugins/visualizations/MDAheatmap/static/images/prefCancel.png" alt="Cancel changes" onclick="pdfCancelButton();" align="top">&nbsp;&nbsp;\r\n-\t\t\t\t\t\t\t\t\t\t\t\t<img id="prefCreate_btn" src="/plugins/visualizations/MDAheatmap/static/images/createPdf.png" alt="Create PDF" onclick="getPDF();" align="top">\r\n-\t\t\t\t\t\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t\t\t\t\t\t</td>\r\n-\t\t\t\t\t\t\t\t\t</tr>\r\n-\t\t\t\t\t\t\t\t</tbody>\r\n-\t\t\t\t\t\t\t</table>\r\n-\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t</td>\r\n-\t\t\t\t</tr>\r\n-\t\t\t</tbody>\r\n-\t\t</table>\r\n-\t</div>\r\n-</BODY >\r\n-</HTML>\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b MDAheatmap/templates/MDAheatmap.oldmako
--- a/MDAheatmap/templates/MDAheatmap.oldmako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,98 +0,0 @@
-<HTML>
-   <HEAD>
-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserHelpManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserPreferenceManager.js"></script>
-
- <meta id='viewport' name ="viewport" content="">
-
-   </HEAD>
-   
-   <BODY onresize="chmResize()">
-    <%
-       from galaxy import model
-       users_current_history = trans.history
-       url_dict = { }
-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]
-       output_datasets = hda.creating_job.output_datasets
-       for o in output_datasets:
-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )
-    %>
-
-    <script>
-       heatMap = null;  //global - heatmap object.
-
-       var url_dict = ${ h.dumps( url_dict ) };
-       var hdaId   = '${trans.security.encode_id( hda.id )}';
-       var hdaExt  = '${hda.ext}';
-       var ajaxUrl = "${h.url_for( controller='/datasets', action='index')}/" + hdaId + "/display?to_ext=" + hdaExt;
-
-       var xmlhttp=new XMLHttpRequest();
-       xmlhttp.open("GET", ajaxUrl, true);
-       xmlhttp.responseType = 'blob';
-       xmlhttp.onload = function(e) {
-           if (this.status == 200) {
-               var blob = new Blob([this.response], {type: 'compress/zip'});
-               zip.useWebWorkers = false;
-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);
-               var name = 'NGCHM';
-               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);
-               heatMap.addEventListener(processDetailMapUpdate);
-               initSummaryDisplay();
-               initDetailDisplay()
-           }
-       };
-       xmlhttp.send();
-
-       function chmResize() {
-          detailResize();
-       }
-
-    </script>
-
-    <div class="mdaServiceHeader">
-        <div class="mdaServiceHeaderLogo">
-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">
-        </div>
-      
-        <div id='detail_buttons' align="center" style="display:none">
-  <img id='zoomOut_btn' src='/plugins/visualizations/MDAheatmap/static/images/zoom-out.png' alt='Zoom Out' onmouseover='detailDataToolHelp(this,"Zoom Out")' onclick='detailDataZoomOut();'   align="top"   />
-     <img id='zoomIn_btn' src='/plugins/visualizations/MDAheatmap/static/images/zoom-in.png' alt='Zoom In' onmouseover='detailDataToolHelp(this,"Zoom In")' onclick='detailDataZoomIn();' align="top"   />
-     <img id='full_btn' src='/plugins/visualizations/MDAheatmap/static/images/full_selected.png' alt='Full' onmouseover='detailDataToolHelp(this,"Normal View")' onclick='detailNormal();' align="top"   />
-     <img id='ribbonH_btn' src='/plugins/visualizations/MDAheatmap/static/images/ribbonH.png' alt='Ribbon H' onmouseover='detailDataToolHelp(this,"Horizontal Ribbon View")' onclick='detailHRibbonButton();' align="top"  />
-     <img id='ribbonV_btn' src='/plugins/visualizations/MDAheatmap/static/images/ribbonV.png' alt='Ribbon V' onmouseover='detailDataToolHelp(this,"Vertical Ribbon View")' onclick='detailVRibbonButton();'  align="top"  />
-    <span style='display: inline-block;'><b>Search: </b><input type="text" id="search_text" name="search" onkeypress='clearSrchBtns();' onchange='detailSearch();'
-                                                         onmouseover='detailDataToolHelp(this,"Search Row/Column Labels. Separate search terms with spaces or commas. Use * for wild card matching. Hit enter or Go to run the search. If the search box turns red none of the search terms were found. If it turns yellow only some of the search terms were found.", 200)' ></span>
-     <img id='go_btn' src='/plugins/visualizations/MDAheatmap/static/images/go.png' alt='Go' onmouseover='detailDataToolHelp(this,"Search Row/Column Labels")'  onclick='detailSearch();' align="top"  />
-     <img id='prev_btn' src='/plugins/visualizations/MDAheatmap/static/images/prev.png' alt='Previous' onmouseover='userHelpClose();' style="display:none;" onclick='searchPrev();'  align="top"  />
-     <img id='next_btn' src='/plugins/visualizations/MDAheatmap/static/images/next.png' alt='Next' onmouseover='userHelpClose();' style="display:none;" onclick='searchNext();'  align="top"  />
-     <img id='cancel_btn' src='/plugins/visualizations/MDAheatmap/static/images/cancel.png' alt='Cancel' onmouseover='detailDataToolHelp(this,"Clear current search")' style="display:none;" onclick='clearSearch();'  align="top"  />
-       </div>
-    </div>
-
-    <div id="container">
-
-       <div id='summary_chm' style='position: relative;'>
-          <canvas id='summary_canvas'></canvas>
- <div id='sumlabelDiv' style="display: inline-block"></div>
-       </div>
-
-   <div id= 'divider' style='position: relative;' onmousedown="dividerStart()" ontouchstart="dividerStart()">
-   </div>
-
-       <div id='detail_chm' style='position: relative;'>
-          <canvas id='detail_canvas' style='display: inline-block'></canvas>
-          <div id='labelDiv' style="display: inline-block"></div>
-       </div>
-   </div>
-
-</BODY >
-</HTML>
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b NGCHMheatmap.xml
--- a/NGCHMheatmap.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,84 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<tool id="NGCHMheatmap" name="NGCHM Heatmap" version="4.1.2">
-  <description>Create Dynamic Clustered HeatMap from Matrix and Covariate files</description>
-<command>$GALAXY_ROOT_DIR/tools/MDA_Heatmaps/heatmap.sh  '$hmname' '$hmdesc' '$inputmatrix' $rowOrderMethod $rowDistanceMeasure $rowAgglomerationMethod $columnOrderMethod $columnDistanceMeasure $columnAgglomerationMethod '$summarymethod' '$GALAXY_ROOT_DIR/tools/MDA_Heatmaps/'
-    #for $op in $operations
-       ${op.class_name}
-       ${op.repeatinput.file_name}
-       ${op.cat}
-      #end for
-  '$output' 
- </command>
- <stdio>
-      <exit_code range="1:" level="fatal" />
- </stdio>
-  <inputs>
-    <param name="inputmatrix" type="data" label="Input Matrix" />
-    <param name="hmname" size="20" type="text" value="HM_name" label="User Defined HeatMap Name"/>
-    <param name="hmdesc" size="100" optional="true" type="text" value="_" label="Optional HeatMap Description"/>
-    <param name="summarymethod"  type="select"  label="Data Summarization Method">
- <option value="average">average</option>
- <option value="sample">sample</option>
- <option value="mode">mode</option>
-    </param>
- <param name="rowOrderMethod" type="select" label="Row ordering method" help="Choices -- Hierarchical Clustering, Original Order, Random">
- <option value="Hierarchical">Hierarchical Clustering</option>
- <option value="Original">Original Order</option>     
- <option value="Random">Random</option>     
- </param>
- <param name="rowDistanceMeasure" type="select"  label="Row Distance Metric" help="euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation">
- <option value="euclidean">Euclidean</option>
- <option value="binary">Binary</option>
- <option value="manhattan">Manhattan</option>
- <option value="maximum">Maximum</option>
- <option value="canberra">Canberra</option>     
- <option value="minkowski">Minkowski</option>     
- <option value="correlation">Correlation</option>     
- </param>
- <param name="rowAgglomerationMethod" type="select"  label="Row Clustering Method" help="Choices: 'average' for Average Linkage, 'complete' for Complete Linkage, 'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.">
- <option value="average">Average Linkage</option>
- <option value="complete">Complete Linkage</option>
- <option value="single">Single Linkage</option>
- <option value="ward">Ward</option>
- <option value="mcquitty">Mcquitty</option>     
- <option value="median">Median</option>     
- <option value="centroid">Centroid</option>     
- </param>
- <param name="columnOrderMethod" type="select" label="Column ordering method" help="Choices -- Hierarchical Clustering, Original Order, Random">
- <option value="Hierarchical">Hierarchical Clustering</option>
- <option value="Original">Original Order</option>     
- <option value="Random">Random</option>     
- </param>
- <param name="columnDistanceMeasure" type="select"  label="Column Distance Metric" help="euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation">
- <option value="euclidean">Euclidean</option>
- <option value="binary">Binary</option>
- <option value="manhattan">Manhattan</option>
- <option value="maximum">Maximum</option>
- <option value="canberra">Canberra</option>     
- <option value="minkowski">Minkowski</option>     
- <option value="correlation">Correlation</option>     
- </param>
- <param name="columnAgglomerationMethod" type="select"  label="Column Clustering Method" help="Choices: 'average' for Average Linkage, 'complete' for Complete Linkage, 'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.">
- <option value="average">Average Linkage</option>
- <option value="complete">Complete Linkage</option>
- <option value="single">Single Linkage</option>
- <option value="ward">Ward</option>
- <option value="mcquitty">Mcquitty</option>     
- <option value="median">Median</option>     
- <option value="centroid">Centroid</option>     
- </param>
-    <repeat name="operations" title="Covariate Bars">
-        <param name="class_name" size="20" type="text" value="" label="Axis Covariate Name"/>
-        <param name="repeatinput" type="data" format="text" label="Axis Covariate File"/>        
- <param name="cat" type="select" label="Axis Covariate Type">
-   <option value="row_categorical" >row categorical</option>
-   <option value="row_continuous" >row continuous</option>
-   <option value="column_categorical" >column categorical</option>
-   <option value="column_continuous" >column continuous</option>
- </param>
-    </repeat>       
-  </inputs>
-  <outputs>
-    <data name="output" label='${hmname}' format="zip"/>
-  </outputs>
-</tool>
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/._400x400-column-covariate.txt
b
Binary file TestFiles/._400x400-column-covariate.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/._400x400-row-covariate.txt
b
Binary file TestFiles/._400x400-row-covariate.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/._400x400.txt
b
Binary file TestFiles/._400x400.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/._Galaxy400x400-noCovariates.ngchm
b
Binary file TestFiles/._Galaxy400x400-noCovariates.ngchm has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/400x400-column-covariate.txt
--- a/TestFiles/400x400-column-covariate.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,1 +0,0 @@\n-TCGA_SAMP_1\t1111\rTCGA_SAMP_2\t1111\rTCGA_SAMP_3\t1111\rTCGA_SAMP_4\t1111\rTCGA_SAMP_5\t1111\rTCGA_SAMP_6\t1111\rTCGA_SAMP_7\t1111\rTCGA_SAMP_8\t1111\rTCGA_SAMP_9\t1111\rTCGA_SAMP_10\t1111\rTCGA_SAMP_11\t1111\rTCGA_SAMP_12\t1111\rTCGA_SAMP_13\t1111\rTCGA_SAMP_14\t1111\rTCGA_SAMP_15\t1111\rTCGA_SAMP_16\t1111\rTCGA_SAMP_17\t1111\rTCGA_SAMP_18\t1111\rTCGA_SAMP_19\t1111\rTCGA_SAMP_20\t1111\rTCGA_SAMP_21\t1111\rTCGA_SAMP_22\t22\rTCGA_SAMP_23\t22\rTCGA_SAMP_24\t22\rTCGA_SAMP_25\t22\rTCGA_SAMP_26\t22\rTCGA_SAMP_27\t22\rTCGA_SAMP_28\t22\rTCGA_SAMP_29\t22\rTCGA_SAMP_30\t22\rTCGA_SAMP_31\t22\rTCGA_SAMP_32\t22\rTCGA_SAMP_33\t22\rTCGA_SAMP_34\t22\rTCGA_SAMP_35\t22\rTCGA_SAMP_36\t22\rTCGA_SAMP_37\t333\rTCGA_SAMP_38\t333\rTCGA_SAMP_39\t333\rTCGA_SAMP_40\t333\rTCGA_SAMP_41\t333\rTCGA_SAMP_42\t333\rTCGA_SAMP_43\t333\rTCGA_SAMP_44\t333\rTCGA_SAMP_45\t333\rTCGA_SAMP_46\t333\rTCGA_SAMP_47\t333\rTCGA_SAMP_48\t333\rTCGA_SAMP_49\t333\rTCGA_SAMP_50\t333\rTCGA_SAMP_51\t1111\rTCGA_SAMP_52\t1111\rTCGA_SAMP_53\t1111\rTCGA_SAMP_54\t1111\rTCGA_SAMP_55\t1111\rTCGA_SAMP_56\t1111\rTCGA_SAMP_57\t1111\rTCGA_SAMP_58\t1111\rTCGA_SAMP_59\t1111\rTCGA_SAMP_60\t1111\rTCGA_SAMP_61\t1111\rTCGA_SAMP_62\t1111\rTCGA_SAMP_63\t1111\rTCGA_SAMP_64\t1111\rTCGA_SAMP_65\t1111\rTCGA_SAMP_66\t1111\rTCGA_SAMP_67\t1111\rTCGA_SAMP_68\t1111\rTCGA_SAMP_69\t1111\rTCGA_SAMP_70\t1111\rTCGA_SAMP_71\t1111\rTCGA_SAMP_72\t22\rTCGA_SAMP_73\t22\rTCGA_SAMP_74\t22\rTCGA_SAMP_75\t22\rTCGA_SAMP_76\t22\rTCGA_SAMP_77\t22\rTCGA_SAMP_78\t22\rTCGA_SAMP_79\t22\rTCGA_SAMP_80\t22\rTCGA_SAMP_81\t22\rTCGA_SAMP_82\t22\rTCGA_SAMP_83\t22\rTCGA_SAMP_84\t22\rTCGA_SAMP_85\t22\rTCGA_SAMP_86\t22\rTCGA_SAMP_87\t333\rTCGA_SAMP_88\t333\rTCGA_SAMP_89\t333\rTCGA_SAMP_90\t333\rTCGA_SAMP_91\t333\rTCGA_SAMP_92\t333\rTCGA_SAMP_93\t333\rTCGA_SAMP_94\t333\rTCGA_SAMP_95\t333\rTCGA_SAMP_96\t333\rTCGA_SAMP_97\t333\rTCGA_SAMP_98\t333\rTCGA_SAMP_99\t333\rTCGA_SAMP_100\t333\rTCGA_SAMP_101\t1111\rTCGA_SAMP_102\t1111\rTCGA_SAMP_103\t1111\rTCGA_SAMP_104\t1111\rTCGA_SAMP_105\t1111\rTCGA_SAMP_106\t1111\rTCGA_SAMP_107\t1111\rTCGA_SAMP_108\t1111\rTCGA_SAMP_109\t1111\rTCGA_SAMP_110\t1111\rTCGA_SAMP_111\t1111\rTCGA_SAMP_112\t1111\rTCGA_SAMP_113\t1111\rTCGA_SAMP_114\t1111\rTCGA_SAMP_115\t1111\rTCGA_SAMP_116\t1111\rTCGA_SAMP_117\t1111\rTCGA_SAMP_118\t1111\rTCGA_SAMP_119\t1111\rTCGA_SAMP_120\t1111\rTCGA_SAMP_121\t1111\rTCGA_SAMP_122\t22\rTCGA_SAMP_123\t22\rTCGA_SAMP_124\t22\rTCGA_SAMP_125\t22\rTCGA_SAMP_126\t22\rTCGA_SAMP_127\t22\rTCGA_SAMP_128\t22\rTCGA_SAMP_129\t22\rTCGA_SAMP_130\t22\rTCGA_SAMP_131\t22\rTCGA_SAMP_132\t22\rTCGA_SAMP_133\t22\rTCGA_SAMP_134\t22\rTCGA_SAMP_135\t22\rTCGA_SAMP_136\t22\rTCGA_SAMP_137\t333\rTCGA_SAMP_138\t333\rTCGA_SAMP_139\t333\rTCGA_SAMP_140\t333\rTCGA_SAMP_141\t333\rTCGA_SAMP_142\t333\rTCGA_SAMP_143\t333\rTCGA_SAMP_144\t333\rTCGA_SAMP_145\t333\rTCGA_SAMP_146\t333\rTCGA_SAMP_147\t333\rTCGA_SAMP_148\t333\rTCGA_SAMP_149\t333\rTCGA_SAMP_150\t333\rTCGA_SAMP_151\t1111\rTCGA_SAMP_152\t1111\rTCGA_SAMP_153\t1111\rTCGA_SAMP_154\t1111\rTCGA_SAMP_155\t1111\rTCGA_SAMP_156\t1111\rTCGA_SAMP_157\t1111\rTCGA_SAMP_158\t1111\rTCGA_SAMP_159\t1111\rTCGA_SAMP_160\t1111\rTCGA_SAMP_161\t1111\rTCGA_SAMP_162\t1111\rTCGA_SAMP_163\t1111\rTCGA_SAMP_164\t1111\rTCGA_SAMP_165\t1111\rTCGA_SAMP_166\t1111\rTCGA_SAMP_167\t1111\rTCGA_SAMP_168\t1111\rTCGA_SAMP_169\t1111\rTCGA_SAMP_170\t1111\rTCGA_SAMP_171\t1111\rTCGA_SAMP_172\t22\rTCGA_SAMP_173\t22\rTCGA_SAMP_174\t22\rTCGA_SAMP_175\t22\rTCGA_SAMP_176\t22\rTCGA_SAMP_177\t22\rTCGA_SAMP_178\t22\rTCGA_SAMP_179\t22\rTCGA_SAMP_180\t22\rTCGA_SAMP_181\t22\rTCGA_SAMP_182\t22\rTCGA_SAMP_183\t22\rTCGA_SAMP_184\t22\rTCGA_SAMP_185\t22\rTCGA_SAMP_186\t22\rTCGA_SAMP_187\t333\rTCGA_SAMP_188\t333\rTCGA_SAMP_189\t333\rTCGA_SAMP_190\t333\rTCGA_SAMP_191\t333\rTCGA_SAMP_192\t333\rTCGA_SAMP_193\t333\rTCGA_SAMP_194\t333\rTCGA_SAMP_195\t333\rTCGA_SAMP_196\t333\rTCGA_SAMP_197\t333\rTCGA_SAMP_198\t333\rTCGA_SAMP_199\t333\rTCGA_SAMP_200\t333\rTCGA_SAMP_201\t1111\rTCGA_SAMP_202\t1111\rTCGA_SAMP_203\t1111\rTCGA_SAMP_204\t1111\rTCGA_SAMP_205\t1111\rTCGA_SAMP_206\t1111\rTCGA_SAMP_207\t1111\rTCGA_SAMP_208\t1111\rTCGA_SAMP_209\t1111\rTCGA_SAMP_210\t1111\rTCGA_SAMP_211\t1111\rTCGA_SAMP_212\t1111\rTCGA_SAMP_213\t1111\rTCGA_SAMP_214\t1111\rTCGA_SAMP_215\t1111\rTCGA_SAMP_216\t1111\rTCGA_SAMP_217\t1111\rTCGA_SAMP_218\t1111\rTCGA_SAMP_219\t1111\rTCGA_SAMP_220\t1111\rTCGA_SAMP_221\t1111\rTCGA_SAMP_222\t22\rTCGA_SAMP_223\t22\rTCGA_SAMP_224\t22\rTCGA_SAMP_225\t22'..b'\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/400x400-row-covariate.txt
--- a/TestFiles/400x400-row-covariate.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-Gene_1 aaa Gene_2 aaa Gene_3 aaa Gene_4 aaa Gene_5 aaa Gene_6 aaa Gene_7 bb Gene_8 bb Gene_9 bb Gene_10 bb Gene_11 bb Gene_12 bb Gene_13 bb Gene_14 bb Gene_15 bb Gene_16 bb Gene_17 bb Gene_18 bb Gene_19 bb Gene_20 bb Gene_21 bb Gene_22 bb Gene_23 bb Gene_24 bb Gene_25 bb Gene_26 bb Gene_27 bb Gene_28 bb Gene_29 bb Gene_30 bb Gene_31 bb Gene_32 cccc Gene_33 cccc Gene_34 cccc Gene_35 cccc Gene_36 cccc Gene_37 cccc Gene_38 cccc Gene_39 cccc Gene_40 cccc Gene_41 cccc Gene_42 cccc Gene_43 cccc Gene_44 cccc Gene_45 cccc Gene_46 cccc Gene_47 cccc Gene_48 cccc Gene_49 aaa Gene_50 aaa Gene_51 aaa Gene_52 aaa Gene_53 aaa Gene_54 aaa Gene_55 bb Gene_56 bb Gene_57 aaa Gene_58 aaa Gene_59 aaa Gene_60 aaa Gene_61 aaa Gene_62 aaa Gene_63 bb Gene_64 bb Gene_65 bb Gene_66 bb Gene_67 bb Gene_68 bb Gene_69 bb Gene_70 bb Gene_71 bb Gene_72 bb Gene_73 bb Gene_74 bb Gene_75 bb Gene_76 bb Gene_77 bb Gene_78 bb Gene_79 bb Gene_80 bb Gene_81 bb Gene_82 bb Gene_83 bb Gene_84 bb Gene_85 bb Gene_86 bb Gene_87 bb Gene_88 cccc Gene_89 cccc Gene_90 cccc Gene_91 cccc Gene_92 cccc Gene_93 cccc Gene_94 cccc Gene_95 cccc Gene_96 cccc Gene_97 cccc Gene_98 cccc Gene_99 cccc Gene_100 cccc Gene_101 cccc Gene_102 cccc Gene_103 cccc Gene_104 cccc Gene_105 aaa Gene_106 aaa Gene_107 aaa Gene_108 aaa Gene_109 aaa Gene_110 aaa Gene_111 bb Gene_112 bb Gene_113 aaa Gene_114 aaa Gene_115 aaa Gene_116 aaa Gene_117 aaa Gene_118 aaa Gene_119 bb Gene_120 bb Gene_121 bb Gene_122 bb Gene_123 bb Gene_124 bb Gene_125 bb Gene_126 bb Gene_127 bb Gene_128 bb Gene_129 bb Gene_130 bb Gene_131 bb Gene_132 bb Gene_133 bb Gene_134 bb Gene_135 bb Gene_136 bb Gene_137 bb Gene_138 bb Gene_139 bb Gene_140 bb Gene_141 bb Gene_142 bb Gene_143 bb Gene_144 cccc Gene_145 cccc Gene_146 cccc Gene_147 cccc Gene_148 cccc Gene_149 cccc Gene_150 cccc Gene_151 cccc Gene_152 cccc Gene_153 cccc Gene_154 cccc Gene_155 cccc Gene_156 cccc Gene_157 cccc Gene_158 cccc Gene_159 cccc Gene_160 cccc Gene_161 aaa Gene_162 aaa Gene_163 aaa Gene_164 aaa Gene_165 aaa Gene_166 aaa Gene_167 bb Gene_168 bb Gene_169 aaa Gene_170 aaa Gene_171 aaa Gene_172 aaa Gene_173 aaa Gene_174 aaa Gene_175 bb Gene_176 bb Gene_177 bb Gene_178 bb Gene_179 bb Gene_180 bb Gene_181 bb Gene_182 bb Gene_183 bb Gene_184 bb Gene_185 bb Gene_186 bb Gene_187 bb Gene_188 bb Gene_189 bb Gene_190 bb Gene_191 bb Gene_192 bb Gene_193 bb Gene_194 bb Gene_195 bb Gene_196 bb Gene_197 bb Gene_198 bb Gene_199 bb Gene_200 cccc Gene_201 cccc Gene_202 cccc Gene_203 cccc Gene_204 cccc Gene_205 cccc Gene_206 cccc Gene_207 cccc Gene_208 cccc Gene_209 cccc Gene_210 cccc Gene_211 cccc Gene_212 cccc Gene_213 cccc Gene_214 cccc Gene_215 cccc Gene_216 cccc Gene_217 aaa Gene_218 aaa Gene_219 aaa Gene_220 aaa Gene_221 aaa Gene_222 aaa Gene_223 bb Gene_224 bb Gene_225 aaa Gene_226 aaa Gene_227 aaa Gene_228 aaa Gene_229 aaa Gene_230 aaa Gene_231 bb Gene_232 bb Gene_233 bb Gene_234 bb Gene_235 bb Gene_236 bb Gene_237 bb Gene_238 bb Gene_239 bb Gene_240 bb Gene_241 bb Gene_242 bb Gene_243 bb Gene_244 bb Gene_245 bb Gene_246 bb Gene_247 bb Gene_248 bb Gene_249 bb Gene_250 bb Gene_251 bb Gene_252 bb Gene_253 bb Gene_254 bb Gene_255 bb Gene_256 cccc Gene_257 cccc Gene_258 cccc Gene_259 cccc Gene_260 cccc Gene_261 cccc Gene_262 cccc Gene_263 cccc Gene_264 cccc Gene_265 cccc Gene_266 cccc Gene_267 cccc Gene_268 cccc Gene_269 cccc Gene_270 cccc Gene_271 cccc Gene_272 cccc Gene_273 aaa Gene_274 aaa Gene_275 aaa Gene_276 aaa Gene_277 aaa Gene_278 aaa Gene_279 bb Gene_280 bb Gene_281 aaa Gene_282 aaa Gene_283 aaa Gene_284 aaa Gene_285 aaa Gene_286 aaa Gene_287 bb Gene_288 bb Gene_289 bb Gene_290 bb Gene_291 bb Gene_292 bb Gene_293 bb Gene_294 bb Gene_295 bb Gene_296 bb Gene_297 bb Gene_298 bb Gene_299 bb Gene_300 bb Gene_301 bb Gene_302 bb Gene_303 bb Gene_304 bb Gene_305 bb Gene_306 bb Gene_307 bb Gene_308 bb Gene_309 bb Gene_310 bb Gene_311 bb Gene_312 cccc Gene_313 cccc Gene_314 cccc Gene_315 cccc Gene_316 cccc Gene_317 cccc Gene_318 cccc Gene_319 cccc Gene_320 cccc Gene_321 cccc Gene_322 cccc Gene_323 cccc Gene_324 cccc Gene_325 cccc Gene_326 cccc Gene_327 cccc Gene_328 cccc Gene_329 aaa Gene_330 aaa Gene_331 aaa Gene_332 aaa Gene_333 aaa Gene_334 aaa Gene_335 bb Gene_336 bb Gene_337 aaa Gene_338 aaa Gene_339 aaa Gene_340 aaa Gene_341 aaa Gene_342 aaa Gene_343 bb Gene_344 bb Gene_345 bb Gene_346 bb Gene_347 bb Gene_348 bb Gene_349 bb Gene_350 bb Gene_351 bb Gene_352 bb Gene_353 bb Gene_354 bb Gene_355 bb Gene_356 bb Gene_357 bb Gene_358 bb Gene_359 bb Gene_360 bb Gene_361 bb Gene_362 bb Gene_363 bb Gene_364 bb Gene_365 bb Gene_366 bb Gene_367 bb Gene_368 cccc Gene_369 cccc Gene_370 cccc Gene_371 cccc Gene_372 cccc Gene_373 cccc Gene_374 cccc Gene_375 cccc Gene_376 cccc Gene_377 cccc Gene_378 cccc Gene_379 cccc Gene_380 cccc Gene_381 cccc Gene_382 cccc Gene_383 cccc Gene_384 cccc Gene_385 aaa Gene_386 aaa Gene_387 aaa Gene_388 aaa Gene_389 aaa Gene_390 aaa Gene_391 bb Gene_392 bb Gene_393 aaa Gene_394 aaa Gene_395 aaa Gene_396 aaa Gene_397 aaa Gene_398 aaa Gene_399 bb Gene_400 bb
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/400x400.txt
--- a/TestFiles/400x400.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,401 +0,0 @@\n-\tTCGA_SAMP_1\tTCGA_SAMP_2\tTCGA_SAMP_3\tTCGA_SAMP_4\tTCGA_SAMP_5\tTCGA_SAMP_6\tTCGA_SAMP_7\tTCGA_SAMP_8\tTCGA_SAMP_9\tTCGA_SAMP_10\tTCGA_SAMP_11\tTCGA_SAMP_12\tTCGA_SAMP_13\tTCGA_SAMP_14\tTCGA_SAMP_15\tTCGA_SAMP_16\tTCGA_SAMP_17\tTCGA_SAMP_18\tTCGA_SAMP_19\tTCGA_SAMP_20\tTCGA_SAMP_21\tTCGA_SAMP_22\tTCGA_SAMP_23\tTCGA_SAMP_24\tTCGA_SAMP_25\tTCGA_SAMP_26\tTCGA_SAMP_27\tTCGA_SAMP_28\tTCGA_SAMP_29\tTCGA_SAMP_30\tTCGA_SAMP_31\tTCGA_SAMP_32\tTCGA_SAMP_33\tTCGA_SAMP_34\tTCGA_SAMP_35\tTCGA_SAMP_36\tTCGA_SAMP_37\tTCGA_SAMP_38\tTCGA_SAMP_39\tTCGA_SAMP_40\tTCGA_SAMP_41\tTCGA_SAMP_42\tTCGA_SAMP_43\tTCGA_SAMP_44\tTCGA_SAMP_45\tTCGA_SAMP_46\tTCGA_SAMP_47\tTCGA_SAMP_48\tTCGA_SAMP_49\tTCGA_SAMP_50\tTCGA_SAMP_51\tTCGA_SAMP_52\tTCGA_SAMP_53\tTCGA_SAMP_54\tTCGA_SAMP_55\tTCGA_SAMP_56\tTCGA_SAMP_57\tTCGA_SAMP_58\tTCGA_SAMP_59\tTCGA_SAMP_60\tTCGA_SAMP_61\tTCGA_SAMP_62\tTCGA_SAMP_63\tTCGA_SAMP_64\tTCGA_SAMP_65\tTCGA_SAMP_66\tTCGA_SAMP_67\tTCGA_SAMP_68\tTCGA_SAMP_69\tTCGA_SAMP_70\tTCGA_SAMP_71\tTCGA_SAMP_72\tTCGA_SAMP_73\tTCGA_SAMP_74\tTCGA_SAMP_75\tTCGA_SAMP_76\tTCGA_SAMP_77\tTCGA_SAMP_78\tTCGA_SAMP_79\tTCGA_SAMP_80\tTCGA_SAMP_81\tTCGA_SAMP_82\tTCGA_SAMP_83\tTCGA_SAMP_84\tTCGA_SAMP_85\tTCGA_SAMP_86\tTCGA_SAMP_87\tTCGA_SAMP_88\tTCGA_SAMP_89\tTCGA_SAMP_90\tTCGA_SAMP_91\tTCGA_SAMP_92\tTCGA_SAMP_93\tTCGA_SAMP_94\tTCGA_SAMP_95\tTCGA_SAMP_96\tTCGA_SAMP_97\tTCGA_SAMP_98\tTCGA_SAMP_99\tTCGA_SAMP_100\tTCGA_SAMP_101\tTCGA_SAMP_102\tTCGA_SAMP_103\tTCGA_SAMP_104\tTCGA_SAMP_105\tTCGA_SAMP_106\tTCGA_SAMP_107\tTCGA_SAMP_108\tTCGA_SAMP_109\tTCGA_SAMP_110\tTCGA_SAMP_111\tTCGA_SAMP_112\tTCGA_SAMP_113\tTCGA_SAMP_114\tTCGA_SAMP_115\tTCGA_SAMP_116\tTCGA_SAMP_117\tTCGA_SAMP_118\tTCGA_SAMP_119\tTCGA_SAMP_120\tTCGA_SAMP_121\tTCGA_SAMP_122\tTCGA_SAMP_123\tTCGA_SAMP_124\tTCGA_SAMP_125\tTCGA_SAMP_126\tTCGA_SAMP_127\tTCGA_SAMP_128\tTCGA_SAMP_129\tTCGA_SAMP_130\tTCGA_SAMP_131\tTCGA_SAMP_132\tTCGA_SAMP_133\tTCGA_SAMP_134\tTCGA_SAMP_135\tTCGA_SAMP_136\tTCGA_SAMP_137\tTCGA_SAMP_138\tTCGA_SAMP_139\tTCGA_SAMP_140\tTCGA_SAMP_141\tTCGA_SAMP_142\tTCGA_SAMP_143\tTCGA_SAMP_144\tTCGA_SAMP_145\tTCGA_SAMP_146\tTCGA_SAMP_147\tTCGA_SAMP_148\tTCGA_SAMP_149\tTCGA_SAMP_150\tTCGA_SAMP_151\tTCGA_SAMP_152\tTCGA_SAMP_153\tTCGA_SAMP_154\tTCGA_SAMP_155\tTCGA_SAMP_156\tTCGA_SAMP_157\tTCGA_SAMP_158\tTCGA_SAMP_159\tTCGA_SAMP_160\tTCGA_SAMP_161\tTCGA_SAMP_162\tTCGA_SAMP_163\tTCGA_SAMP_164\tTCGA_SAMP_165\tTCGA_SAMP_166\tTCGA_SAMP_167\tTCGA_SAMP_168\tTCGA_SAMP_169\tTCGA_SAMP_170\tTCGA_SAMP_171\tTCGA_SAMP_172\tTCGA_SAMP_173\tTCGA_SAMP_174\tTCGA_SAMP_175\tTCGA_SAMP_176\tTCGA_SAMP_177\tTCGA_SAMP_178\tTCGA_SAMP_179\tTCGA_SAMP_180\tTCGA_SAMP_181\tTCGA_SAMP_182\tTCGA_SAMP_183\tTCGA_SAMP_184\tTCGA_SAMP_185\tTCGA_SAMP_186\tTCGA_SAMP_187\tTCGA_SAMP_188\tTCGA_SAMP_189\tTCGA_SAMP_190\tTCGA_SAMP_191\tTCGA_SAMP_192\tTCGA_SAMP_193\tTCGA_SAMP_194\tTCGA_SAMP_195\tTCGA_SAMP_196\tTCGA_SAMP_197\tTCGA_SAMP_198\tTCGA_SAMP_199\tTCGA_SAMP_200\tTCGA_SAMP_201\tTCGA_SAMP_202\tTCGA_SAMP_203\tTCGA_SAMP_204\tTCGA_SAMP_205\tTCGA_SAMP_206\tTCGA_SAMP_207\tTCGA_SAMP_208\tTCGA_SAMP_209\tTCGA_SAMP_210\tTCGA_SAMP_211\tTCGA_SAMP_212\tTCGA_SAMP_213\tTCGA_SAMP_214\tTCGA_SAMP_215\tTCGA_SAMP_216\tTCGA_SAMP_217\tTCGA_SAMP_218\tTCGA_SAMP_219\tTCGA_SAMP_220\tTCGA_SAMP_221\tTCGA_SAMP_222\tTCGA_SAMP_223\tTCGA_SAMP_224\tTCGA_SAMP_225\tTCGA_SAMP_226\tTCGA_SAMP_227\tTCGA_SAMP_228\tTCGA_SAMP_229\tTCGA_SAMP_230\tTCGA_SAMP_231\tTCGA_SAMP_232\tTCGA_SAMP_233\tTCGA_SAMP_234\tTCGA_SAMP_235\tTCGA_SAMP_236\tTCGA_SAMP_237\tTCGA_SAMP_238\tTCGA_SAMP_239\tTCGA_SAMP_240\tTCGA_SAMP_241\tTCGA_SAMP_242\tTCGA_SAMP_243\tTCGA_SAMP_244\tTCGA_SAMP_245\tTCGA_SAMP_246\tTCGA_SAMP_247\tTCGA_SAMP_248\tTCGA_SAMP_249\tTCGA_SAMP_250\tTCGA_SAMP_251\tTCGA_SAMP_252\tTCGA_SAMP_253\tTCGA_SAMP_254\tTCGA_SAMP_255\tTCGA_SAMP_256\tTCGA_SAMP_257\tTCGA_SAMP_258\tTCGA_SAMP_259\tTCGA_SAMP_260\tTCGA_SAMP_261\tTCGA_SAMP_262\tTCGA_SAMP_263\tTCGA_SAMP_264\tTCGA_SAMP_265\tTCGA_SAMP_266\tTCGA_SAMP_267\tTCGA_SAMP_268\tTCGA_SAMP_269\tTCGA_SAMP_270\tTCGA_SAMP_271\tTCGA_SAMP_272\tTCGA_SAMP_273\tTCGA_SAMP_274\tTCGA_SAMP_275\tTCGA_SAMP_276\tTCGA_SAMP_277\tTCGA_SAMP_278\tTCGA_SAMP_279\tTCGA_SAMP_280\tTCGA_SAMP_281\tTCGA_SAMP_282\tTCGA_SAMP_283\tTCGA_SAMP_284\tTCGA_SAMP_285\tTCGA_SAMP_286\tTCGA_SAMP_287\tTCGA_SAMP_288\tTCGA_SAMP_289\tTCGA_SAMP_290\tTCGA_SAMP_291\tTCGA_SAMP_292'..b'-0.1234\t-0.5552\t-1.0011\t-0.7683\t-0.9426\t0.4153\t-0.9074\t-0.8332\t-0.7285\t-0.7919\t-0.7821\t-0.1604\t-0.9555\t-0.5453\t-0.5558\t-0.4777\t0.9927\t-0.5413\t-0.4734\t-0.4588\t-0.5805\t-1.0253\t-0.7693\t-0.4296\t-0.6796\t0.8262\t-0.7745\t-0.6376\t-0.0074\t0.3159\t-0.9130\t-0.9774\t0.6942\t-0.5006\t-0.8757\t0.5845\t0.7145\t0.8540\t0.9361\t0.8116\t0.2409\t-0.5179\t0.8032\t1.1316\t1.0940\t0.6173\t1.0097\t0.7659\t1.1171\t0.0157\t0.6325\t1.1164\t0.4553\t0.9517\t1.0558\t0.6920\t0.5512\t-0.0023\t0.6649\t0.1056\t0.0373\t0.3099\t-0.4889\t0.2225\t0.1384\t0.1885\t0.2696\t-0.3968\t0.0435\t-0.1625\t0.3381\t-0.5490\t-0.8873\t-0.1601\t-0.0382\t-0.1281\t0.5346\t0.1330\t-0.0225\t-0.0469\t0.3917\t-0.2018\t0.0124\t0.0971\t0.0586\t-0.2148\t-0.0725\t0.2933\t0.2434\t-0.1930\t-0.2130\t-0.0815\t-0.1020\t0.1226\t-0.8454\t0.2793\t0.0076\t-0.0491\t0.4567\t-0.5813\t-0.1195\t-0.0545\t0.4301\t0.6602\t0.0026\t-0.0107\t0.0924\t0.2801\t0.0994\t0.1995\t-0.5433\t-0.1273\t-0.2183\t0.3139\t0.7543\n-Gene_400\t-0.4675\t-0.5625\t-0.9426\t-0.9125\t-0.7059\t-1.0095\t-0.5360\t0.5494\t-0.8530\t-0.6565\t-0.5113\t-0.7029\t-0.9266\t-0.5604\t-0.6257\t-0.5704\t-0.7289\t-0.8479\t0.2874\t-0.5555\t-0.7253\t0.7134\t-0.8393\t-0.7263\t-0.1907\t-0.9337\t-0.9875\t-0.9372\t-0.7513\t-0.5924\t-0.6478\t-1.0565\t-0.4282\t-1.0247\t-0.7741\t-0.7328\t-0.6240\t-0.7278\t-0.1866\t-0.7209\t-0.5869\t-0.9104\t-0.8722\t0.7306\t-0.8916\t-0.7944\t-0.7026\t0.3330\t-0.8422\t-0.8180\t-1.0085\t-0.8501\t-0.7878\t-0.0265\t-0.8514\t-0.5027\t-0.6785\t-0.7414\t-1.0339\t0.9769\t-0.8676\t-0.6131\t-0.5971\t-1.0292\t-0.7050\t-0.9822\t-0.6119\t0.8307\t0.4432\t-0.6735\t-0.7362\t0.9352\t0.3047\t-0.6156\t-0.8046\t-0.8011\t-0.9673\t-0.0873\t-0.5907\t-0.7913\t-0.6618\t-0.7793\t-0.6049\t-0.5591\t-1.0178\t-0.5226\t-0.5416\t-0.5813\t-0.8697\t0.1654\t-1.0279\t0.6686\t-0.9866\t-0.7457\t-0.6320\t-0.5601\t-0.5332\t-0.5421\t-0.2444\t-0.9276\t-0.9135\t-0.8742\t-0.9947\t-0.9066\t-0.5072\t-0.7124\t-0.6779\t-0.7269\t-0.7067\t-1.0756\t-0.7878\t-0.9654\t-0.7497\t0.8585\t-0.8088\t-0.2993\t-0.4758\t-0.6342\t-0.9970\t-0.9072\t-0.8251\t-0.5799\t-0.8863\t-0.6786\t0.1716\t-0.7152\t-0.3949\t-0.7811\t-0.7618\t-0.5131\t-0.9968\t-0.5984\t-0.7348\t-0.6830\t0.6360\t0.4276\t-0.6148\t-0.5662\t-0.4814\t-0.7204\t-1.0230\t-0.6352\t-0.8532\t-0.9810\t-1.0715\t0.5990\t-0.7936\t-0.5936\t-0.7362\t-0.8250\t-0.6988\t-0.9429\t-0.7175\t0.2144\t-0.8203\t-0.7717\t-0.6864\t0.8223\t-0.8283\t0.9115\t-0.7985\t-0.6492\t-0.8979\t-0.9065\t-0.0489\t-1.0277\t-0.3150\t-0.0747\t-0.9950\t-0.3324\t-0.0221\t0.1903\t-0.1714\t0.9333\t-0.4070\t-0.1338\t0.1442\t-0.4161\t-0.2932\t-0.5282\t-0.5717\t-0.4622\t0.8190\t-0.3340\t-0.5111\t-0.0428\t-0.2564\t-0.2569\t-0.1697\t0.4051\t-0.6920\t-0.3264\t-0.0712\t-0.2308\t-0.1695\t-0.0590\t-0.3065\t-0.1910\t-0.1837\t-0.1376\t-0.2802\t0.4537\t-0.5248\t-0.2884\t-0.3138\t-0.3883\t-0.0174\t-0.0968\t0.1407\t-0.2415\t-0.4150\t0.2691\t-0.2863\t-0.0553\t-0.1940\t-0.3862\t-0.5521\t0.3513\t0.5377\t-0.0957\t-0.1367\t-0.0404\t-0.6388\t0.7555\t0.6765\t-0.2095\t0.1232\t0.9740\t0.0258\t-0.2023\t-0.2714\t-0.2547\t-0.0517\t-0.3214\t0.6261\t-0.0485\t-0.0965\t-0.1772\t-0.0664\t-0.2283\t-0.0235\t-0.3385\t-0.5397\t0.9498\t-0.2252\t-0.4920\t0.3937\t-0.9364\t-0.0602\t0.1564\t-0.7009\t0.4962\t0.5710\t-0.2458\t-0.0143\t-0.4776\t-0.2535\t-0.1612\t-0.2521\t-0.4946\t-0.3643\t-0.0460\t0.6374\t-0.5389\t-0.6337\t-0.1551\t-0.1683\t-0.2280\t-0.5649\t0.1563\t-0.3811\t-0.5550\t-0.3368\t-0.3596\t-0.9880\t-0.8343\t-0.3819\t-0.2793\t0.6773\t0.0126\t-0.4956\t-0.5080\t-0.4040\t-0.0193\t-0.3502\t-0.5371\t-0.1358\t-0.2151\t-0.6968\t-0.0244\t-0.4420\t-0.7311\t-0.4241\t-0.3395\t-0.1330\t-0.4521\t-0.2395\t-0.1335\t-0.1596\t-0.4195\t-0.7585\t-0.3474\t0.2321\t-0.2345\t-0.3285\t0.8975\t-0.1729\t-0.5696\t-0.4128\t-0.3681\t-0.1093\t-0.0937\t0.0969\t-0.7263\t-0.9508\t-0.2285\t-0.1364\t-0.2778\t-0.2074\t-0.1128\t-0.0071\t0.3693\t0.2008\t-0.0301\t0.8537\t-0.0354\t-0.3364\t-0.6988\t-0.4083\t-0.4346\t-0.5064\t-0.3832\t-0.1229\t0.4540\t-0.5451\t-0.2981\t0.0137\t-0.9264\t0.3926\t0.7172\t0.1079\t-0.9814\t-0.6913\t-0.2629\t0.5726\t-0.9126\t-0.1970\t0.0353\t0.0183\t0.0080\t0.1573\t-0.1910\t0.1862\t-0.1535\t-0.0711\t0.0457\t-0.0962\t-0.9497\t-0.2888\t0.0767\t-0.2824\t0.0747\t0.1759\t-0.3013\t0.1017\t-0.1491\t-0.3433\t-0.3226\t-0.1821\t-0.0231\t0.1140\t-0.9329\t-0.7741\t0.9107\t-0.8045\t-0.5862\t-0.8495\t0.7974\t-0.9572\t-0.4193\t-0.9811\t0.4838\t-0.5628\t-0.4886\t0.4722\t-0.6954\t-0.4979\t-0.7257\t-0.8920\t-0.3473\t0.9870\t-0.5745\t-0.8121\t-0.5114\t-1.0267\t-0.2803\t-0.5134\t-0.8283\t0.4809\t-0.5844\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b TestFiles/Galaxy400x400-noCovariates.ngchm
b
Binary file TestFiles/Galaxy400x400-noCovariates.ngchm has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b heatmap.sh
--- a/heatmap.sh Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,22 +0,0 @@
-echo $1 $2 $3 $4 $5 $6 $7 $8 $9 ${10} ${11} ${12} ${13} ${14} ${15}
-#create temp directory for row and col order and dendro files.
-tdir=${11}/$(date +%y%m%d%k%M%S)
-echo $tdir
-mkdir $tdir
-#run R to cluster matrix
-output="$(R --slave --vanilla --file=${11}/CHM.R --args $3 $4 $5 $6 $7 $8 $9 $tdir/ROfile.txt $tdir/COfile.txt $tdir/RDfile.txt $tdir/CDfile.txt)"
-rc=$?; if [[ $rc != 0 ]]; then echo $output; exit $rc; fi
-#there are a variable number of triplicate parameters for classification bars
-count=0
-classifcations=''
-for i in "$@"; do
-  if [ $count -gt 10 ]
-  then
-    classifications=$classifications' '$i
-  fi
-  count=$((count+1))
-done
-#call java program to generate NGCHM viewer files.
-java -jar ${11}/GalaxyMapGen.jar "${1}" "${2}" DataLayer1 $3 linear Row Column $4 $5 $6 $tdir/ROfile.txt $tdir/RDfile.txt $7 $8 $9 $tdir/COfile.txt $tdir/CDfile.txt ${10} $classifications
-#clean up tempdir
-rm -rf $tdir
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/._.DS_Store
b
Binary file naNGCHMheatmap/._.DS_Store has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/._NGCHMheatmap.xml
b
Binary file naNGCHMheatmap/._NGCHMheatmap.xml has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/._heatmap.sh
b
Binary file naNGCHMheatmap/._heatmap.sh has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/._repository_dependencies.xml
b
Binary file naNGCHMheatmap/._repository_dependencies.xml has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/CHM.R
--- a/naNGCHMheatmap/CHM.R Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,125 +0,0 @@
-### This method generates a row and column ordering given an input matrix and ordering methods.
-###
-### matrixData - numeric matrix 
-### rowOrderMethod - Hierarchical, Original, Random
-### rowDistanceMeasure - For clustering, distance measure. May be: euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation.
-### rowAgglomerationMethod - For clustering, agglomeration method.  May be:  'average' for Average Linkage, 'complete' for Complete Linkage,
-###                                                                          'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.
-### colOrderMethod 
-### colDistanceMeasure
-### colAgglomerationMethod
-### rowOrderFile - output file of order of rows 
-### rowDendroFile - output file of row dendrogram  
-### colOrderFile - output file of order of cols
-### colDendroFile - output file of col dendrogram
-
-performDataOrdering<-function(dataFile, rowOrderMethod, rowDistanceMeasure, rowAgglomerationMethod, colOrderMethod, colDistanceMeasure, colAgglomerationMethod,rowOrderFile, colOrderFile, rowDendroFile, colDendroFile)
-{ 
-   dataMatrix = read.table(dataFile, header=TRUE, sep = "\t", row.names = 1, as.is=TRUE)
-   rowOrder <-  createOrdering(dataMatrix, rowOrderMethod, "row", rowDistanceMeasure, rowAgglomerationMethod)  
-   if (rowOrderMethod == "Hierarchical") {
-      writeHCDataTSVs(rowOrder, rowDendroFile, rowOrderFile)
-   } else {
-      writeOrderTSV(rowOrder, rownames(dataMatrix), rowOrderFile)
-   }
-
-   colOrder <-  createOrdering(dataMatrix, colOrderMethod, "col", colDistanceMeasure, colAgglomerationMethod)  
-   if (colOrderMethod == "Hierarchical") {
-      writeHCDataTSVs(colOrder, colDendroFile, colOrderFile)
-   } else {
-      writeOrderTSV(colOrder, colnames(dataMatrix), colOrderFile)
-   }
-}
-
-#creates output files for hclust ordering
-writeHCDataTSVs<-function(uDend, outputHCDataFileName, outputHCOrderFileName)
-{
-   data<-cbind(uDend$merge, uDend$height, deparse.level=0)
-   colnames(data)<-c("A", "B", "Height")
-   write.table(data, file = outputHCDataFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)

-   data=matrix(,length(uDend$labels),2);
-   for (i in 1:length(uDend$labels)) {
-      data[i,1] = uDend$labels[i];
-      data[i,2] = which(uDend$order==i);
-   }
-   colnames(data)<-c("Id", "Order")
-   write.table(data, file = outputHCOrderFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)
-}
-
-#creates order file for non-clustering methods
-writeOrderTSV<-function(newOrder, originalOrder, outputHCOrderFileName)
-{
-   data=matrix(,length(originalOrder),2);
-   for (i in 1:length(originalOrder)) {
-      data[i,1] = originalOrder[i];
-      data[i,2] = which(newOrder==originalOrder[i]);
-   }
-   colnames(data)<-c("Id", "Order")
-   write.table(data, file = outputHCOrderFileName, append = FALSE, quote = FALSE, sep = "\t", row.names=FALSE)
-}
-
-
-
-createOrdering<-function(matrixData, orderMethod, direction, distanceMeasure, agglomerationMethod)
-{
-  ordering <- NULL
-
-  if (orderMethod == "Hierarchical")
-  {
-
-    # Compute dendrogram for "Distance Metric"
-    distVals <- NULL
-    if(direction=="row") {
-      if (distanceMeasure == "correlation") {
-        geneGeneCor <- cor(t(matrixData), use="pairwise")
-        distVals <- as.dist((1-geneGeneCor)/2)
-      } else {
-        distVals <- dist(matrixData, method=distanceMeasure)
-      }
-    } else { #column
-      if (distanceMeasure == "correlation") {
-        geneGeneCor <- cor(matrixData, use="pairwise")
-        distVals <- as.dist((1-geneGeneCor)/2)
-      } else {
-        distVals <- dist(t(matrixData), method=distanceMeasure)
-      }
-    }
-
-    if (agglomerationMethod == "ward") {
-      ordering <- hclust(distVals * distVals, method="ward.D2")
-    } else {
-      ordering <- hclust(distVals, method=agglomerationMethod)
-    }
-  }
-  else if (orderMethod == "Random")
-  {
-    if(direction=="row") {
-       headerList <- rownames(matrixData)
-       ordering <- sample(headerList, length(headerList)) 
-    } else {
-       headerList <- colnames(matrixData)
-       ordering <- sample(headerList, length(headerList)) 
-    }
-  }
-  else if (orderMethod == "Original")
-  {
-    if(direction=="row") {
-       ordering <- rownames(matrixData) 
-    } else {
-       ordering <- colnames(matrixData) 
-    }
-  } else {
-    stop("createOrdering -- failed to find ordering method")
-  }
-  return(ordering)
-}
-### Initialize command line arguments and call performDataOrdering
-
-options(warn=-1)
-
-args = commandArgs(TRUE)
-
-performDataOrdering(dataFile=args[1], rowOrderMethod=args[2], rowDistanceMeasure=args[3], rowAgglomerationMethod=args[4], colOrderMethod=args[5], colDistanceMeasure=args[6], colAgglomerationMethod=args[7],rowOrderFile=args[8], colOrderFile=args[9], rowDendroFile=args[10], colDendroFile=args[11])
-
-#suppressWarnings(performDataOrdering(dataFile=args[1], rowOrderMethod=args[2], rowDistanceMeasure=args[3], rowAgglomerationMethod=args[4], colOrderMethod=args[5], colDistanceMeasure=args[6], colAgglomerationMethod=args[7],rowOrderFile=args[8], colOrderFile=args[9], rowDendroFile=args[10], colDendroFile=args[11]))
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/GalaxyMapGen.jar
b
Binary file naNGCHMheatmap/GalaxyMapGen.jar has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/._.DS_Store
b
Binary file naNGCHMheatmap/MDAheatmap/._.DS_Store has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/MDAheatmap.mako
--- a/naNGCHMheatmap/MDAheatmap/MDAheatmap.mako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,96 +0,0 @@
-<HTML>
-   <HEAD>
-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>
-
- <meta id='viewport' name ="viewport" content="">
-
-   </HEAD>
-   
-   <BODY onresize="chmResize()">
-    <%
-       from galaxy import model
-       users_current_history = trans.history
-       url_dict = { }
-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]
-       output_datasets = hda.creating_job.output_datasets
-       for o in output_datasets:
-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )
-    %>
-
-    <script>
-       heatMap = null;  //global - heatmap object.
-
-       var url_dict = ${ h.dumps( url_dict ) };
-       var hdaId   = '${trans.security.encode_id( hda.id )}';
-       var hdaExt  = '${hda.ext}';
-       var ajaxUrl = "${h.url_for( controller='/datasets', action='index')}/" + hdaId + "/display?to_ext=" + hdaExt;
-
-       var xmlhttp=new XMLHttpRequest();
-       xmlhttp.open("GET", ajaxUrl, true);
-       xmlhttp.responseType = 'blob';
-       xmlhttp.onload = function(e) {
-           if (this.status == 200) {
-               var blob = new Blob([this.response], {type: 'compress/zip'});
-               zip.useWebWorkers = false;
-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);
-               var name = 'galaxydata';
-               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);
-               heatMap.addEventListener(processDetailMapUpdate);
-               initSummaryDisplay();
-               initDetailDisplay()
-           }
-       };
-       xmlhttp.send();
-
-       function chmResize() {
-          detailResize();
-       }
-
-    </script>
-
-    <div class="mdaServiceHeader">
-        <div class="mdaServiceHeaderLogo">
-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">
-        </div>
-      
-    <div id='detail_buttons' align="center" style="display:none">
-  <img id='zoomOut_btn' src='images/zoom-out.png' alt='Zoom Out' onmouseover='detailDataToolHelp(this,"Zoom Out")' onclick='detailDataZoomOut();'   align="top"   />
-     <img id='zoomIn_btn' src='images/zoom-in.png' alt='Zoom In' onmouseover='detailDataToolHelp(this,"Zoom In")' onclick='detailDataZoomIn();' align="top"   />
-     <img id='full_btn' src='images/full_selected.png' alt='Full' onmouseover='detailDataToolHelp(this,"Normal View")' onclick='detailNormal();' align="top"   />
-     <img id='ribbonH_btn' src='images/ribbonH.png' alt='Ribbon H' onmouseover='detailDataToolHelp(this,"Horizontal Ribbon View")' onclick='detailHRibbonButton();' align="top"  />
-     <img id='ribbonV_btn' src='images/ribbonV.png' alt='Ribbon V' onmouseover='detailDataToolHelp(this,"Vertical Ribbon View")' onclick='detailVRibbonButton();'  align="top"  />
-    <span style='display: inline-block;'><b>Search: </b><input type="text" id="search_text" name="search" onkeypress='clearSrchBtns();' onchange='detailSearch();'
-                                                         onmouseover='detailDataToolHelp(this,"Search Row/Column Labels. Separate search terms with spaces or commas. Use * for wild card matching. Hit enter or Go to run the search. If the search box turns red none of the search terms were found. If it turns yellow only some of the search terms were found.", 200)' ></span>
-     <img id='go_btn' src='images/go.png' alt='Go' onmouseover='detailDataToolHelp(this,"Search Row/Column Labels")'  onclick='detailSearch();' align="top"  />
-     <img id='prev_btn' src='images/prev.png' alt='Previous' onmouseover='userHelpClose();' style="display:none;" onclick='searchPrev();'  align="top"  />
-     <img id='next_btn' src='images/next.png' alt='Next' onmouseover='userHelpClose();' style="display:none;" onclick='searchNext();'  align="top"  />
-     <img id='cancel_btn' src='images/cancel.png' alt='Cancel' onmouseover='detailDataToolHelp(this,"Clear current search")' style="display:none;" onclick='clearSearch();'  align="top"  />
-       </div>
-    </div>
-
-    <div id="container">
-
-       <div id='summary_chm' style='position: relative;'>
-          <canvas id='summary_canvas'></canvas>
- <div id='sumlabelDiv' style="display: inline-block"></div>
-       </div>
-
-   <div id= 'divider' style='position: relative;' onmousedown="dividerStart()" ontouchstart="dividerStart()">
-   </div>
-
-       <div id='detail_chm' style='position: relative;'>
-          <canvas id='detail_canvas' style='display: inline-block'></canvas>
-          <div id='labelDiv' style="display: inline-block"></div>
-       </div>
-   </div>
-
-</BODY >
-</HTML>
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/config/MDAheatmap.xml
--- a/naNGCHMheatmap/MDAheatmap/config/MDAheatmap.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE visualization SYSTEM "../../visualization.dtd">
-<visualization name="MDAheatmap">
- <data_sources>
-    <data_source>
-       <model_class>HistoryDatasetAssociation</model_class>
-       <test test_attr="extension">zip</test>
-       <to_param param_attr="id">dataset_id</to_param>
-    </data_source>
- </data_sources>
- <params>
-    <param type="dataset" var_name_in_template="hda" required="true">dataset_id</param>
- </params>
- <entry_point entry_point_type="mako">MDAheatmap.mako</entry_point>
-</visualization> 
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/css/NGCHM.css
--- a/naNGCHMheatmap/MDAheatmap/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,121 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-
-#divider{
- height: 82%;
- width: 5px;
- vertical-align:top;
- display:inline-block;
- background: #666666;
- cursor: ew-resize;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:98%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#detail_buttons {
- margin-top: 10px;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/cancel.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/cancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/full.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/full_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/go.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/go.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/join.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/mdandersonlogo260x85.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/next.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/next.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/prev.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/prev.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/ribbonH.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/ribbonH_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/ribbonV.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/ribbonV_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/split.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/zoom-in.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/images/zoom-out.png
b
Binary file naNGCHMheatmap/MDAheatmap/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/.gitignore
--- a/naNGCHMheatmap/MDAheatmap/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/ColorMapManager.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,222 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeys: This function calculates and returns an
-  * array containing 10 continuous threshold breakpoint keys from the original thresholds 
-  * submitted.  It is used only for rendering a continuous classification bar help.  
-  **********************************************************************************/
- this.getContinuousThresholdKeys = function(){
-     var conThresh = new Array();
-     var bottomThresh = thresholds[0];
-     var threshSize = this.getContinuousThresholdKeySize();
-     //Add first threshold from original threshold list
-     conThresh.push(bottomThresh);
-     //Calculate and create "interim" 8 thresholds
-     for (var i = 1; i <= 8; i++){
-      conThresh.push(bottomThresh+Math.floor(threshSize*i));
-     }
-     //Add last threshold from original threshold list
-     conThresh.push(thresholds[thresholds.length - 1]);  
-     return conThresh;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeySize: This function calculates the size 
-  * separating each "interim" threshold key for a continuous classification bar.  
-  **********************************************************************************/
- this.getContinuousThresholdKeySize = function(){
-     var bottomThresh = thresholds[0];
-     var topThresh = thresholds[thresholds.length - 1]; 
-     return (topThresh - bottomThresh) / 8;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- continue;
- }
- }
- } else {
- color = this.getColor(value);
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
- this.getRgbToHex = function(rgb) {
- var a = rgb.a
- var r = rgb.r
- var g = rgb.g
- var b = rgb.b
-     return ('#' + componentToHex(r) + componentToHex(g) + componentToHex(b));
- }
-
- function componentToHex(c) {
-     var hex = c.toString(16);
-     return hex.length == 1 ? "0" + hex : hex;
- }
-
-}
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/DetailHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1743 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var userHelpOpen;\r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-\r\n-var detailDendroHeight = 105;\r\n-var detailDendroWidth = 105;\r\n-var normDetailDendroMatrixHeight = 200;\r\n-var rowDetailDendroMatrix,colDetailDendroMatrix;\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-var currentSearchItem;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'divider\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src="images/join.png";\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(10);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  (detailDataViewWidth + calculateTotalClassBarHeight("row") + detailDendroWidth);\r\n-\t\tdetCanvas.height = (detailDataViewHeight + calculateTotalClassBarHeight("column") + detailDendroHeight);\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = clickStart;\r\n-\tdocument.onmouseup = clickEnd;\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.addEventListener("touchmove", function(e){\r\n-\t\te.preventDefault();\r\n-\t\tif (e.touches){\r\n-\t    \tif (e.touches.length > 1){\r\n-\t    \t\treturn false;\r\n-\t    \t}\r\n-\t    }\r\n-\t})\r\n-\tdetCanvas.addEventListener("touchstart", function(e){\r\n-\t\tuserHelpClose();\r\n-\t\tclickStart(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchmove", function(e){\r\n-\t\te.stopPropagation();\r\n-\t\te.preventDefault();\r\n-\t\thandleMove(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchend", function(e){clickEnd(e)}, false);\r\n-\t\r\n-\tdetCanvas.addEventListener("gestureend",function(e){\r\n-\t\tif (e.scale > 1){\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\t} else if (e.scale < 1){\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\t}\r\n-\t},false)\r\n-\t\r\n-\t\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function clickStart(e){\r\n-\tuserHelpClose();\r\n-\tdragOffsetX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tdragOffsetY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\r\n-    mouseDown = true;\r\n-}\r\n-function clickEnd(e){\r\n-\tmouseDown = false;\r\n-\tvar dragEndX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tvar dragEndY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\tvar rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\tif (Math.abs(dragEndX - dragOffsetX) < colElementSize/10 && Math.abs(dragEndY - dragOffsetY) < rowElementSize/10){\r\n-\t\tuserHelpOpen(e);\r\n-\t}\r\n-}\r\n-\r\n-function handleDrag(e) {\r\n-    if(!mouseDown) return;\r\n-    var rowElementSize = dataBoxWidth * detCanvas.cli'..b'\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row")+detailDendroWidth;\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column")+detailDendroHeight;\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/MatrixManager.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,463 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different 'zoom' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = 'tn';\r\n-MatrixManager.SUMMARY_LEVEL = 's';\r\n-MatrixManager.RIBBON_VERT_LEVEL = 'rv';\r\n-MatrixManager.RIBBON_HOR_LEVEL = 'rh';\r\n-MatrixManager.DETAIL_LEVEL = 'd';\r\n-\r\n-MatrixManager.WEB_SOURCE = 'W';\r\n-MatrixManager.FILE_SOURCE = 'F';\r\n-\r\n-MatrixManager.Event_INITIALIZED = 'Init';\r\n-MatrixManager.Event_JSON = 'Json';\r\n-MatrixManager.Event_NEWDATA = 'NewData';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Return the row sample ratio for a given level\r\n-\tthis.getRowSampleRatio = function(level){\r\n-\t\treturn datalayers[level].rowSampleRatio;\r\n-\t}\r\n-\t\r\n-\t//Return the column sample ratio for a given level\r\n-\tthis.getColSampleRatio = function(level){\r\n-\t\treturn datalayers[level].colSampleRatio;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don't do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdatalayers[level].setReadWindow(row, column, numRows, numColumns);\r\n-    } \t\r\n-\r\n-\t// Retrieve color map Manager for this heat map.\r\n-\tthis.getColorMapManager = function() {\r\n-\t\tif (initialized != 1)\r\n-\t\t\treturn null;\r\n-\t\t\r\n-\t\tif (colorMapMgr == null ) {\r\n-\t\t\tcolorMapMgr = new ColorMapManager(colorMaps);\r\n-\t\t}\r\n-\t\treturn colorMapMgr;\r\n-\t}\r\n-\t\r\n-\t//Retrieve classifications\r\n-\tthis.getClassifications = function() {\r\n-\t\treturn classifications;\r\n-\t}\r\n-\t\r\n-\t//Get Row Labels\r\n-\tthis.getRowLabels = function() {\r\n-\t\treturn rowLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tth"..b' to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\t\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\r\n-    this.rowSampleRatio = jsonData.row_sample_ratio;\r\n-    this.colSampleRatio = jsonData.col_sample_ratio;\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endRowCalc = (row+(numRows-1))/rowsPerTile;\r\n-    \tvar endColCalc = (column+(numColumns-1))/colsPerTile;\r\n-\t\tvar endRowTile = Math.floor(endRowCalc)+(endRowCalc%1 > 0 ? 1 : 0);\r\n-\t\tvar endColTile = Math.floor(endColCalc)+(endColCalc%1 > 0 ? 1 : 0);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/NGCHM_Util.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,8 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/SelectionManager.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,386 +0,0 @@\n-/**\r\n- * This code is responsible for handling changes in position of selected heat map region.\r\n- * It handles mouse, keyboard, and button events that change the position of the selected\r\n- * region.  It also tracks whether the display is in a single window or split into two\r\n- * separate windows.  If in separate windows, local storage events are used to communicate\r\n- * changes between the two windows.  \r\n- */\r\n-\r\n-//Globals that provide information about heat map position selection.\r\n-\r\n-mode = null;          // Set to normal or ribbon vertical or ribbon horizontal \r\n-currentRow=null;      // Top row of current selected position\r\n-currentCol=null;      // Left column of the current selected position\r\n-dataPerRow=null;      // How many rows are included in the current selection\r\n-dataPerCol=null;      // How many columns in the current selection\r\n-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.\r\n-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.\r\n-var searchItems=[];   // Valid labels found from a user search\r\n-\r\n-                      //isSub will be set to true if windows are split and this is the child.\r\n-isSub = getURLParameter(\'sub\') == \'true\';  \r\n-hasSub = false;       //hasSub set to true if windows are split and this is the parent.\r\n-\r\n-\r\n-/* This routine is called when the selected row / column is changed.\r\n- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,\r\n- * and dataPerCol as desired. This method does redrawing and notification as necessary.  \r\n- */\r\n-function updateSelection() {\r\n-\tvar selected = "";\r\n-\t\t\r\n-\tif (!isSub) {\r\n-\t\t//We have the summary heat map so redraw the yellow selection box.\r\n-\t\tdrawLeftCanvasBox();\r\n-\t} \r\n-\tif (!hasSub) {\r\n-\t\t// Redraw based on mode type and selection. \r\n-\t\theatMap.setReadWindow(getLevelFromMode(MatrixManager.DETAIL_LEVEL),currentRow,currentCol,dataPerCol,dataPerRow);\r\n-\t\tdrawDetailHeatMap();\r\n-\t} \r\n-\t\r\n- \t//If summary and detail as split into two browsers.  Communicate the selection change\r\n-\t//to the other browser.\r\n-\tif (isSub || hasSub) {\r\n-\t\tlocalStorage.removeItem(\'event\');\r\n-\t\tlocalStorage.setItem(\'currentRow\', \'\' + currentRow);\r\n-\t\tlocalStorage.setItem(\'currentCol\', \'\' + currentCol);\r\n-\t\tlocalStorage.setItem(\'dataPerRow\', \'\' + dataPerRow);\r\n-\t\tlocalStorage.setItem(\'dataPerCol\', \'\' + dataPerCol);\r\n-\t\tlocalStorage.setItem(\'selectedStart\', \'\' + selectedStart);\r\n-\t\tlocalStorage.setItem(\'selectedStop\', \'\' + selectedStop);\r\n-\t\tlocalStorage.setItem(\'mode\', mode);\r\n-    \t//turn current search items into a comma delimited string.\r\n-    \tfor (var i=0; i < searchItems.length; i++) {selected+=";"+searchItems[i];}\r\n-\t\tlocalStorage.setItem(\'selected\', selected);\r\n-\t\tlocalStorage.setItem(\'event\', \'changePosition\');\r\n-\t}\t\t\r\n-}\r\n-\r\n-function changeMode(newMode) {\r\n-\t\r\n-\tif (!hasSub) {\r\n-\t\tif (newMode == \'RIBBONH\')\r\n-\t\t\tdetailHRibbon();\r\n-\t\tif (newMode == \'RIBBONV\')\r\n-\t\t\tdetailVRibbon();\r\n-\t\tif (newMode == \'NORMAL\')\r\n-\t\t\tdetailNormal();\r\n-\t} else {\r\n-\t\tlocalStorage.removeItem(\'event\');\r\n-\t\tlocalStorage.setItem(\'selectedStart\', \'\' + selectedStart);\r\n-\t\tlocalStorage.setItem(\'selectedStop\', \'\' + selectedStop);\r\n-\t\tlocalStorage.setItem(\'mode\', newMode);\r\n-\t\tlocalStorage.setItem(\'event\', \'changeMode\');\r\n-\t}\r\n-}\r\n-\r\n-/* Handle mouse scroll wheel events to zoom in / out.\r\n- */\r\n-function handleScroll(evt) {\r\n-\tevt.preventDefault();\r\n-\tif (evt.wheelDelta < 0 || evt.deltaY > 0 || evt.scale < 1) { //Zoom out\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem(\'event\');\r\n-\t\t\tlocalStorage.setItem(\'event\', \'zoomOut\' )\r\n-\t\t}\r\n-\t} else { // Zoom in\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem(\'event\');\r\n-\t\t\tlocalStorage.setItem(\'event\', \'zoomIn\' )\r\n-\t\t}\r\n-\t}\t\r\n-\treturn false;\r\n-} \t\t\r\n-\r\n-\r\n-function keyNavigate(e){\r\n-\tuserHelpClose();\r\n-    clearTimeout(de'..b" sample ratios (ratio of detail to summary) \r\n- * are used to calculate the proper detail coordinates.  \r\n- **********************************************************************************/\r\n-function setCurrentRowFromSum(sumRow) {\r\n-\t// Up scale current summary row to detail equivalent\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tif (rowSampleRatio > 1) {\r\n-\t\tcurrentRow = (sumRow*rowSampleRatio);\r\n-\t} else {\r\n-\t\tcurrentRow = sumRow;\r\n-\t}\r\n-}\r\n-function setCurrentColFromSum(sumCol) {\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tif (colSampleRatio > 1) {\r\n-\t\tcurrentCol = (sumCol*colSampleRatio);\r\n-\t} else {\r\n-\t\tcurrentCol = sumCol;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - setCurrentSumRow(Col): These functions perform the conversion of \r\n- * currentRow and currentCol coordinates from detail to summary.  This is done \r\n- * so that the  proper row/col location is set on the summary pane when a user clicks \r\n- * in the detail pane. This is used when the leftCanvasBox is drawn. The heatmap \r\n- * row/col sample ratios (ratio of detail to summary) are used to  calculate the \r\n- * proper detail coordinates.\r\n- **********************************************************************************/\r\n-function getCurrentSumRow() {\r\n-\t// Unless current mode is vertical ribbon, start with detail current row\r\n-\tvar currRow = currentRow;\r\n-\t// If current mode is vertical ribbon, start Selected Start and apply\r\n-\t// ribbon vertical sample ratio.\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rvRatio = heatMap.getRowSampleRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tcurrRow = selectedStart * rvRatio;\r\n-\t}\r\n-\t// Convert selected current row value to Summary level\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\treturn  Math.floor(currRow/rowSampleRatio)+1;\r\n-}\r\n-//Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumCol() {\r\n-\tvar currCol = currentCol;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rhRatio = heatMap.getColSampleRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tcurrCol = selectedStart * rhRatio;\r\n-\t}\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\treturn  Math.floor(currCol/colSampleRatio)+1;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentSumDataPerRow(Col): These functions perform the conversion of \r\n- * dataPerRow and dataPerCol from detail to summary.  This is done so that the  \r\n- * proper view pane can be calculated on the summary heatmap when drawing the \r\n- * leftCanvasBox on that side of the screen.\r\n- **********************************************************************************/\r\n-function getCurrentSumDataPerRow() {\r\n-\tvar rowSampleRatio = heatMap.getRowSampleRatio(getLevelFromMode(MatrixManager.SUMMARY_LEVEL));\r\n-\t// Summary data per row for all modes except Ribbon Horizontal using the sample ration for that level\r\n-\tvar\tsumDataPerRow = Math.floor(dataPerRow/rowSampleRatio);\r\n-\t// For Ribbon Horizontal, we convert to summary level THEN apply the ribbon horizontal sample ratio\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rate = heatMap.getColSampleRatio(getLevelFromMode(MatrixManager.RIBBON_HOR_LEVEL));\r\n-\t\tsumDataPerRow = (Math.floor(dataPerRow/summarySampleRatio)*rate);\r\n-\t} \r\n-\treturn sumDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumDataPerCol() {\r\n-\tvar colSampleRatio = heatMap.getColSampleRatio(getLevelFromMode(MatrixManager.SUMMARY_LEVEL));\r\n-\tvar\tsumDataPerCol = Math.floor(dataPerCol/colSampleRatio);\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rate = heatMap.getRowSampleRatio(getLevelFromMode(MatrixManager.RIBBON_VERT_LEVEL));\r\n-\t\tsumDataPerCol = (Math.floor(dataPerCol/summarySampleRatio)*rate);\r\n-\t} \r\n-\treturn sumDataPerCol;\r\n-}\r\n-\r\n-\r\n-\r\n-\r\n-\r\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/SummaryHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,995 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var dendroPaddingHeight = 1;\r\n-var rowDendroHeight = 102; // this is the height of the row dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var columnDendroHeight = 102; // this is the height of the col dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var normDendroMatrixHeight = 500; // this is the height of the dendro matrices created in buildDendroMatrix\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-var summarySampleRatio;\r\n-\r\n-var rowDendroBars;\r\n-var colDendroBars;\r\n-var colDendroMatrix;\r\n-var rowDendroMatrix;\r\n-var chosenBar = {axis: null, index: null};\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcanvas.onmousemove = handleMove;\r\n-\t// set the position to (1,1) so that the detail pane loads at the top left corner of the summary.\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {\r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tclassBars = heatMap.getClassifications();\r\n-\t\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\t\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\t\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummarySampleRatio = heatMap.getColSampleRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Row\'); // create array with the bars\r\n-\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\'); // create array with the bars\r\n-\t\t\r\n-\t\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\t\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\t\trowEmptySpace = summaryMatrixWidth/2 - summaryMatrixHeight;\r\n-\t\telse if (summaryMatrixHeight > summaryMatrixWidth && summaryMatrixHeight/summaryMatrixWidth > 2)\r\n-\t\t\tcolEmptySpace = summaryMatrixHeight/2 - summaryMatrixWidth;\r\n-\t\t\r\n-\t\tcalcTotalSize();\r\n-\r\n-\t\tcanvas.width =  summaryTotalWidth;\r\n-\t\tcanvas.height = summaryTotalHeight;\r\n-\t\tsetupGl();\r\n-\t\tinitGl();\r\n-\t\tbuildSummaryTexture();\r\n-\t\tleftCanvasBoxVertThick = (1+Math.floor(summaryMatrixWidth/250))/1000;\r\n-\t\tleftCanvasBoxHorThick = (1+Math.floor(summaryMatrixHeight/250))/1000;\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//'..b'dendroMatrix[0].length){\r\n-\t\tif (dendroMatrix[i][j+1] == 1 ||dendroMatrix[i][j+1] == 2){\r\n-\t\t\tj++;\r\n-\t\t\tdendroMatrix[i][j] = 2;\r\n-\t\t} else {//if (dendroMatrix[i-1][j] == 1 ||dendroMatrix[i-1][j] == 2){\r\n-\t\t\ti--;\r\n-\t\t\tdendroMatrix[i][j] = 2;\r\n-\t\t}\r\n-\t}\r\n-\treturn j;\r\n-}\r\n-\r\n-function highlightAllBranchesInRange(height,leftExtreme,rightExtreme,dendroMatrix){\r\n-\tfor (var i = height; i >= 0; i--){\r\n-\t\tfor (var loc in dendroMatrix[i]){\r\n-\t\t\tif (leftExtreme < loc && loc < rightExtreme){\r\n-\t\t\t\tdendroMatrix[i][loc] = 2;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function clearDendroSelection(){\r\n-\tchosenBar = {axis: null, index: null};\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\');\r\n-\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),"Row");\r\n-\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\tdrawRowDendrogram(TexPixels);\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\r\n-\r\n-\r\n-//***************************//\r\n-//Selection Label Functions *//\r\n-//***************************//\r\n-function summaryResize() {\r\n-\tclearSelectionMarks();\r\n-\tdrawRowSelectionMarks();\r\n-\tdrawColSelectionMarks();\r\n-}\r\n-\r\n-\r\n-function drawRowSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalHeight - summaryMatrixHeight;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedRows = getSearchRows();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedRows.length; i++) {\r\n-\t\tvar xPos = canvas.clientWidth + 3;\r\n-\t\tvar position = headerSize + (selectedRows[i]/heatMap.getRowSampleRatio(MatrixManager.DETAIL_LEVEL));\r\n-\t\tvar yPos = ((position * canvas.clientHeight) / summaryTotalHeight) - fontSize;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'F\');\r\n-\t}\r\n-}\r\n-\r\n-function drawColSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalWidth - summaryMatrixWidth;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedCols = getSearchCols();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedCols.length; i++) {\r\n-\t\tvar position = headerSize + (selectedCols[i]/heatMap.getColSampleRatio(MatrixManager.DETAIL_LEVEL));\r\n-\t\tvar xPos = ((position * canvas.clientWidth) / summaryTotalWidth) + fontSize/2;\r\n-\t\tvar yPos = canvas.clientHeight + 4;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'T\');\r\n-\t}\r\n-}\r\n-\r\n-function clearSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar oldMarks = document.getElementsByClassName("MarkLabel");\r\n-\twhile (oldMarks.length > 0) {\r\n-\t\tmarkElement.removeChild(oldMarks[0]);\r\n-\t}\r\n-\r\n-}\r\n-\r\n-\r\n-function dividerStart(){\r\n-\tuserHelpClose();\r\n-\tdocument.addEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.addEventListener(\'touchmove\', dividerMove);\r\n-\tdocument.addEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.addEventListener(\'touchend\',dividerEnd);\r\n-}\r\n-function dividerMove(e){\r\n-\tvar divider = document.getElementById(\'divider\');\r\n-\tif (e.touches){\r\n-    \tif (e.touches.length > 1){\r\n-    \t\treturn false;\r\n-    \t}\r\n-    }\r\n-\tvar Xmove = e.touches ? divider.offsetLeft - e.touches[0].pageX : divider.offsetLeft - e.pageX;\r\n-\tvar summary = document.getElementById(\'summary_chm\');\r\n-\tvar summaryX = summary.offsetWidth - Xmove;\r\n-\tsummary.setAttribute("style","position: relative; width:" + summaryX + "px");\r\n-\tvar detail = document.getElementById(\'detail_chm\');\r\n-\tvar detailX = detail.offsetWidth + Xmove;\r\n-\tdetail.setAttribute("style","position: relative; width:" + detailX + "px");\r\n-\tclearLabels();\r\n-\tclearSelectionMarks();\r\n-}\r\n-function dividerEnd(){\r\n-\tdocument.removeEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.removeEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.removeEventListener(\'touchmove\',dividerMove);\r\n-\tdocument.removeEventListener(\'touchend\',dividerEnd);\r\n-\tdetailResize();\r\n-\tsummaryResize();\r\n-}\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/lib/deflate.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/lib/inflate.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/lib/z-worker.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/lib/zip.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/javascript/temp.js
--- a/naNGCHMheatmap/MDAheatmap/javascript/temp.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,49 +0,0 @@
-/**
- * 
- */
-
-function buildSomething () {
- var numRows = 10;
- var numCols = 10;
- var myMatrix = create2DArray(numRows, numCols);
-
- //Note 0 based - may need to modify for row - column ordering starting at 1
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Move data into a linear (texture) array - could change to colors at the same time
- var texture = new Array(numRows*numCols);
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- texture[row*numCols+col] = myMatrix[row][col];
- }
- }
-
- //For a sideways dendor - row dendro still do the 2D array normal way
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Then pull out one column at a time to put on the front of each texture row.
- var currentRow = 7;
- var textureRow = new Array(1000);
- pos = 700;
- for (var row = 0; row < numRows; row++) {
- textureRow[pos + col] = myMatrix[row][7];
- }
-}
-
-
-
-function create2DArray(rows, columns) {
- var matrix = new Array(rows);
- for (var i = 0; i < rows; i++) {
- matrix[i] = new Array(columns);
- }
- return matrix;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/css/NGCHM.css
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,107 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;  */
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    verticalAlign:top;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    verticalAlign:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/full.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/full_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/join.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/mdandersonlogo260x85.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/split.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-in.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-out.png
b
Binary file naNGCHMheatmap/MDAheatmap/oldstatic/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/.gitignore
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/ColorMapManager.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,181 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- continue;
- }
- }
- } else {
- color = this.getColor(value);
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
-}
-
-
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1165 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var userHelpOpen;\r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src="images/join.png";\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(20);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  detailDataViewWidth + calculateTotalClassBarHeight("row");\r\n-\t\tdetCanvas.height = detailDataViewHeight + calculateTotalClassBarHeight("column");\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = function(e){\r\n-\t\tdragOffsetX = e.pageX;\r\n-\t\tdragOffsetY = e.pageY;\r\n-\r\n-\t    mouseDown = true;\r\n-\t}\r\n-\tdocument.onmouseup = function(e){\r\n-\t\tmouseDown = false;\r\n-\t}\r\n-\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function handleDrag(e) {\r\n-\tclearTimeout(detailPoint);\r\n-    if(!mouseDown) return;\r\n-    var rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-    \r\n-    var xDrag = e.pageX - dragOffsetX;\r\n-    var yDrag = e.pageY - dragOffsetY;\r\n-    \r\n-    if ((Math.abs(xDrag/rowElementSize) > 1) || \r\n-    \t(Math.abs(yDrag/colElementSize) > 1)    ) {\r\n-    \tcurrentRow = Math.floor(currentRow - (yDrag/colElementSize));\r\n-    \tcurrentCol = Math.floor(currentCol - (xDrag/rowElementSize));\r\n-    \t\r\n-\t    dragOffsetX = e.pageX;\r\n-\t    dragOffsetY = e.pageY;\r\n-\t    var numRows = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);\r\n-\t    var numCols = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);\r\n-\t    checkRow();\r\n-\t    checkColumn();\r\n-\t \r\n-\t    updateSelection();\r\n-   }\r\n-    return false;\r\n-}\t\r\n-\r\n-function handleMove(e) {\r\n-\tif (mouseDown){\r\n-\t\thandleDrag(e);\r\n-\t} else{\r\n-\t\tuserHelpOpen(e);\r\n-\t}\r\n-}\r\n- \r\n-function getColClassPixelHeight() {\r\n-\tvar classbarHeight = calculateTotalClassBarHeight("column");\r\n-\treturn detCanvas.clientHeight*(classbarHeight/detCanvas.height);\r\n-}\r\n-\r\n-function getRowClassPixelWidth() {\r\n-\tvar classbarWidth = calculateTotalClassBarHeight("row");\r\n-\treturn detCanvas.clientWidth*(classbarWidth/detCanvas.width);\r\n-}\r\n-\r\n-function isOnObject(e,type) {\r\n-    var rowClassWidthPx =  getRowClassPixelWidth();\r\n-    var colClassHeightPx = getColClassPixelHeight();\r\n-    if (e.layerY > colClassHeightPx ) { \r\n-    \tif  ((type == "map") && e.layerX > rowClassWidthPx) {\r\n-    \t\treturn true;\r\n-    \t}\r\n-    \tif  ((type'..b'm vec2 u_box_right_bottom;\' +\r\n- \t\t \t\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row");\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column");\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/MatrixManager.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,443 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different 'zoom' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = 'tn';\r\n-MatrixManager.SUMMARY_LEVEL = 's';\r\n-MatrixManager.RIBBON_VERT_LEVEL = 'rv';\r\n-MatrixManager.RIBBON_HOR_LEVEL = 'rh';\r\n-MatrixManager.DETAIL_LEVEL = 'd';\r\n-\r\n-MatrixManager.WEB_SOURCE = 'W';\r\n-MatrixManager.FILE_SOURCE = 'F';\r\n-\r\n-MatrixManager.Event_INITIALIZED = 'Init';\r\n-MatrixManager.Event_NEWDATA = 'NewData';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don't do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdatalayers[level].setReadWindow(row, column, numRows, numColumns);\r\n-    } \t\r\n-\r\n-\t// Retrieve color map Manager for this heat map.\r\n-\tthis.getColorMapManager = function() {\r\n-\t\tif (initialized != 1)\r\n-\t\t\treturn null;\r\n-\t\t\r\n-\t\tif (colorMapMgr == null ) {\r\n-\t\t\tcolorMapMgr = new ColorMapManager(colorMaps);\r\n-\t\t}\r\n-\t\treturn colorMapMgr;\r\n-\t}\r\n-\t\r\n-\t//Retrieve classifications\r\n-\tthis.getClassifications = function() {\r\n-\t\treturn classifications;\r\n-\t}\r\n-\t\r\n-\t//Get Row Labels\r\n-\tthis.getRowLabels = function() {\r\n-\t\treturn rowLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tthis.getColLabels = function() {\r\n-\t\treturn colLabels;\r\n-\t}\r\n-\t\r\n-\t//Get Column Labels\r\n-\tthis.getDendrogram = function() {\r\n-\t\treturn dendrogram;\r\n-\t}\r\n-\t\r\n-\t//Method used to register another callback function for a user that wants to be notifed\r\n-\t//of updates to the status of heat map data.\r\n-\tthis.addEventListener = function(callback) {"..b'(MatrixManager.Event_NEWDATA, level);\r\n-\t\t\t     }\r\n-\t\t\t    \t  \r\n-\t\t\t     fr.readAsArrayBuffer(blob);\t\t\r\n-\t\t\t}, function(current, total) {\r\n-\t\t\t\t// onprogress callback\r\n-\t\t\t});\t\t\r\n-\t\t}\r\n-\t};\r\n-\t\r\n-\t//Helper function to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\t\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\t\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar endRowTile = startRowTile + Math.floor((numRows-1)/rowsPerTile);\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endColTile = startColTile + Math.floor((numColumns-1)/colsPerTile);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/NGCHM_Util.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,8 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SelectionManager.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,217 +0,0 @@
-/**
- * This code is responsible for handling changes in position of selected heat map region.
- * It handles mouse, keyboard, and button events that change the position of the selected
- * region.  It also tracks whether the display is in a single window or split into two
- * separate windows.  If in separate windows, local storage events are used to communicate
- * changes between the two windows.  
- */
-
-//Globals that provide information about heat map position selection.
-
-mode = null;          // Set to normal or ribbon verticle or ribbon horizontal
-currentRow=null;      // Top row of current selected position
-currentCol=null;      // Left column of the current selected position
-dataPerRow=null;      // How many rows are included in the current selection
-dataPerCol=null;      // How many columns in the current selection
-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.
-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.
-
-                      //isSub will be set to true if windows are split and this is the child.
-isSub = getURLParameter('sub') == 'true';  
-hasSub = false;       //hasSub set to true if windows are split and this is the parent.
-
-
-/* This routine is called when the selected row / column is changed.
- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,
- * and dataPerCol as desired. This method does redrawing and notification as necessary.  
- */
-function updateSelection() {
-
- if (!isSub) {
- //We have the summary heat map so redraw the yellow selection box.
- drawLeftCanvasBox();
- } 
- if (!hasSub) {
- //We have the detail heat map so redraw based on selection. 
- drawDetailHeatMap();
- } 
-
- if (isSub || hasSub) {
- //summary and detail as split into two browsers.  Communciate the selection change
- //to the other browser.
- localStorage.removeItem('event');
- localStorage.setItem('currentRow', '' + currentRow);
- localStorage.setItem('currentCol', '' + currentCol);
- localStorage.setItem('dataPerRow', '' + dataPerRow);
- localStorage.setItem('dataPerCol', '' + dataPerCol);
- localStorage.setItem('selectedStart', '' + selectedStart);
- localStorage.setItem('selectedStop', '' + selectedStop);
- localStorage.setItem('mode', mode);
- localStorage.setItem('event', 'changePosition');
- }
-}
-
-function changeMode(newMode) {
-
- if (!hasSub) {
- if (newMode == 'RIBBONH')
- detailHRibbon();
- if (newMode == 'RIBBONV')
- detailVRibbon();
- if (newMode == 'NORMAL')
- detailNormal();
- } else {
- localStorage.removeItem('event');
- localStorage.setItem('selectedStart', '' + selectedStart);
- localStorage.setItem('selectedStop', '' + selectedStop);
- localStorage.setItem('mode', newMode);
- localStorage.setItem('event', 'changeMode');
- }
-}
-
-/* Handle mouse scroll wheel events to zoom in / out.
- */
-function handleScroll(evt) {
- evt.preventDefault();
- if (evt.wheelDelta < 0 || evt.deltaY > 0) { //Zoom out
- if (!hasSub)
- detailDataZoomOut();
- else {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'zoomOut' )
- }
- } else { // Zoom in
- if (!hasSub)
- detailDataZoomIn();
- else {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'zoomIn' )
- }
- }
- return false;
-} 
-
-
-function keyNavigate(e){
- userHelpClose();
-    clearTimeout(detailPoint);
- e.preventDefault();
- switch(e.keyCode){
- case 37: // left key
- if (e.shiftKey){
- currentCol -= dataPerRow;
- } else {
- currentCol--;
- }
- break;
- case 38: // up key
- if (e.shiftKey){
- currentRow -= dataPerCol;
- } else {
- currentRow--;
- }
- break;
- case 39: // right key
- if (e.shiftKey){
- currentCol += dataPerRow;
- } else {
- currentCol++;
- }
- break;
- case 40: // down key
- if (e.shiftKey){
- currentRow += dataPerCol;
- } else {
- currentRow++;
- }
- break;
- default:
- break;
- }
-
- checkRow();
- checkColumn();
-    
-    updateSelection();
-}
-
-/* Local storage is used to communicate between two browser windows when the display is split. Set
- * up an event to be notified when contents of local storage are modified.
- */ 
-function setupLocalStorage () {
- window.addEventListener('storage', function (evt) {
- console.log('localstorage event ' + evt.key);
- if (evt.key == 'event') {
- handleLocalStorageEvent(evt);
- } 
- }, false);
-}
-
-//When the detail pane is in a separate window, local storage is used to send it updates from 
-//clicks in the summary view.
-function handleLocalStorageEvent(evt) {
- var type = localStorage.getItem('event');
- console.log('type ' + type);
- if (type == 'changePosition') {
- currentRow = Number(localStorage.getItem('currentRow'));
- currentCol = Number(localStorage.getItem('currentCol'));
- dataPerRow = Number(localStorage.getItem('dataPerRow'));
- dataPerCol = Number(localStorage.getItem('dataPerCol'));
- selectedStart = Number(localStorage.getItem('selectedStart'));
- selectedStop = Number(localStorage.getItem('selectedStop'));
- mode = localStorage.getItem('mode');
- if (hasSub) {
- // Redraw the yellow selection box.
- drawLeftCanvasBox ();
- } 
- if (isSub) {
- // Redraw detail view based on selection. 
- drawDetailHeatMap();
- } 
- } else if ((type == 'zoomIn') && (isSub)) {
- detailDataZoomIn();
- } else if ((type == 'zoomOut') && (isSub)) {
- detailDataZoomOut();
- } else if ((type == 'changeMode') && (isSub)) {
- var newMode = localStorage.getItem('mode');
- selectedStart = Number(localStorage.getItem('selectedStart'));
- selectedStop = Number(localStorage.getItem('selectedStop'));
- if (newMode == 'RIBBONH')
- detailHRibbon();
- if (newMode == 'RIBBONV')
- detailVRibbon();
- if (newMode == 'NORMAL')
- detailNormal();
- } else if ((type == 'join') && hasSub) {
- hasSub=false;
- detailJoin();
- }
-}
-
-//Called when a separate detail map window is joined back into the main chm browser window.
-function rejoinNotice() {
- localStorage.removeItem('event');
- localStorage.setItem('event', 'join');
-}
-
-
-//Makes sure the currentRow setting is valid and adjusts if it is not.
-function checkRow() {
- var numRows = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);
- if ((currentRow < 1) || ((mode == 'RIBBONV') && (selectedStart==0))) currentRow = 1;
- if ((mode == 'RIBBONV') && (selectedStart != 0)) currentRow = selectedStart;
-    if (currentRow > ((numRows + 1) - dataPerCol)) currentRow = (numRows + 1) - dataPerCol;
-}
-
-function checkColumn() {
-    var numCols = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);
-    if ((currentCol < 1) || ((mode == 'RIBBONH') && selectedStart==0)) currentCol = 1;
-    if ((mode == 'RIBBONH') && selectedStart!= 0) currentCol = selectedStart;
-    if (currentCol > ((numCols + 1) - dataPerRow)) currentCol = (numCols + 1) - dataPerRow;
-}
-
-
-
-
-
-
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,891 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var rowDendroHeight = 105;\r\n-var columnDendroHeight = 105;\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-\r\n-var colDendroBars;\r\n-var rowDendroBars;\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {\r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tclassBars = heatMap.getClassifications();\r\n-\t\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\t\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\t\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\t\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\t\r\n-\t\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\t\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\t\trowEmptySpace = summaryMatrixWidth/2 - summaryMatrixHeight;\r\n-\t\telse if (summaryMatrixHeight > summaryMatrixWidth && summaryMatrixHeight/summaryMatrixWidth > 2)\r\n-\t\t\tcolEmptySpace = summaryMatrixHeight/2 - summaryMatrixWidth;\r\n-\t\t\r\n-\t\tcalcTotalSize();\r\n-\r\n-\t\tcanvas.width =  summaryTotalWidth;\r\n-\t\tcanvas.height = summaryTotalHeight;\r\n-\t\tsetupGl();\r\n-\t\tinitGl();\r\n-\t\tbuildSummaryTexture();\r\n-\t\tleftCanvasBoxVertThick = (1+Math.floor(summaryMatrixWidth/250))/1000;\r\n-\t\tleftCanvasBoxHorThick = (2+Math.floor(summaryMatrixHeight/250))/1000;\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//Summary tile - wait a bit to see if we get another tile quickly, then draw\r\n-\t\tif (eventTimer != 0) {\r\n-\t\t\t//New tile arrived - reset timer\r\n-\t\t\tclearTimeout(eventTimer);\r\n-\t\t}\r\n-\t\teventTimer = setTimeout(buildSummaryTexture, 200);\r\n-\t} \r\n-\t//Ignore updates to other tile types.\r\n-}\r\n-\r\n-//Set the variables for the total size of the summary heat map - used to set canvas, WebGL texture, and viewport size.\r\n-function calcTotalSize() {\r\n-\tsummaryTotalHeight = summaryMatrixHeight + rowEmptySpace + summaryViewBorderWidth + colClassBarHeight + columnDendroHeight;\r\n-\tsummaryTotalWidth = summaryMatrixWidth + colEmptySpace + summaryViewBorderWidth + rowClassBarWidth + rowDendroHeight;\r\n-}\r\n-\r\n-function buildSummaryTexture() {\r\n-\teventTimer = 0;\r\n-\tvar colorMap = heatMap.getColorMapMan'..b'roBoxLeftTopArray = new Float32Array([leftMin, 1-rightExtreme/canvas.height-topMin]);\r\n-\tdendroBoxRightBottomArray = new Float32Array([1-matrixRight, 1-leftExtreme/canvas.height-topMin]);\r\n-\r\n-\tselectedStart = leftExtreme;\r\n-\tselectedStop = rightExtreme;\r\n-}\r\n-\r\n-function highlightColumnDendrogram(dataBuffer, selectedNode){\r\n-\tvar interval = heatMap.getDendrogram()["interval"];\r\n-\tvar highlightedBars = [];\r\n-\tvar mapAndClassBarHeight = summaryTotalHeight - columnDendroHeight;\r\n-\tvar startPos = summaryTotalWidth*(mapAndClassBarHeight+1)*BYTE_PER_RGBA + (rowClassBarWidth+rowDendroHeight+summaryViewBorderWidth/2)*BYTE_PER_RGBA; // bottom left corner of the dendro space\r\n-\tvar leftExtreme = getTranslatedLocation(colDendroBars[selectedNode].left);\r\n-\tvar rightExtreme = getTranslatedLocation(colDendroBars[selectedNode].right);\r\n-\tfor (var i = selectedNode; i > 0; i--){ // DRAW THE HORIZONTAL BARS FIRST\t\r\n-\t\tvar bar = colDendroBars[i];\r\n-\t\tvar leftLoc = getTranslatedLocation(bar.left/interval);\r\n-\t\tvar rightLoc = getTranslatedLocation(bar.right/interval);\r\n-\t\tvar height = bar.height;\r\n-\t\tif (rightLoc < leftExtreme || leftLoc > rightExtreme){ // if this bar isn\'t located within the extreme bounds, skip it\r\n-\t\t\tcontinue;\r\n-\t\t} else if (rightLoc > leftExtreme && leftLoc < leftExtreme ){ // if this bar starts in the extreme bounds, but goes beyond the current extreme, update the extreme value\r\n-\t\t\tleftExtreme = leftLoc;\r\n-\t\t} else if (leftLoc < rightExtreme && rightLoc > rightExtreme){\r\n-\t\t\trightExtreme = rightLoc;\r\n-\t\t}\r\n-\t\thighlightedBars.push(bar);\r\n-\t\tvar barLength = (rightLoc-leftLoc);\r\n-\t\tvar pos = startPos;\r\n-\t\tpos += leftLoc*BYTE_PER_RGBA;\t// get in the proper left location\r\n-\t\tpos += height*summaryTotalWidth*BYTE_PER_RGBA; // go to the proper height\r\n-\t\tfor (var j = 0; j < barLength; j++){ // draw line going across\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos += BYTE_PER_RGBA;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\tfor (var i = 0; i < highlightedBars.length; i++){// DRAW THE LINES GOING DOWN\r\n-\t\tvar bar = highlightedBars[i];\r\n-\t\tvar pos =  startPos;\r\n-\t\tvar leftLoc = getTranslatedLocation(bar.left/interval);\r\n-\t\tvar rightLoc = getTranslatedLocation(bar.right/interval);\r\n-\t\tvar height = bar.height;\r\n-\t\tpos += leftLoc*BYTE_PER_RGBA; // draw the left side lines\r\n-\t\tpos += (height-1)*summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\twhile (pos > startPos && dataBuffer[pos] == 3){\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos -= summaryTotalWidth*BYTE_PER_RGBA; // jump down to the next row until it hits a horizontal line\r\n-\t\t}\r\n-\t\tpos = startPos; // draw the right side lines\r\n-\t\tpos += rightLoc*BYTE_PER_RGBA;\r\n-\t\tpos += height*summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\twhile (pos > startPos && dataBuffer[pos] == 3){\r\n-\t\t\tdataBuffer[pos] = 200;\r\n-\t\t\tdataBuffer[pos+1] = 200;\r\n-\t\t\tdataBuffer[pos+2] = 3;\r\n-\t\t\tdataBuffer[pos+3] = 255;\r\n-\t\t\tpos -= summaryTotalWidth*BYTE_PER_RGBA;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\tvar matrixBottom = rowEmptySpace / canvas.height + leftCanvasBoxHorThick;\r\n-\tvar matrixRight = colEmptySpace / canvas.width + leftCanvasBoxVertThick;\r\n-\tvar leftMin = leftCanvasBoxVertThick + ((rowClassBarWidth+rowDendroHeight)/canvas.width);\r\n-\tvar topMin = leftCanvasBoxHorThick + ((colClassBarHeight+columnDendroHeight)/canvas.height);\r\n-\r\n-\tdendroBoxLeftTopArray = new Float32Array([leftExtreme/canvas.width+leftMin, 0]); \r\n-\tdendroBoxRightBottomArray = new Float32Array([rightExtreme/canvas.width+leftMin, 1-topMin]);\r\n-\t\r\n-\tselectedStart = leftExtreme;\r\n-\tselectedStop = rightExtreme;\r\n-}\r\n-\r\n-\r\n-function clearDendroSelection(){\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\tdrawRowDendrogram(TexPixels);\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/deflate.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/inflate.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/z-worker.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/zip.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/oldstatic/javascript/temp.js
--- a/naNGCHMheatmap/MDAheatmap/oldstatic/javascript/temp.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,49 +0,0 @@
-/**
- * 
- */
-
-function buildSomething () {
- var numRows = 10;
- var numCols = 10;
- var myMatrix = create2DArray(numRows, numCols);
-
- //Note 0 based - may need to modify for row - column ordering starting at 1
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Move data into a linear (texture) array - could change to colors at the same time
- var texture = new Array(numRows*numCols);
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- texture[row*numCols+col] = myMatrix[row][col];
- }
- }
-
- //For a sideways dendor - row dendro still do the 2D array normal way
- for (var row = 0; row < numRows; row++) {
- for (var col = 0; col < numCols; col++) {
- myMatrix[row][col] = Math.random();
- }
- }
-
- //Then pull out one column at a time to put on the front of each texture row.
- var currentRow = 7;
- var textureRow = new Array(1000);
- pos = 700;
- for (var row = 0; row < numRows; row++) {
- textureRow[pos + col] = myMatrix[row][7];
- }
-}
-
-
-
-function create2DArray(rows, columns) {
- var matrix = new Array(rows);
- for (var i = 0; i < rows; i++) {
- matrix[i] = new Array(columns);
- }
- return matrix;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/css/NGCHM.css
--- a/naNGCHMheatmap/MDAheatmap/static/css/NGCHM.css Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,291 +0,0 @@
-@CHARSET "ISO-8859-1";
-/**
- *  */
-
-
-body, html {
-    width:100%;
-    height:100%;
-    margin:0;
-    padding:0;
-    overflow:auto;
-    font-family: sans-serif;
-    font-family: arial;  
-    font-size: 15px;
-}
-
-div.mdaServiceHeader
-{
- float: none;
- width: 100%;
- height: 40px;
- color: #666;
- margin: 2px 0px 2px 0px;
- background-color: white;
- border-bottom: 4px solid #da0505;
- z-index: -1;
- overflow: hidden;
-}
-
-div.mdaServiceHeaderLogo
-{
- float: left;
- width: auto;
-}
-
-div.mdaServiceHeaderLogo img
-{
- height: 35px;
-}
-
-
-#divider{
- height: 82%;
- width: 5px;
- vertical-align:top;
- display:inline-block;
- background: #666666;
- cursor: ew-resize;
-}
-
-#summary_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    margin-left: 3px;
-    display:inline-block;
-}
-
-#summary_canvas {
-    height:82%;
-    width:98%;
- zIndex:1;
-}
-
-#classBarLabels{
- height:95%;
- width:95%;
- pointer-events:none;
-}
-
-#detail_chm {
-    height:100%;
-    width:48%;
-    vertical-align:top;
-    display:inline-block;
-}
-
-#detail_canvas {
-    height:82%;
-    width:90%;
- zIndex:1;
-}
-
-#detail_buttons {
- margin-top: 10px;
-}
-
-#chmFile {
- display: none
-}
-
-#helptext {
-    margin: 5px !important;
-    padding: 10px 10px 10px 10px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    min-width: 100px;
-    z-index: 10000;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-#helpprefs {
-    margin: 5px !important;
-    padding: 8px 8px 8px 8px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    z-index: 10000;
-    text-align: center;
-    height: auto;
-    width: auto;
-    box-shadow: 5px 5px 5px #777777;
-    white-space: nowrap;
-}
-
-#prefprefs {
- position: relative;
-    display: inline-block;
-}
-
-
-.input-color {
-    position: relative;
-}
-.input-color input {
-    padding-left: 0px;
-}
-.input-color .color-box {
-    width: 30px;
-    height: 15px;
-    display: inline-block;
-    background-color: #ccc;
-    position: absolute;
-    left: -8px;
-    top: -8px;
-}
-
-table {
-    width: 100%;
-}
-
-td {
-    height: 0px;
- padding: 0px;
-    font-size: 80% !important;
-    font-family: Arial;
-    font-weight: normal;
-    color: #0843c1;
-    vertical-align: center;
-}
-
-.searchItem{
- background-color: yellow;
-}
-
-#searchError{
- border: 1px solid #1a1a1a;
-    border-radius: 10px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: red;
-    position: absolute;
-    width: 180px;
-    z-index:10;
-    /* height: 50px; */
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-}
-
-.labelMenu{
-    border: 1px solid #1a1a1a;
-    border-radius: 10px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    width: 240px;
-    height: 150px;
-    text-align: center;
-    box-shadow: 5px 5px 5px #777777;
-    position:relative;
-}
-
-.labelMenuCaption{
- padding: .4em 1em;
- background: #0843c1;
- color: #ffffff;
- font-size: 90% !important;
-    font-family: Arial;
-    font-weight: bold;
-    text-align: left;
- border-top-left-radius: 10px;
-    border-top-right-radius: 10px;
-}
-
-.labelMenuClose{
- position: absolute;
- right: 2px;
- bottom:2px;
-}
-
-.labelMenuHeader tr{
- padding: 4em 1em;
- position:relative;
- margin: 0px 0px 0px 0px;
- background: #f8f3f1; 
- color: #0843c1;
- text-align: left;
- font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
- border-radius: 10px;
-}
-
-.labelMenuBody tr{
- height: 20px;
-}
-.labelMenuBody td{
- height:20px;
- position: absolute;
- font-size: 80% !important;
-    font-family: Arial;
-    font-weight: normal;
-    color: #0843c1;
-    cursor: pointer;
-}
-
-.labelMenuBody td:hover{
- font-weight: bold;
-}
-
-table.breakpointContainer {
-    border: none;
-    border-spacing: 0px;
-    border-collapse: collapse;
-}
-
-td.breakpointContainer
-th.breakpointContainer {
-    text-align: center;
-    margin: 0px;
-    padding: 0px 5px 0px 0px;
-    border-spacing: 0px;
-    border-collapse: collapse;    
-}
-
-#prefsPanel, #pdfPrefsPanel {
-    margin: 5px !important;
-    padding: 2px 2px 2px 2px !important;
-    border: 1px solid #1a1a1a;
-    border-radius: 15px;
-    font-size: 90% !important;
-    font-family: Arial;
-    font-weight: normal;
-    background: #dddddd;
-    color: #000000;
-    z-index: 10000;
-    text-align: center;
-    height: auto;
-    width: auto;
-    box-shadow: 5px 5px 5px #777777;
-    white-space: nowrap;
-}
-#prefsHeader, #pdfPrefsHeader{
-    display: table;
-    font-size: 18px;
-    font-weight: bold;
-    color: #0843c1;
-    margin: auto;
-    width: 100%;
-    height: 30px;
-    line-height: 30px;
-    text-align: center;
-    border-top-left-radius: 15px;
-    border-top-right-radius: 15px;
-    background: #CBD1EA;
-}
-
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/addButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/addButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/breakButtonOff.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/breakButtonOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/breakButtonOn.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/breakButtonOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/cancel.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/cancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/classButtonOff.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/classButtonOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/classButtonOn.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/classButtonOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/closeButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/closeButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOff.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOn.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/covariateBarsOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/createPdf.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/createPdf.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/dataLayersOff.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/dataLayersOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/dataLayersOn.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/dataLayersOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/filterClassButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/filterClassButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/full.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/full.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/full_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/full_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/gear.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/gear.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/gearDis.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/gearDis.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/gear_big.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/gear_big.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/go.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/go.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/join.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/join.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/mdandersonlogo260x85.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/mdandersonlogo260x85.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/minusButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/minusButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/next.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/next.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/pdf.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/pdf.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/plusButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/plusButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/prefApply.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/prefApply.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/prefBack.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/prefBack.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/prefCancel.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/prefCancel.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/prefSave.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/prefSave.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/prev.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/prev.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/removeFilterClassButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/removeFilterClassButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/ribbonH.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/ribbonH.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/ribbonH_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/ribbonH_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/ribbonV.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/ribbonV.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/ribbonV_selected.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/ribbonV_selected.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/rowsColsOff.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/rowsColsOff.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/rowsColsOn.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/rowsColsOn.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/save.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/save.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/searchButton.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/searchButton.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/split.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/split.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/zoom-in.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/zoom-in.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/images/zoom-out.png
b
Binary file naNGCHMheatmap/MDAheatmap/static/images/zoom-out.png has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/.gitignore
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/.gitignore Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-/temp.js
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/ColorMapManager.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/ColorMapManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,246 +0,0 @@
-
-function ColorMap(colorMapObj){
- var type = colorMapObj["type"];
- var thresholds;
- if (type == "quantile"){
- thresholds = colorMapObj["linearEquiv"];
- } else {
- thresholds = colorMapObj["thresholds"];
- }
- var numBreaks = thresholds.length;
-
- // Hex colors
- var colors = colorMapObj["colors"];
- var missingColor = colorMapObj["missing"];
-
- // RGBA colors
- var rgbaColors = [];
- var rgbaMissingColor;
-
- if (colorMapObj["rgbaColors"] != undefined){
- rgbaColors = colorMapObj["rgbaColors"];
- } else {
- for (var i =0; i<numBreaks; i++){
- rgbaColors[i] = hexToRgba(colors[i]);
- }
- }
-
- if (colorMapObj["rgbaMissingColor"] != undefined){
- rgbaMissingColors = colorMapObj["rgbaMissingColor"];
- } else {
- rgbaMissingColor = hexToRgba(missingColor);
- }
-
- this.getThresholds = function(){
- return thresholds;
- }
-
- this.setThresholds = function(newthresholds){
- thresholds = newthresholds;
- }
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeys: This function calculates and returns an
-  * array containing 10 continuous threshold breakpoint keys from the original thresholds 
-  * submitted.  It is used only for rendering a continuous classification bar help.  
-  **********************************************************************************/
- this.getContinuousThresholdKeys = function(){
-     var conThresh = new Array();
-     var bottomThresh = thresholds[0];
-     var threshSize = this.getContinuousThresholdKeySize();
-     //Add first threshold from original threshold list
-     conThresh.push(bottomThresh);
-     //Calculate and create "interim" 8 thresholds
-     for (var i = 1; i <= 8; i++){
-      conThresh.push(bottomThresh+Math.floor(threshSize*i));
-     }
-     //Add last threshold from original threshold list
-     conThresh.push(thresholds[thresholds.length - 1]);  
-     return conThresh;
- }
-
- /**********************************************************************************
-  * FUNCTION - getContinuousThresholdKeySize: This function calculates the size 
-  * separating each "interim" threshold key for a continuous classification bar.  
-  **********************************************************************************/
- this.getContinuousThresholdKeySize = function(){
-     var bottomThresh = thresholds[0];
-     var topThresh = thresholds[thresholds.length - 1]; 
-     return (topThresh - bottomThresh) / 8;
- }
-
- this.getColors = function(){
- return colors;
- }
- this.setColors = function(newcolors){
- colors = newcolors;
- }
- this.getType = function(){
- return type;
- }
- this.getMissingColor = function(){
- return missingColor;
- }
- this.setMissingColor = function(color){
- missingColor = color;
- }
-
-
- // returns an RGBA value from the given value
- this.getColor = function(value){
- var color;
-
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else if(value < thresholds[0]){
- color = rgbaColors[0]; // return color for lowest threshold if value is below range
- } else if (value >= thresholds[numBreaks-1]){
- color = rgbaColors[numBreaks-1]; // return color for highest threshold if value is above range
- } else {
- var bounds = findBounds(value, thresholds);
- color = blendColors(value, bounds);
- }
-
- return color;
- }
-
- this.getClassificationColor = function(value){
- var color;
- if (type == "discrete"){
- for (var i = 0; i < thresholds.length; i++){
- if (value == thresholds[i]){
- color = rgbaColors[i];
- return color;
- }
- }
- return rgbaMissingColor;
- } else {
- if (isNaN(value)){
- color = rgbaMissingColor;
- }else{
- color = this.getColor(value);
- }
- }
-
- return color;
- }
-
- this.addBreakpoint = function(value,color){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],0,value);
- colors.splice(bounds["lower"],0,color);
- rgbaColors.splice(bounds["lower"],0,hexToRgba(color));
- }
-
- this.changeBreakpoint = function(value,newColor){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1,value);
- colors.splice(bounds["lower"],1,newColor);
- rgbaColors.splice(bounds["lower"],1,hexToRgba(newColor));
- }
-
- this.removeBreakpoint = function(value){
- var bounds = findBounds(value, thresholds);
- thresholds.splice(bounds["lower"],1);
- colors.splice(bounds["lower"],1);
- rgbaColors.splice(bounds["lower"],1);
- }
-
- //===========================//
- // internal helper functions //
- //===========================//
-
- function findBounds(value, thresholds){
- var bounds = {};
- var i =0;
- while (i<numBreaks){
- if (thresholds[i] <= value && value < thresholds[i+1]){
- bounds["upper"] = i+1;
- bounds["lower"] = i;
- break;
- }
- i++;
- }
- return bounds;
- }
-
- function blendColors(value, bounds){
- var ratio = (value - thresholds[bounds["lower"]])/(thresholds[bounds["upper"]]-thresholds[bounds["lower"]]);
- var lowerColor = rgbaColors[bounds["lower"]];
- var upperColor = rgbaColors[bounds["upper"]];
- // lowerColor and upperColor should be in { r:###, g:###, b:### } format
- var color = {};
- color["r"] = Math.round(lowerColor["r"] * (1.0 - ratio) + upperColor["r"] * ratio);
-     color["g"] = Math.round(lowerColor["g"] * (1.0 - ratio) + upperColor["g"] * ratio);
-     color["b"] = Math.round(lowerColor["b"] * (1.0 - ratio) + upperColor["b"] * ratio);
-     color["a"] = 255;
-     return color;
- }
-
- function hexToRgba(hex) { // I didn't write this function. I'm not that clever. Thanks stackoverflow
-     var rgbColor = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
-     return rgbColor ? {
-         r: parseInt(rgbColor[1], 16),
-         g: parseInt(rgbColor[2], 16),
-         b: parseInt(rgbColor[3], 16),
-         a: 255
-     } : null;
- }
-
- this.getHexToRgba = function(hex){
- return hexToRgba(hex);
- }
-
- this.getRgbToHex = function(rgb) {
- var a = rgb.a
- var r = rgb.r
- var g = rgb.g
- var b = rgb.b
-     return ('#' + componentToHex(r) + componentToHex(g) + componentToHex(b));
- }
-
- function componentToHex(c) {
-     var hex = c.toString(16);
-     return hex.length == 1 ? "0" + hex : hex;
- }
-
-}
-
-// All color maps and current color maps are stored here.
-function ColorMapManager(colorMaps){
-
- var colorMapCollection = colorMaps.colormaps;
-
- var mainColorMap;
- var flickColorMap;
-
- this.getMainColorMap = function(){
- return mainColorMap;
- }
-
- this.setMainColorMap = function(colorMapName){
- mainColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return mainColorMap;
- }
-
-
- this.getFlickColorMap = function(){
- return flickColorMap;
- }
-
- this.setFlickColorMap = function(colorMapName){
- flickColorMap = new ColorMap(colorMapCollection[colorMapName]);
- return flickColorMap;
- }
-
- this.getColorMap = function(colorMapName){
- var colorMap = new ColorMap(colorMapCollection[colorMapName]);
- return colorMap;
- }
-
- this.setColorMap = function(colorMapName, colorMap){
- colorMapCollection[colorMapName].colors = colorMap.getColors();
- colorMapCollection[colorMapName].thresholds = colorMap.getThresholds();
- colorMapCollection[colorMapName].missing = colorMap.getMissingColor();
- }
-
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/DetailHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/DetailHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1616 +0,0 @@\n-var detCanvas;\r\n-var det_gl; // WebGL contexts\r\n-var detTextureParams;\r\n-var labelElement; \r\n-var old_mouse_pos = [0, 0];\r\n-\r\n-\r\n-var detCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var detCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var detCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var detCanvasTranslateArray = new Float32Array([0, 0]);\r\n-\r\n-var detTexPixels;\r\n-var detTexPixelsCache;\r\n-\r\n-var detUScale;\r\n-var detUTranslate;\r\n-var detUBoxLeftTop;\r\n-var detUBoxRightBottom;\r\n-var detUBoxThickness;\r\n-var detUBoxColor;\r\n-\r\n-var detEventTimer = 0; // Used to delay draw updates\r\n-\r\n-var saveRow;\r\n-var saveCol;\r\n-var dataBoxHeight;\r\n-var dataBoxWidth;\r\n-\r\n-\r\n-var detailDendroHeight = 105;\r\n-var detailDendroWidth = 105;\r\n-var normDetailDendroMatrixHeight = 200;\r\n-var rowDetailDendroMatrix,colDetailDendroMatrix;\r\n-var DETAIL_SIZE_NORMAL_MODE = 502;\r\n-var detailDataViewHeight = 502;\r\n-var detailDataViewWidth = 502;\r\n-var detailDataViewBoarder = 2;\r\n-var zoomBoxSizes = [1,2,4,5,10,20,25,50];\r\n-var labelSizeLimit = 8;\r\n-var currentSearchItem;\r\n-var labelLastClicked;\r\n-\r\n-var mouseDown = false;\r\n-var dragOffsetX;\r\n-var dragOffsetY;\r\n-var detailPoint;\r\n-var detailGrid = true;\r\n-\r\n-var mode = \'NORMAL\';\r\n-var isDrawn = false;\r\n-\r\n-//Call once to hook up detail drawing routines to a heat map and initialize the webGl \r\n-function initDetailDisplay() {\r\n-\tdetCanvas = document.getElementById(\'detail_canvas\');\r\n-\tlabelElement = document.getElementById(\'labelDiv\');\r\n-\r\n-\tif (isSub) {\r\n- \t\tdocument.getElementById(\'summary_chm\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'divider\').style.display = \'none\';\r\n- \t\tdocument.getElementById(\'detail_chm\').style.width = \'100%\';\r\n- \t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n- \t\tdocument.getElementById(\'split_btn\').src= staticPath + "images/join.png";\r\n- \t\tdocument.getElementById(\'gear_btn\').src= staticPath + "images/gearDis.png";\r\n- \t\tdocument.getElementById(\'pdf_btn\').style.display = \'none\';\r\n-\t}\r\n-\t\r\n-\tif (dataBoxWidth === undefined) {\r\n-\t\tsetDetailDataSize(10);\r\n-\t}\r\n-\tif (heatMap.isInitialized() > 0) {\r\n-\t\tdocument.getElementById(\'detail_buttons\').style.display = \'\';\r\n-\t\tdetCanvas.width =  (detailDataViewWidth + calculateTotalClassBarHeight("row") + detailDendroWidth);\r\n-\t\tdetCanvas.height = (detailDataViewHeight + calculateTotalClassBarHeight("column") + detailDendroHeight);\r\n-\t\tdetSetupGl();\r\n-\t\tdetInitGl();\r\n-\t\tcreateLabelMenus();\r\n-\t\tupdateSelection();\r\n-\t}\r\n-\t\t\r\n-\tdetCanvas.onmousedown = clickStart;\r\n-\tdocument.onmouseup = clickEnd;\r\n-\tdetCanvas.onmousemove = handleMove;\r\n-\tdetCanvas.onmouseleave = userHelpClose;\r\n-\tdocument.addEventListener("touchmove", function(e){\r\n-\t\te.preventDefault();\r\n-\t\tif (e.touches){\r\n-\t    \tif (e.touches.length > 1){\r\n-\t    \t\treturn false;\r\n-\t    \t}\r\n-\t    }\r\n-\t})\r\n-\tdetCanvas.addEventListener("touchstart", function(e){\r\n-\t\tuserHelpClose();\r\n-\t\tclickStart(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchmove", function(e){\r\n-\t\te.stopPropagation();\r\n-\t\te.preventDefault();\r\n-\t\thandleMove(e);\r\n-\t}, false);\r\n-\tdetCanvas.addEventListener("touchend", function(e){clickEnd(e)}, false);\r\n-\t\r\n-\tdetCanvas.addEventListener("gestureend",function(e){\r\n-\t\tif (e.scale > 1){\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\t} else if (e.scale < 1){\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\t}\r\n-\t},false)\r\n-\t\r\n-\t\r\n-\tdocument.onkeydown = keyNavigate;\r\n-}\r\n-\r\n-function clickStart(e){\r\n-\tuserHelpClose();\r\n-\tdragOffsetX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tdragOffsetY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\r\n-    mouseDown = true;\r\n-}\r\n-function clickEnd(e){\r\n-\tmouseDown = false;\r\n-\tvar dragEndX = e.touches ? e.touches[0].pageX : e.pageX;\r\n-\tvar dragEndY = e.touches ? e.touches[0].pageY : e.pageY;\r\n-\tvar rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width;\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\tif (Math.abs(dragEndX - dragOffsetX) < colElementSize/10 && Math.abs(dra'..b'\t \'uniform float u_box_thickness;  \' +\r\n- \t\t \t\t \'uniform vec4 u_box_color;       \' +\r\n- \t\t \t\t \'void main () {                  \' +\r\n- \t\t \t\t \'  vec2 difLeftTop = v_texPosition - u_box_left_top; \' +\r\n- \t\t \t\t \'  vec2 difRightBottom = v_texPosition - u_box_right_bottom; \' +\r\n- \t\t \t\t \'  if (v_texPosition.y >= u_box_left_top.y && v_texPosition.y <= u_box_right_bottom.y) { \' +\r\n- \t\t \t\t \'    if ((difLeftTop.x <= u_box_thickness && difLeftTop.x >= -u_box_thickness) ||  \' +\r\n- \t\t \t\t \'        (difRightBottom.x <= u_box_thickness && difRightBottom.x >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'      gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'    } else { \' +\r\n- \t\t \t\t \'      gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'    } \' +\r\n- \t\t \t\t \'  } else if (v_texPosition.x >= u_box_left_top.x && v_texPosition.x <= u_box_right_bottom.x) { \' +\r\n- \t\t \t\t \'\t  if ((difLeftTop.y <= u_box_thickness && difLeftTop.y >= -u_box_thickness) || \' +\r\n- \t\t \t\t \'\t      (difRightBottom.y <= u_box_thickness && difRightBottom.y >= -u_box_thickness)) { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = u_box_color; \' +\r\n- \t\t \t\t \'\t  } else { \' +\r\n- \t\t \t\t \'\t    gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t  } \' +\r\n- \t\t \t\t \'\t} else { \' +\r\n- \t\t \t\t \'\t  gl_FragColor = texture2D(u_texture, v_texPosition); \' +\r\n- \t\t \t\t \'\t} \' +\r\n- \t\t \t\t \'}\'; \r\n-\r\n-\r\n-\tvar shader = theGL.createShader(theGL.FRAGMENT_SHADER);;\r\n-\ttheGL.shaderSource(shader, source);\r\n-\ttheGL.compileShader(shader);\r\n-\tif (!theGL.getShaderParameter(shader, theGL.COMPILE_STATUS)) {\r\n-        alert(theGL.getShaderInfoLog(shader));\r\n-    }\r\n-\r\n-\treturn shader;\r\n-}\r\n-\r\n-\r\n-\r\n-function detInitGl () {\r\n-\tdet_gl.viewport(0, 0, det_gl.viewportWidth, det_gl.viewportHeight);\r\n-\tdet_gl.clear(det_gl.COLOR_BUFFER_BIT);\r\n-\r\n-\t// Vertices\r\n-\tvar buffer = det_gl.createBuffer();\r\n-\tdet_gl.buffer = buffer;\r\n-\tdet_gl.bindBuffer(det_gl.ARRAY_BUFFER, buffer);\r\n-\tvar vertices = [ -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, 1 ];\r\n-\tdet_gl.bufferData(det_gl.ARRAY_BUFFER, new Float32Array(vertices), det_gl.STATIC_DRAW);\r\n-\tvar byte_per_vertex = Float32Array.BYTES_PER_ELEMENT;\r\n-\tvar component_per_vertex = 2;\r\n-\tbuffer.numItems = vertices.length / component_per_vertex;\r\n-\tvar stride = component_per_vertex * byte_per_vertex;\r\n-\tvar program = det_gl.program;\r\n-\tvar position = det_gl.getAttribLocation(program, \'position\');\r\n-\tdetUScale = det_gl.getUniformLocation(program, \'u_scale\');\r\n-\tdetUTranslate = det_gl.getUniformLocation(program, \'u_translate\');\r\n-\tdetUBoxLeftTop = det_gl.getUniformLocation(program, \'u_box_left_top\');\r\n-\tdetUBoxRightBottom = det_gl.getUniformLocation(program, \'u_box_right_bottom\');\r\n-\tdetUBoxThickness = det_gl.getUniformLocation(program, \'u_box_thickness\');\r\n-\tdetUBoxColor = det_gl.getUniformLocation(program, \'u_box_color\');\r\n-\tdet_gl.enableVertexAttribArray(position);\r\n-\tdet_gl.vertexAttribPointer(position, 2, det_gl.FLOAT, false, stride, 0);\r\n-\r\n-\t// Texture\r\n-\tvar texture = det_gl.createTexture();\r\n-\tdet_gl.bindTexture(det_gl.TEXTURE_2D, texture);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_S, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_WRAP_T, \r\n-\t\t\tdet_gl.CLAMP_TO_EDGE);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MIN_FILTER,\r\n-\t\t\tdet_gl.NEAREST);\r\n-\tdet_gl.texParameteri(\r\n-\t\t\tdet_gl.TEXTURE_2D, \r\n-\t\t\tdet_gl.TEXTURE_MAG_FILTER, \r\n-\t\t\tdet_gl.NEAREST);\r\n-\t\r\n-\tdetTextureParams = {};\r\n-\r\n-\tvar texWidth = null, texHeight = null, texData;\r\n-\ttexWidth = detailDataViewWidth + calculateTotalClassBarHeight("row")+detailDendroWidth;\r\n-\ttexHeight = detailDataViewHeight + calculateTotalClassBarHeight("column")+detailDendroHeight;\r\n-\ttexData = new ArrayBuffer(texWidth * texHeight * 4);\r\n-\tdetTexPixels = new Uint8Array(texData);\r\n-\tdetTextureParams[\'width\'] = texWidth;\r\n-\tdetTextureParams[\'height\'] = texHeight; \r\n-}\r\n-\r\n-function toggleGrid(){\r\n-\tdetailGrid = !detailGrid;\r\n-\tdrawDetailHeatMap();\r\n-}\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/MatrixManager.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/MatrixManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,568 +0,0 @@\n-//\r\n-// MatrixManager is responsible for retrieving clustered heat map data.  Heat map\r\n-// data is available at different \'zoom\' levels - Summary, Ribbon Vertical, Ribbon\r\n-// Horizontal, and Full.  To use this code, create MatrixManger by calling the \r\n-// MatrixManager function.  The MatrixManager lets you retrieve a HeatmapData object\r\n-// given a heat map name and summary level.  The HeatMapData object has various\r\n-// attributes of the map including the size an number of tiles the map is broken up \r\n-// into.  getTile() is called on the HeatmapData to get each tile of the data.  Tile\r\n-// retrieval is asynchronous so you need to provide a callback that is triggered when\r\n-// the tile is retrieved.\r\n-//\r\n-\r\n-//Supported map data summary levels.\r\n-MatrixManager.THUMBNAIL_LEVEL = \'tn\';\r\n-MatrixManager.SUMMARY_LEVEL = \'s\';\r\n-MatrixManager.RIBBON_VERT_LEVEL = \'rv\';\r\n-MatrixManager.RIBBON_HOR_LEVEL = \'rh\';\r\n-MatrixManager.DETAIL_LEVEL = \'d\';\r\n-\r\n-MatrixManager.WEB_SOURCE = \'W\';\r\n-MatrixManager.FILE_SOURCE = \'F\';\r\n-\r\n-MatrixManager.Event_INITIALIZED = \'Init\';\r\n-MatrixManager.Event_JSON = \'Json\';\r\n-MatrixManager.Event_NEWDATA = \'NewData\';\r\n-\r\n-\r\n-//Create a MatrixManager to retrieve heat maps. \r\n-//Need to specify a mode of heat map data - \r\n-//web server or local file.\r\n-function MatrixManager(mode){\r\n-\t\r\n-\t//Main function of the matrix manager - retrieve a heat map object.\r\n-\t//mapFile parameter is only used for local file based heat maps.\r\n-\tthis.getHeatMap = function (heatMapName, updateCallback, mapFile) {\r\n-\t\treturn  new HeatMap(heatMapName, updateCallback, mode, mapFile);\r\n-\t}\t\r\n-};    \t\r\n-\r\n-\r\n-//HeatMap Object - holds heat map properties and a tile cache\r\n-//Used to get HeatMapData object.\r\n-//ToDo switch from using heat map name to blob key?\r\n-function HeatMap (heatMapName, updateCallback, mode, chmFile) {\r\n-\t//This holds the various zoom levels of data.\r\n-\tvar datalayers = {};\r\n-\tvar tileCache = {};\r\n-\tvar zipFiles = {};\r\n-\tvar colorMaps = null;\r\n-\tvar colorMapMgr;\r\n-\tvar classifications = null;\r\n-\tvar rowLabels = null;\r\n-\tvar colLabels = null;\r\n-\tvar dendrogram = null;\r\n-\tvar chm = null;\r\n-\tvar initialized = 0;\r\n-\tvar eventListeners = [];\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.isSaveAllowed = function(){\r\n-\t\tif (mode === "F") {\r\n-\t\t\treturn false;\r\n-\t\t} else {\r\n-\t\t\treturn true;\r\n-\t\t}\r\n-\t}\r\n-\t\r\n-\t//Return the number of rows for a given level\r\n-\tthis.getNumRows = function(level){\r\n-\t\treturn datalayers[level].totalRows;\r\n-\t}\r\n-\t\r\n-\t//Return the number of columns for a given level\r\n-\tthis.getNumColumns = function(level){\r\n-\t\treturn datalayers[level].totalColumns;\r\n-\t}\r\n-\t\r\n-\t//Return the row summary ratio for a given level\r\n-\tthis.getRowSummaryRatio = function(level){\r\n-\t\treturn datalayers[level].rowSummaryRatio;\r\n-\t}\r\n-\t\r\n-\t//Return the column summary ratio for a given level\r\n-\tthis.getColSummaryRatio = function(level){\r\n-\t\treturn datalayers[level].colSummaryRatio;\r\n-\t}\r\n-\t\r\n-\t//Get a data value in a given row / column\r\n-\tthis.getValue = function(level, row, column) {\r\n-\t\treturn datalayers[level].getValue(row,column);\r\n-\t}\r\n-\t\r\n-\tthis.saveHeatMapProperties = function () {\r\n-\t\tvar success = saveMapProperties("colorMap",JSON.stringify(colorMaps));\r\n-\t\tif (success !== "false") {\r\n-\t\t\tsaveMapProperties("classifications",JSON.stringify(classifications));\r\n-\t\t} \r\n-\t\tif (success !== "false") {\r\n-\t\t\tsaveMapProperties("dendrogram",JSON.stringify(dendrogram));\r\n-\t\t} \r\n-\t\treturn success;\r\n-\t}\r\n-\t\r\n-\t//This function is used to set a read window for high resolution data layers.\r\n-\t//Calling setReadWindow will cause the HeatMap object to retrieve tiles needed\r\n-\t//for reading this area if the tiles are not already in the cache.\r\n-    this.setReadWindow = function(level, row, column, numRows, numColumns) {\r\n-  \t//Thumb nail and summary level are always kept in the cache.  Don\'t do fetch for them.\r\n-  \tif (level != MatrixManager.THUMBNAIL_LEVEL && level != MatrixManager.SUMMARY_LEVEL)\r\n-  \t\tdata'..b' to fetch a json file from server.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction webFetchJson(jsonFile, setterFunction) {\r\n-\t\tvar req = new XMLHttpRequest();\r\n-\t\treq.open("GET", "GetDescriptor?map=" + heatMapName + "&type=" + jsonFile, true);\r\n-\t\treq.onreadystatechange = function () {\r\n-\t\t\tif (req.readyState == req.DONE) {\r\n-\t\t        if (req.status != 200) {\r\n-\t\t            console.log(\'Failed to get json file \' + jsonFile + \' for \' + heatMapName + \' from server: \' + req.status);\r\n-\t\t        } else {\r\n-\t\t        \t//Got the result - call appropriate setter.\r\n-\t\t        \tsetterFunction(JSON.parse(req.response));\r\n-\t\t\t    }\r\n-\t\t\t}\r\n-\t\t};\r\n-\t\treq.send();\r\n-\t}\r\n-\t\r\n-\t//Helper function to fetch a json file from zip file.  \r\n-\t//Specify which file to get and what funciton to call when it arrives.\r\n-\tfunction zipFetchJson(jsonFile, setterFunction) {\r\n-\t\tzipFiles[heatMapName + "/" + jsonFile].getData(new zip.TextWriter(), function(text) {\r\n-\t\t\t// got the json, now call the appropriate setter\r\n-\t\t\tsetterFunction(JSON.parse(text));\r\n-\t\t}, function(current, total) {\r\n-\t\t\t// onprogress callback\r\n-\t\t});\r\n-\t}\r\n-\t\r\n-};\r\n-\r\n-\r\n-//Internal object for traversing the data at a given zoom level.\r\n-function HeatMapData(heatMapName, level, jsonData, lowerLevel, tileCache, getTile) {\t\r\n-\tthis.totalRows = jsonData.total_rows;\r\n-\tthis.totalColumns = jsonData.total_cols;\r\n-    var numTileRows = jsonData.tile_rows;\r\n-    var numTileColumns = jsonData.tile_cols;\r\n-    var rowsPerTile = jsonData.rows_per_tile;\r\n-    var colsPerTile = jsonData.cols_per_tile;\r\n-    this.rowSummaryRatio = jsonData.row_summary_ratio;\r\n-    this.colSummaryRatio = jsonData.col_summary_ratio;\r\n-\tvar rowToLower = (lowerLevel === null ? null : this.totalRows/lowerLevel.totalRows);\r\n-\tvar colToLower = (lowerLevel === null ? null : this.totalColumns/lowerLevel.totalColumns);\r\n-\t\r\n-\t//Get a value for a row / column.  If the tile with that value is not available, get the down sampled value from\r\n-\t//the lower data level.\r\n-\tthis.getValue = function(row, column) {\r\n-\t\t//Calculate which tile holds the row / column we are looking for.\r\n-\t\tvar tileRow = Math.floor((row-1)/rowsPerTile) + 1;\r\n-\t\tvar tileCol = Math.floor((column-1)/colsPerTile) + 1;\r\n-\t\tarrayData = tileCache[level+"."+tileRow+"."+tileCol];\r\n-\r\n-\t\t//If we have the tile, use it.  Otherwise, use a lower resolution tile to provide a value.\r\n-\t    if (arrayData != undefined) {\r\n-\t    \t//for end tiles, the # of columns can be less than the colsPerTile - figure out the correct num columns.\r\n-\t\t\tvar thisTileColsPerRow = tileCol == numTileColumns ? ((this.totalColumns % colsPerTile) == 0 ? colsPerTile : this.totalColumns % colsPerTile) : colsPerTile; \r\n-\t\t\t//Tile data is in one long list of numbers.  Calculate which position maps to the row/column we want.\r\n-\t    \treturn arrayData[(row-1)%rowsPerTile * thisTileColsPerRow + (column-1)%colsPerTile];\r\n-\t    } else if (lowerLevel != null) {\r\n-\t    \treturn lowerLevel.getValue(Math.floor(row/rowToLower) + 1, Math.floor(column/colToLower) + 1);\r\n-\t    } else {\r\n-\t    \treturn 0;\r\n-\t    }\t\r\n-\t};\r\n-\r\n-\t// External user of the matix data lets us know where they plan to read.\r\n-\t// Pull tiles for that area if we don\'t already have them.\r\n-    this.setReadWindow = function(row, column, numRows, numColumns) {\r\n-    \tvar startRowTile = Math.floor(row/rowsPerTile) + 1;\r\n-    \tvar startColTile = Math.floor(column/colsPerTile) + 1;\r\n-    \tvar endRowCalc = (row+(numRows-1))/rowsPerTile;\r\n-    \tvar endColCalc = (column+(numColumns-1))/colsPerTile;\r\n-\t\tvar endRowTile = Math.floor(endRowCalc)+(endRowCalc%1 > 0 ? 1 : 0);\r\n-\t\tvar endColTile = Math.floor(endColCalc)+(endColCalc%1 > 0 ? 1 : 0);\r\n-    \t\r\n-    \tfor (var i = startRowTile; i <= endRowTile; i++) {\r\n-    \t\tfor (var j = startColTile; j <= endColTile; j++) {\r\n-    \t\t\tif (tileCache[level+"."+i+"."+j] === undefined)\r\n-    \t\t\t\tgetTile(level, i, j);\r\n-    \t\t}\r\n-    \t}\r\n-    }\r\n-\r\n-};\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/NGCHM_Util.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/NGCHM_Util.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,34 +0,0 @@
-/**
- * General purpose javascript helper funcitons
- */
-
-//Get a value for a parm passed in the URL.
-function getURLParameter(name) {
-  return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||''
-}
-
-/**********************************************************************************
- * FUNCTION - toTitleCase: The purpose of this function is to change the case of
- * the first letter of the first word in each sentence passed in.
- **********************************************************************************/
-function toTitleCase(string)
-{
-    // \u00C0-\u00ff for a happy Latin-1
-    return string.toLowerCase().replace(/_/g, ' ').replace(/\b([a-z\u00C0-\u00ff])/g, function (_, initial) {
-        return initial.toUpperCase();
-    }).replace(/(\s(?:de|a|o|e|da|do|em|ou|[\u00C0-\u00ff]))\b/ig, function (_, match) {
-        return match.toLowerCase();
-    });
-}
-
-/**********************************************************************************
- * FUNCTION - getStyle: The purpose of this function is to return the style 
- * property requested for a given screen object.
- **********************************************************************************/
-function getStyle(x,styleProp){
-    if (x.currentStyle)
-        var y = x.currentStyle[styleProp];
-    else if (window.getComputedStyle)
-        var y = document.defaultView.getComputedStyle(x,null).getPropertyValue(styleProp);
-    return y;
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/PdfGenerator.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/PdfGenerator.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,389 +0,0 @@\n-function openPdfPrefs(e){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\tvar prefspanel = document.getElementById(\'pdfPrefsPanel\');\r\n-\t//Add prefspanel table to the main preferences DIV and set position and display\r\n-\tprefspanel.style.top = e.offsetTop + 15;\r\n-\tprefspanel.style.display="inherit";\r\n-\tprefspanel.style.left = e.offsetLeft - prefspanel.clientWidth;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - getPDF: This function is called when the "create pdf" button is pressed.\r\n- * It will check the checkboxes/radio buttons to see how the PDF is to be created using\r\n- * the isChecked function. for a full list of jsPDF functions, visit here:\r\n- * https://mrrio.github.io/jsPDF/doc/symbols/jsPDF.html#setLineCap\r\n- **********************************************************************************/\r\n-function getPDF(){\r\n-\t// canvas elements need to be converted to DataUrl to be loaded into PDF\r\n-\tupdateSelection(); // redraw the canvases because otherwise they can show up blank\r\n-\tvar sumImgData = canvas.toDataURL(\'image/png\');\r\n-\tvar detImgData = detCanvas.toDataURL(\'image/png\');\r\n-\tvar mapsToShow = isChecked("pdfInputSummaryMap") ? "S" : isChecked("pdfInputDetailMap") ? "D" : "B";\r\n-\tvar doc = isChecked("pdfInputPortrait") ? new jsPDF("p","pt") :new jsPDF("l","pt"); // landscape or portrait?\r\n-\tvar pageHeight = doc.internal.pageSize.height;\r\n-\tvar pageWidth = doc.internal.pageSize.width;\r\n-\t\r\n-\tdoc.setFont("times");\r\n-//\tdoc.setFont("helvetica");\r\n-\t// convert longest label units to actual length (11 is the max font size of the labels)\r\n-\t// these will be the bottom and left padding space for the detail Heat Map\r\n-\tvar allLabels = document.getElementsByClassName("DynamicLabel");\r\n-\tvar longestRowLabelUnits = 10, longestColLabelUnits = 5;\r\n-\tfor (var i = 0; i < allLabels.length; i++){ // go through all the labels and find the one that takes the most space\r\n-\t\tvar label = allLabels[i];\r\n-\t\tif (label.getAttribute(\'axis\') == "Row"){\r\n-\t\t\tlongestRowLabelUnits = Math.max(doc.getStringUnitWidth(label.innerHTML),longestRowLabelUnits);\r\n-\t\t} else {\r\n-\t\t\tlongestColLabelUnits = Math.max(doc.getStringUnitWidth(label.innerHTML),longestColLabelUnits);\r\n-\t\t}\r\n-\t}\r\n-\tlongestColLabelUnits *= 11;\r\n-\tlongestRowLabelUnits *= 11;\r\n-\t\r\n-\t// header\r\n-\tvar headerCanvas = document.createElement(\'CANVAS\'); // load the MDAnderson logo into a canvas, since you can\'t load an img directly\r\n-\tvar headerCtx = headerCanvas.getContext(\'2d\'); \r\n-\tvar header = document.getElementsByClassName(\'mdaServiceHeaderLogo\')[0];\r\n-\theaderCanvas.height = 85; // logo png\'s actual dimensions\r\n-\theaderCanvas.width = 260;\r\n-\theaderCtx.drawImage(header.children[0], 0, 0);\r\n-\tvar headerData = headerCanvas.toDataURL(\'image/png\');\r\n-\tvar headerHeight = header.clientHeight + 5;\r\n-\tcreateHeader();\r\n-\t\r\n-\t// maps\r\n-\tvar paddingLeft = 5, paddingTop = headerHeight+10; // these are the variables that we will be using repeatedly to place items\r\n-\tvar sumImgW,sumImgH,detImgW,detImgH;\r\n-\tvar detImgL = paddingLeft;\r\n-\tif (mapsToShow == "S"){\r\n-\t\tsumImgW = pageWidth - 2*paddingLeft, sumImgH = pageHeight - paddingTop - 2*paddingLeft;\r\n-\t\tdoc.addImage(sumImgData, \'PNG\', paddingLeft, paddingTop, sumImgW,sumImgH);\r\n-\t} else if (mapsToShow == "D"){\r\n-\t\tdetImgW = pageWidth - 2*paddingLeft - longestRowLabelUnits, detImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\tdoc.addImage(detImgData, \'PNG\', paddingLeft, paddingTop, detImgW,detImgH);\r\n-\t} else {\r\n-\t\tif (!isChecked("pdfInputPages")){\r\n-\t\t\tsumImgW = (pageWidth - longestRowLabelUnits - 2*paddingLeft)/2, sumImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\t\tdetImgW = (pageWidth - longestRowLabelUnits - 2*paddingLeft)/2, detImgH = pageHeight - paddingTop - longestColLabelUnits;\r\n-\t\t\tdetImgL = sumImgW + 2*paddingLeft;\r\n-\t\t\tdoc.addImage(sumImgData, \'PNG\', paddingLeft, paddingTop, sumImgW,sumImgH);\r\n-\t\t\tdoc.addImage(detImgData, \'PNG\', detImgL, paddingTop, detImg'..b'ds = colorMap.getThresholds();\r\n-\t\tvar barHeight = !condenseClassBars ? classBarFigureH/(thresholds.length+1) : 10;\r\n-\t\tvar counts = {}, maxCount = 0, maxLabelLength = doc.getStringUnitWidth("Missing Value")*classBarLegendTextSize;\r\n-\t\t// get the number N in each threshold\r\n-\t\tfor(var i = 0; i< classBar.values.length; i++) {\r\n-\t\t    var num = classBar.values[i];\r\n-\t\t    counts[num] = counts[num] ? counts[num]+1 : 1;\r\n-\t\t}\r\n-\t\tfor (var val in counts){\r\n-\t\t\tmaxCount = Math.max(maxCount, counts[val]);\r\n-\t\t\tmaxLabelLength = Math.max(maxLabelLength, doc.getStringUnitWidth(val.length)*classBarLegendTextSize);\r\n-\t\t}\r\n-\t\t\t\r\n-\t\tvar bartop = topOff+5;\r\n-\t\t//\xc2\xa0NOTE: missingCount will contain all elements that are not accounted for in the thresholds\r\n-\t\t// ie: thresholds = [type1, type2, type3], typeX will get included in the missingCount\r\n-\t\tvar missingCount = classBar.values.length;\r\n-\t\t// draw the bars\r\n-\t\tfor (var j = 0; j < thresholds.length; j++){ // make a gradient stop (and also a bucket for continuous)\r\n-\t\t\tvar rgb = colorMap.getClassificationColor(thresholds[j]);\r\n-\t\t\tdoc.setFillColor(rgb.r,rgb.g,rgb.b);\r\n-\t\t\tdoc.setDrawColor(0,0,0);\r\n-\t\t\tif (condenseClassBars){\r\n-\t\t\t\tvar barW = 10;\r\n-\t\t\t\tdoc.rect(leftOff, bartop, barW, barHeight, "FD");\r\n-\t\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\t\tdoc.text(leftOff +barW + 5, bartop + classBarLegendTextSize, thresholds[j].toString() + "   " + "n = " + counts[thresholds[j]] , null);\r\n-\t\t\t} else {\r\n-\t\t\t\tvar barW = counts[thresholds[j]]/maxCount*classBarFigureW;\r\n-\t\t\t\tdoc.rect(leftOff + maxLabelLength, bartop, barW, barHeight, "FD");\r\n-\t\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\t\tdoc.text(leftOff + maxLabelLength - doc.getStringUnitWidth(thresholds[j].toString())*classBarLegendTextSize - 4, bartop + barHeight/2, thresholds[j].toString() , null);\r\n-\t\t\t\tdoc.text(leftOff + maxLabelLength +barW + 5, bartop + barHeight/2, "n = " + counts[thresholds[j]] , null);\r\n-\t\t\t}\r\n-\t\t\t\r\n-\t\t\tmissingCount -= counts[thresholds[j]];\r\n-\t\t\tbartop+=barHeight;\r\n-\t\t}\r\n-\t\t\t\r\n-\t\tvar rgb = colorMap.getClassificationColor("Missing Value");\r\n-\t\tdoc.setFillColor(rgb.r,rgb.g,rgb.b);\r\n-\t\tdoc.setDrawColor(0,0,0);\r\n-\t\tif (condenseClassBars){\r\n-\t\t\tvar barW = 10;\r\n-\t\t\tdoc.rect(leftOff, bartop, barW, barHeight, "FD");\r\n-\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\tdoc.text(leftOff +barW + 5, bartop + classBarLegendTextSize, "Missing Value n = " + missingCount , null);\r\n-\t\t} else {\r\n-\t\t\tvar barW = missingCount/maxCount*classBarFigureW;\r\n-\t\t\tdoc.rect(leftOff + maxLabelLength, bartop, barW, barHeight, "FD");\r\n-\t\t\tdoc.setFontSize(classBarLegendTextSize);\r\n-\t\t\tdoc.text(leftOff + maxLabelLength - doc.getStringUnitWidth("Missing Value")*classBarLegendTextSize - 4, bartop + barHeight/2, "Missing Value" , null);\r\n-\t\t\tdoc.text(leftOff + maxLabelLength +barW + 5, bartop + barHeight/2, "n = " + missingCount , null);\r\n-\t\t}\r\n-\t\t\r\n-\t\tif (thresholds.length > 15){ // in case a discrete classbar has over 15 categories, make the topOff increment bigger\r\n-\t\t\tclassBarFigureH = (1+thresholds.length)*10;\r\n-\t\t}\r\n-\t\tleftOff+= classBarFigureW + maxLabelLength + 50;\r\n-\t\tif (leftOff + classBarFigureW > pageWidth){ // if the next class bar figure will go beyond the width of the page...\r\n-\t\t\tleftOff = 10; // ...reset leftOff...\r\n-\t\t\ttopOff += classBarFigureH+classBarHeaderSize; // ... and move the next figure to the line below\r\n-\t\t\tclassBarFigureH = 150; // return class bar height to original value in case it got changed in this row\r\n-\t\t\tif (topOff + classBarFigureH > pageHeight){ // if the next class bar goes off the page vertically...\r\n-\t\t\t\tdoc.addPage(); // ... make a new page and reset topOff\r\n-\t\t\t\tcreateHeader();\r\n-\t\t\t\ttopOff = paddingTop + 10;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-\tfunction isChecked(el){\r\n-\t\tif(document.getElementById(el))\r\n-\t\treturn document.getElementById(el).checked;\r\n-\t}\r\n-}\r\n-\r\n-function pdfCancelButton(){\r\n-\tvar prefspanel = document.getElementById(\'pdfPrefsPanel\');\r\n-\tprefspanel.style.display = "none";\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/SelectionManager.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/SelectionManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b"@@ -1,449 +0,0 @@\n-/**\r\n- * This code is responsible for handling changes in position of selected heat map region.\r\n- * It handles mouse, keyboard, and button events that change the position of the selected\r\n- * region.  It also tracks whether the display is in a single window or split into two\r\n- * separate windows.  If in separate windows, local storage events are used to communicate\r\n- * changes between the two windows.  \r\n- */\r\n-\r\n-//Globals that provide information about heat map position selection.\r\n-\r\n-mode = null;          // Set to normal or ribbon vertical or ribbon horizontal \r\n-currentRow=null;      // Top row of current selected position\r\n-currentCol=null;      // Left column of the current selected position\r\n-dataPerRow=null;      // How many rows are included in the current selection\r\n-dataPerCol=null;      // How many columns in the current selection\r\n-selectedStart=0;      // If dendrogram selection is used to limit ribbon view - which position to start selection.\r\n-selectedStop=0;       // If dendrogram selection is used to limit ribbon view - which position is last of selection.\r\n-var searchItems=[];   // Valid labels found from a user search\r\n-\r\n-                      //isSub will be set to true if windows are split and this is the child.\r\n-isSub = getURLParameter('sub') == 'true';  \r\n-hasSub = false;       //hasSub set to true if windows are split and this is the parent.\r\n-\r\n-\r\n-/* This routine is called when the selected row / column is changed.\r\n- * It is assumed that the caller modified currentRow, currentCol, dataPerRow,\r\n- * and dataPerCol as desired. This method does redrawing and notification as necessary.  \r\n- */\r\n-function updateSelection() {\r\n-\tif (!isSub) {\r\n-\t\t//We have the summary heat map so redraw the yellow selection box.\r\n-\t\tdrawLeftCanvasBox();\r\n-\t} \r\n-\tif (!hasSub) {\r\n-\t\t// Redraw based on mode type and selection. \r\n-\t\theatMap.setReadWindow(getLevelFromMode(MatrixManager.DETAIL_LEVEL),getCurrentDetRow(),getCurrentDetCol(),getCurrentDetDataPerCol(),getCurrentDetDataPerRow());\r\n-\t\tdrawDetailHeatMap();\r\n-\t} \r\n-\t\r\n- \t//If summary and detail as split into two browsers.  Communicate the selection change\r\n-\t//to the other browser.\r\n-\tif (isSub || hasSub) {\r\n-\t\tlocalStorage.removeItem('event');\r\n-\t\tlocalStorage.setItem('currentRow', '' + currentRow);\r\n-\t\tlocalStorage.setItem('currentCol', '' + currentCol);\r\n-\t\tlocalStorage.setItem('dataPerRow', '' + dataPerRow);\r\n-\t\tlocalStorage.setItem('dataPerCol', '' + dataPerCol);\r\n-\t\tlocalStorage.setItem('selectedStart', '' + selectedStart);\r\n-\t\tlocalStorage.setItem('selectedStop', '' + selectedStop);\r\n-\t\tlocalStorage.setItem('mode', mode);\r\n-\t\tlocalStorage.setItem('selected', JSON.stringify(searchItems));\r\n-\t\tlocalStorage.setItem('event', 'changePosition');\r\n-\t}\t\t\r\n-}\r\n-\r\n-function changeMode(newMode) {\r\n-\t\r\n-\tif (!hasSub) {\r\n-\t\tif (newMode == 'RIBBONH')\r\n-\t\t\tdetailHRibbon();\r\n-\t\tif (newMode == 'RIBBONV')\r\n-\t\t\tdetailVRibbon();\r\n-\t\tif (newMode == 'NORMAL')\r\n-\t\t\tdetailNormal();\r\n-\t} else {\r\n-\t\tlocalStorage.removeItem('event');\r\n-\t\tlocalStorage.setItem('selectedStart', '' + selectedStart);\r\n-\t\tlocalStorage.setItem('selectedStop', '' + selectedStop);\r\n-\t\tlocalStorage.setItem('mode', newMode);\r\n-\t\tlocalStorage.setItem('event', 'changeMode');\r\n-\t}\r\n-}\r\n-\r\n-/* Handle mouse scroll wheel events to zoom in / out.\r\n- */\r\n-function handleScroll(evt) {\r\n-\tevt.preventDefault();\r\n-\tif (evt.wheelDelta < 0 || evt.deltaY > 0 || evt.scale < 1) { //Zoom out\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomOut();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem('event');\r\n-\t\t\tlocalStorage.setItem('event', 'zoomOut' )\r\n-\t\t}\r\n-\t} else { // Zoom in\r\n-\t\tif (!hasSub)\r\n-\t\t\tdetailDataZoomIn();\r\n-\t\telse {\r\n-\t\t\tlocalStorage.removeItem('event');\r\n-\t\t\tlocalStorage.setItem('event', 'zoomIn' )\r\n-\t\t}\r\n-\t}\t\r\n-\treturn false;\r\n-} \t\t\r\n-\r\n-\r\n-function keyNavigate(e){\r\n-\tuserHelpClose();\r\n-    clearTimeout(detailPoint);\r\n-\tswitch(e.keyCode){ // prevent default added redundantly to each case so that other key inputs w"..b"ated on the summary heat map when drawing the \r\n- * leftCanvasBox on that side of the screen.\r\n- **********************************************************************************/\r\n-function getCurrentSumDataPerRow() {\r\n-\tvar rowSummaryRatio = heatMap.getRowSummaryRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\t// Summary data per row for  using the summary ration for that level\r\n-\tvar\tsumDataPerRow = Math.floor(dataPerRow/rowSummaryRatio);\r\n-\treturn sumDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentSumDataPerCol() {\r\n-\tvar colSummaryRatio = heatMap.getColSummaryRatio(MatrixManager.SUMMARY_LEVEL);\r\n-\tvar\tsumDataPerCol = Math.floor(dataPerCol/colSummaryRatio);\r\n-\treturn sumDataPerCol;\r\n-}\r\n-\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentDetRow(): These functions perform the conversion of \r\n- * currentRow and currentCol coordinates from full matrix position to detail view\r\n- * position.  This is usually the same but when in ribbon view on a large matrix, \r\n- * the positions are scaled.\r\n- **********************************************************************************/\r\n-function getCurrentDetRow() {\r\n-\tvar detRow = currentRow;\r\n-\tif ((mode == 'RIBBONV') && (selectedStart >= 1)) {\r\n-\t\tvar rvRatio = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tdetRow = Math.round(selectedStart/rvRatio);\r\n-\t}\r\n-\treturn  detRow;\r\n-}\r\n-//Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentDetCol() {\r\n-\tvar detCol = currentCol;\r\n-\tif ((mode == 'RIBBONH') && (selectedStart >= 1)) {\r\n-\t\tvar rhRatio = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tdetCol = Math.round(selectedStart/rhRatio);\r\n-\t}\r\n-\treturn  detCol;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - getCurrentDetDataPerRow(): DataPerRow/Col is in full matrix coordinates\r\n- * and usually the detail view uses this value directly unless we are in ribbon\r\n- * view where the value needs to be scaled in one dimension.\r\n- **********************************************************************************/\r\n-function getCurrentDetDataPerRow() {\r\n-\tvar\tdetDataPerRow = dataPerRow;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tvar rate = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\tdetDataPerRow = Math.round(detDataPerRow/rate);\r\n-\t} \r\n-\treturn detDataPerRow;\r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function getCurrentDetDataPerCol() {\r\n-\tvar\tdetDataPerCol = dataPerCol;\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tvar rate = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\tdetDataPerCol = Math.round(detDataPerCol/rate);\r\n-\t} \r\n-\treturn detDataPerCol;\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTIONS - setDataPerRowFromDet(): DataPerRow/Col is in full matrix coordinates\r\n- * so sometimes in ribbon view this needs to be translated to full coordinates.\r\n- **********************************************************************************/\r\n-function setDataPerRowFromDet(detDataPerRow) {\r\n-\tdataPerRow = detDataPerRow;\r\n-\tif (mode == 'RIBBONH') {\r\n-\t\tif (selectedStart==0) {\r\n-\t\t\tdataPerRow = heatMap.getNumColumns(MatrixManager.DETAIL_LEVEL);\r\n-\t\t} else {\r\n-\t\t\tvar rate = heatMap.getColSummaryRatio(MatrixManager.RIBBON_HOR_LEVEL);\r\n-\t\t\tdataPerRow = detDataPerRow * rate;\r\n-\t\t}\r\n-\t} \r\n-}\r\n-// Follow similar methodology for Column as is used in above row based function\r\n-function setDataPerColFromDet(detDataPerCol) {\r\n-\tdataPerCol = detDataPerCol;\r\n-\tif (mode == 'RIBBONV') {\r\n-\t\tif (selectedStart==0) {\r\n-\t\t\tdataPerCol = heatMap.getNumRows(MatrixManager.DETAIL_LEVEL);\r\n-\t\t} else {\r\n-\t\t\tvar rate = heatMap.getRowSummaryRatio(MatrixManager.RIBBON_VERT_LEVEL);\r\n-\t\t\tdataPerCol = detDataPerCol * rate;\r\n-\t\t}\r\n-\t} \r\n-}\r\n-\r\n-\r\n-\r\n-\r\n-\r\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1026 +0,0 @@\n-var BYTE_PER_RGBA = 4;\r\n-\r\n-var canvas;\r\n-var gl; // WebGL contexts\r\n-var textureParams;\r\n-\r\n-//Size of heat map components\r\n-var dendroPaddingHeight = 1;\r\n-var rowDendroHeight = 102; // this is the height of the row dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var columnDendroHeight = 102; // this is the height of the col dendro in canvas coords (this value may be adjusted eventually by the user)\r\n-var normDendroMatrixHeight = 500; // this is the height of the dendro matrices created in buildDendroMatrix\r\n-var paddingHeight = 2;          // space between classification bars\r\n-var rowClassBarWidth;\r\n-var colClassBarHeight;\r\n-var summaryViewBorderWidth = 2; // black edge around map\r\n-var summaryMatrixWidth;\r\n-var summaryMatrixHeight;\r\n-var colEmptySpace = 0;          // padding for asymmetric maps\r\n-var rowEmptySpace = 0;\r\n-var summaryTotalHeight;\r\n-var summaryTotalWidth;\r\n-\r\n-var rowDendroBars;\r\n-var colDendroBars;\r\n-var colDendroMatrix;\r\n-var rowDendroMatrix;\r\n-var chosenBar = {axis: null, index: null};\r\n-\r\n-var leftCanvasScaleArray = new Float32Array([1.0, 1.0]);\r\n-var leftCanvasBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasTranslateArray = new Float32Array([0, 0]);\r\n-var dendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-var dendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-var leftCanvasBoxVertThick;\r\n-var leftCanvasBoxHorThick;\r\n-\r\n-var TexPixels;\r\n-\r\n-var uScale;\r\n-var uTranslate;\r\n-var uBoxLeftTop;\r\n-var uBoxRightBottom;\r\n-var uBoxVertThickness;\r\n-var uBoxHorThickness;\r\n-var uBoxColor;\r\n-var dendroBoxLeftTop;\r\n-var dendroBoxRightBottom;\r\n-var dendroBoxColor;\r\n-var chmInitialized = 0;\r\n-\r\n-var eventTimer = 0; // Used to delay draw updates\r\n-\r\n-//Main function that draws the summary heat map. chmFile is only used in file mode.\r\n-function initSummaryDisplay() {\r\n-\tcanvas = document.getElementById(\'summary_canvas\');\r\n-\tcanvas.addEventListener(\'click\',  onClickLeftCanvas);\r\n-\tcanvas.onmousemove = handleMove;\r\n-\t// set the position to (1,1) so that the detail pane loads at the top left corner of the summary.\r\n-\tcurrentRow = 1;\r\n-\tcurrentCol = 1;\r\n-};\r\n-\r\n-// Callback that is notified every time there is an update to the heat map \r\n-// initialize, new data, etc.  This callback draws the summary heat map.\r\n-function processSummaryMapUpdate (event, level) {   \r\n-\r\n-\tif (event == MatrixManager.Event_INITIALIZED) {\r\n-\t\tsummaryInit();\r\n-\t} else if (event == MatrixManager.Event_NEWDATA && level == MatrixManager.SUMMARY_LEVEL){\r\n-\t\t//Summary tile - wait a bit to see if we get another tile quickly, then draw\r\n-\t\tif (eventTimer != 0) {\r\n-\t\t\t//New tile arrived - reset timer\r\n-\t\t\tclearTimeout(eventTimer);\r\n-\t\t}\r\n-\t\teventTimer = setTimeout(buildSummaryTexture, 200);\r\n-\t} \r\n-\t//Ignore updates to other tile types.\r\n-}\r\n-\r\n-// Perform all initialization functions for Summary heat map\r\n-function summaryInit() {\r\n-\tvar dendroGram = heatMap.getDendrogram();\r\n-\trowDendroHeight = parseInt(dendroGram[\'row_dendro_height\'])+2;\r\n-\tcolumnDendroHeight = parseInt(dendroGram[\'col_dendro_height\'])+2;\r\n-\tif (heatMap.showRowDendrogram("SUMMARY")) {\r\n-\t\trowDendroMatrix = buildDendroMatrix(dendroGram,\'Row\'); // create array with the bars\r\n-\t}\r\n-\tif (heatMap.showColDendrogram("SUMMARY")) {\r\n-\t\tcolDendroMatrix = buildDendroMatrix(dendroGram,\'Column\'); // create array with the bars\r\n-\t}\r\n-\trowClassBarWidth = calculateTotalClassBarHeight("row");\r\n-\tcolClassBarHeight = calculateTotalClassBarHeight("column");\r\n-\tsummaryMatrixWidth = heatMap.getNumColumns(MatrixManager.SUMMARY_LEVEL);\r\n-\tsummaryMatrixHeight = heatMap.getNumRows(MatrixManager.SUMMARY_LEVEL);\r\n-\t\r\n-\t//If the matrix is skewed (height vs. width) by more than a 2:1 ratio, add padding to keep the summary from stretching too much.\r\n-\tif (summaryMatrixWidth > summaryMatrixHeight && summaryMatrixWidth/summaryMatrixHeight > 2)\r\n-\t\trowEmptySpace = summaryMatrixWidth/2 - sum'..b'= 2;\r\n-\t\t}\r\n-\t}\r\n-\treturn j;\r\n-}\r\n-\r\n-function highlightAllBranchesInRange(height,leftExtreme,rightExtreme,dendroMatrix){\r\n-\tfor (var i = height; i >= 0; i--){\r\n-\t\tfor (var loc in dendroMatrix[i]){\r\n-\t\t\tif (leftExtreme < loc && loc < rightExtreme){\r\n-\t\t\t\tdendroMatrix[i][loc] = 2;\r\n-\t\t\t}\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function clearDendroSelection(){\r\n-\tchosenBar = {axis: null, index: null};\r\n-\tselectedStart = 0;\r\n-\tselectedStop = 0;\r\n-\tif (!isSub) {\r\n-\t\tdendroBoxLeftTopArray = new Float32Array([0, 0]);\r\n-\t\tdendroBoxRightBottomArray = new Float32Array([0, 0]);\r\n-\t\tif (heatMap.showColDendrogram("summary")) {\r\n-\t\t\tcolDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),\'Column\');\r\n-\t\t\tdrawColumnDendrogram(TexPixels);\r\n-\t\t}\r\n-\t\tif (heatMap.showRowDendrogram("summary")) {\r\n-\t\t\trowDendroMatrix = buildDendroMatrix(heatMap.getDendrogram(),"Row");\r\n-\t\t\tdrawRowDendrogram(TexPixels);\r\n-\t\t}\r\n-\t\tdrawSummaryHeatMap();\r\n-\t}\r\n-}\r\n-\r\n-\r\n-//***************************//\r\n-//Selection Label Functions *//\r\n-//***************************//\r\n-function summaryResize() {\r\n-\tclearSelectionMarks();\r\n-\tdrawRowSelectionMarks();\r\n-\tdrawColSelectionMarks();\r\n-}\r\n-\r\n-\r\n-function drawRowSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalHeight - summaryMatrixHeight;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedRows = getSearchRows();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedRows.length; i++) {\r\n-\t\tvar xPos = (1-colEmptySpace/canvas.width)*canvas.clientWidth + 3;\r\n-\t\tvar position = headerSize + (selectedRows[i]/heatMap.getRowSummaryRatio(MatrixManager.SUMMARY_LEVEL));\r\n-\t\tvar yPos = ((position /summaryTotalHeight-(rowEmptySpace/canvas.height))* canvas.clientHeight) - fontSize;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'F\');\r\n-\t}\r\n-}\r\n-\r\n-function drawColSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar headerSize = summaryTotalWidth - summaryMatrixWidth;\r\n-\r\n-\tvar fontSize = 10;\r\n-\tvar selectedCols = getSearchCols();\r\n-\t\r\n-\t\r\n-\tfor (var i = 0; i < selectedCols.length; i++) {\r\n-\t\tvar position = headerSize + (selectedCols[i]/heatMap.getColSummaryRatio(MatrixManager.SUMMARY_LEVEL));\r\n-\t\tvar xPos = ((position / summaryTotalWidth-(colEmptySpace/canvas.width))*(canvas.clientWidth)) + fontSize/2;\r\n-\t\tvar yPos = (1-rowEmptySpace/canvas.height)*canvas.clientHeight + 4;\r\n-\t\taddLabelDiv(markElement, \'sum_row\' + i, \'MarkLabel\', \'<\', xPos, yPos, fontSize, \'T\');\r\n-\t}\r\n-}\r\n-\r\n-function clearSelectionMarks() {\r\n-\tvar markElement = document.getElementById(\'sumlabelDiv\');\r\n-\tvar oldMarks = document.getElementsByClassName("MarkLabel");\r\n-\twhile (oldMarks.length > 0) {\r\n-\t\tmarkElement.removeChild(oldMarks[0]);\r\n-\t}\r\n-\r\n-}\r\n-\r\n-\r\n-function dividerStart(){\r\n-\tuserHelpClose();\r\n-\tdocument.addEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.addEventListener(\'touchmove\', dividerMove);\r\n-\tdocument.addEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.addEventListener(\'touchend\',dividerEnd);\r\n-}\r\n-function dividerMove(e){\r\n-\tvar divider = document.getElementById(\'divider\');\r\n-\tif (e.touches){\r\n-    \tif (e.touches.length > 1){\r\n-    \t\treturn false;\r\n-    \t}\r\n-    }\r\n-\tvar Xmove = e.touches ? divider.offsetLeft - e.touches[0].pageX : divider.offsetLeft - e.pageX;\r\n-\tvar summary = document.getElementById(\'summary_chm\');\r\n-\tvar summaryX = summary.offsetWidth - Xmove;\r\n-\tsummary.setAttribute("style","position: relative; width:" + summaryX + "px");\r\n-\tvar detail = document.getElementById(\'detail_chm\');\r\n-\tvar detailX = detail.offsetWidth + Xmove;\r\n-\tdetail.setAttribute("style","position: relative; width:" + detailX + "px");\r\n-\tclearLabels();\r\n-\tclearSelectionMarks();\r\n-}\r\n-function dividerEnd(){\r\n-\tdocument.removeEventListener(\'mousemove\', dividerMove);\r\n-\tdocument.removeEventListener(\'mouseup\', dividerEnd);\r\n-\tdocument.removeEventListener(\'touchmove\',dividerMove);\r\n-\tdocument.removeEventListener(\'touchend\',dividerEnd);\r\n-\tdetailResize();\r\n-\tsummaryResize();\r\n-}\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/UserHelpManager.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/UserHelpManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,527 +0,0 @@\n-/**********************************************************************************\r\n- * USER HELP FUNCTIONS:  The following functions handle the processing \r\n- * for user help popup windows for the detail canvas and the detail canvas buttons.\r\n- **********************************************************************************/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - userHelpOpen: This function handles all of the tasks necessary to \r\n- * generate help pop-up panels for the detail heat map and the detail heat map \r\n- * classification bars.  \r\n- **********************************************************************************/\r\n-function userHelpOpen(e){ \r\n-    userHelpClose();\r\n-    clearTimeout(detailPoint);\r\n-    var orgW = window.innerWidth+window.pageXOffset;\r\n-    var orgH = window.innerHeight+window.pageYOffset;\r\n-    var helptext = getDivElement("helptext");    \r\n-    helptext.style.position = "absolute";\r\n-    document.getElementsByTagName(\'body\')[0].appendChild(helptext);\r\n-    var rowElementSize = dataBoxWidth * detCanvas.clientWidth/detCanvas.width; // px/Glpoint\r\n-    var colElementSize = dataBoxHeight * detCanvas.clientHeight/detCanvas.height;\r\n-\r\n-    // pixels\r\n-    var rowClassWidthPx = getRowClassPixelWidth();\r\n-    var colClassHeightPx = getColClassPixelHeight();\r\n-    var rowDendroWidthPx =  getRowDendroPixelWidth();\r\n-    var colDendroHeightPx = getColDendroPixelHeight();\r\n-\tvar mapLocY = e.layerY - colClassHeightPx - colDendroHeightPx;\r\n-\tvar mapLocX = e.layerX - rowClassWidthPx - rowDendroWidthPx;\r\n-\t\r\n-    if (isOnObject(e,"map")) {\r\n-    \tvar row = Math.floor(currentRow + (mapLocY/colElementSize)*getSamplingRatio(\'row\'));\r\n-    \tvar col = Math.floor(currentCol + (mapLocX/rowElementSize)*getSamplingRatio(\'col\'));\r\n-    \tvar rowLabels = heatMap.getRowLabels().labels;\r\n-    \tvar colLabels = heatMap.getColLabels().labels;\r\n-    \tvar classBars = heatMap.getClassifications();\r\n-    \tvar helpContents = document.createElement("TABLE");\r\n-    \tsetTableRow(helpContents, ["<u>"+"Data Details"+"</u>", "&nbsp;"], 2);\r\n-    \tsetTableRow(helpContents,["&nbsp;Value:", heatMap.getValue(MatrixManager.DETAIL_LEVEL,row,col).toFixed(5)]);\r\n-    \tsetTableRow(helpContents,[ "&nbsp;Row:", rowLabels[row-1]]);\r\n-    \tsetTableRow(helpContents,["&nbsp;Column:", colLabels[col-1]]);\r\n-    \thelpContents.insertRow().innerHTML = formatBlankRow();\r\n-    \tvar rowCtr = 8;\r\n-    \tvar writeFirstCol = true;\r\n-    \tvar pos = col;\r\n-    \tvar classLen = Object.keys(classBars).length;\r\n-    \tif (classLen > 0) {\r\n-\t\t\tsetTableRow(helpContents, ["&nbsp;<u>"+"Row Classifications"+"</u>", "&nbsp;"], 2);\r\n-\t    \tfor (var key in classBars){\r\n-\t    \t\tif (classBars[key].position == "column") {\r\n-\t    \t\t\tif (writeFirstCol) {\r\n-\t    \t\t    \thelpContents.insertRow().innerHTML = formatBlankRow();\r\n-\t    \t\t\t\tsetTableRow(helpContents, ["&nbsp;<u>"+"Column Classifications"+"</u>", "&nbsp;"], 2);\r\n-\t    \t\t\t\twriteFirstCol = false;\r\n-\t    \t\t\t}\r\n-\t        \t\tpos = row;\r\n-\t        \t\trowCtr = rowCtr++;\r\n-\t    \t\t}\r\n-\t    \t\tsetTableRow(helpContents,["&nbsp;&nbsp;&nbsp;"+key+":"+"</u>", classBars[key].values[pos-1]]);\t    \t\t\r\n-\t    \t\trowCtr++;\r\n-\t    \t}\r\n-    \t}\r\n-        helptext.style.display="inherit";\r\n-    \thelptext.appendChild(helpContents);\r\n-    \tlocateHelpBox(e, helptext);\r\n-    } else if (isOnObject(e,"rowClass") || isOnObject(e,"colClass")) {\r\n-    \tvar pos, classInfo, names, colorSchemes, value;\r\n-    \tvar classBars = heatMap.getClassifications();\r\n-    \tvar hoveredBar, hoveredBarColorScheme;                                                     //coveredWidth = 0, coveredHeight = 0;\r\n-    \tif (isOnObject(e,"colClass")) {\r\n-    \t\tvar coveredHeight = detCanvas.clientHeight*detailDendroHeight/detCanvas.height\r\n-    \t\tpos = Math.floor(currentCol + (mapLocX/rowElementSize));\r\n-    \t\tclassInfo = getClassBarsToDraw("column");\r\n-        \tnames = classInfo["bars"];\r\n-        \tcolorSche'..b'have these inputs!\r\n-\t};\r\n-\tcell.addEventListener(\'click\', functionWithParams);\r\n-}\r\n-\r\n-function getDefaultLinkouts(){\r\n-\taddLinkout("Copy " + heatMap.getColLabels()["label_type"] +" to Clipboard", heatMap.getColLabels()["label_type"], "labels", copyToClipBoard,0);\r\n-\taddLinkout("Copy " +heatMap.getRowLabels()["label_type"] + " to Clipboard", heatMap.getRowLabels()["label_type"], "labels", copyToClipBoard,0);\r\n-\taddLinkout("Copy bar data for all labels to Clipboard", "ColumnClass", "labels",copyEntireClassBarToClipBoard,0);\r\n-\taddLinkout("Copy bar data for selected labels to Clipboard", "ColumnClass", "labels",copyPartialClassBarToClipBoard,1);\r\n-\taddLinkout("Copy bar data for all labels to Clipboard", "RowClass", "labels",copyEntireClassBarToClipBoard,0);\r\n-\taddLinkout("Copy bar data for selected labels to Clipboard", "RowClass", "labels",copyPartialClassBarToClipBoard,1);\r\n-}\r\n-\r\n-function linkout (title, inputType, callback){ // the linkout object\r\n-\tthis.title = title;\r\n-\tthis.inputType = inputType; // input type of the callback function\r\n-\tthis.callback = callback;\r\n-}\r\n-\r\n-function addLinkout(name, labelType, inputType, callback, index){ // adds linkout objects to the linkouts global variable\r\n-\tif (!linkouts[labelType]){\r\n-\t\tlinkouts[labelType] = [new linkout(name, inputType,callback)];\r\n-\t} else {\r\n-\t\tif (index !== undefined){\r\n-\t\t\tlinkouts[labelType].splice(index, 0, new linkout(name,inputType,callback)); \r\n-\t\t}else {\r\n-\t\t\tlinkouts[labelType].push(new linkout(name,inputType,callback));\r\n-\t\t}\r\n-\t}\r\n-}\r\n-\r\n-function copyToClipBoard(labels,axis){\r\n-\twindow.open("","",\'width=335,height=330,resizable=1\').document.write(labels.join(", "));\r\n-}\r\n-\r\n-function copyEntireClassBarToClipBoard(labels,axis){\r\n-\tvar newWindow = window.open("","",\'width=335,height=330,resizable=1\');\r\n-\tvar newDoc = newWindow.document;\r\n-\tvar axisLabels = axis == "ColumnClass" ? heatMap.getColLabels()["labels"] : heatMap.getRowLabels()["labels"]; \r\n-\tvar classifications = heatMap.getClassifications();\r\n-\tnewDoc.write("Sample&emsp;" + labels.join("&emsp;") + ":<br>");\r\n-\tfor (var i = 0; i < axisLabels.length; i++){\r\n-\t\tnewDoc.write(axisLabels[i] + "&emsp;");\r\n-\t\tfor (var j = 0; j < labels.length; j++){\r\n-\t\t\tnewDoc.write(classifications[labels[j]].values[i] + "&emsp;");\r\n-\t\t}\r\n-\t\tnewDoc.write("<br>");\r\n-\t}\r\n-}\r\n-\r\n-function copyPartialClassBarToClipBoard(labels,axis){\r\n-\tvar newWindow = window.open("","",\'width=335,height=330,resizable=1\');\r\n-\tvar newDoc = newWindow.document;\r\n-\tvar axisLabels = axis == "ColumnClass" ? getSearchLabelsByAxis("Column") : getSearchLabelsByAxis("Row");\r\n-\tvar labelIndex = axis == "ColumnClass" ? getSearchCols() : getSearchRows(); \r\n-\tvar classifications = heatMap.getClassifications();\r\n-\tnewDoc.write("Sample&emsp;" + labels.join("&emsp;") + ":<br>");\r\n-\tfor (var i = 0; i < axisLabels.length; i++){\r\n-\t\tnewDoc.write(axisLabels[i] + "&emsp;");\r\n-\t\tfor (var j = 0; j < labels.length; j++){\r\n-\t\t\tnewDoc.write(classifications[labels[j]].values[labelIndex[i]-1] + "&emsp;");\r\n-\t\t}\r\n-\t\tnewDoc.write("<br>");\r\n-\t}\r\n-}\r\n-\r\n-//===========================\r\n-// LABEL MENU FUNCTIONS END \r\n-//===========================\r\n-\r\n-function showSearchError(type){\r\n-\tvar searchError = getDivElement(\'searchError\');\r\n-\tsearchError.style.display = \'inherit\';\r\n-\tvar searchBar = document.getElementById(\'search_text\');\r\n-\tsearchError.style.top = searchBar.offsetTop + searchBar.offsetHeight;\r\n-\tsearchError.style.left = searchBar.offsetLeft + searchBar.offsetWidth;\r\n-\tswitch (type){\r\n-\t\tcase 0: searchError.innerHTML = "No matching labels found"; break;\r\n-\t\tcase 1: searchError.innerHTML = "Exit dendrogram selection to go to " + currentSearchItem.label;break;\r\n-\t\tcase 2: searchError.innerHTML = "All " + currentSearchItem.axis +  " items are visible. Change the view mode to see " + currentSearchItem.label;break;\r\n-\t}\r\n-\tdocument.body.appendChild(searchError);\r\n-\tsetTimeout(function(){\r\n-\t\tsearchError.remove();\r\n-\t}, 2000);\r\n-\t\r\n-}\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1159 +0,0 @@\n-/**********************************************************************************\r\n- * USER PREFERENCE FUNCTIONS:  The following functions handle the processing \r\n- * for user preference editing. \r\n- **********************************************************************************/\r\n-\r\n-//Global variables for preference processing\r\n-var maxRows = 0;\r\n-var helpRowSize = 0;\r\n-var bkpColorMap = null;\r\n-var filterVal;\r\n-var searchPerformed = false;\r\n-\r\n-/*===================================================================================\r\n- *  COMMON PREFERENCE PROCESSING FUNCTIONS\r\n- *  \r\n- *  The following functions are utilized to present the entire heat map preferences\r\n- *  dialog and, therefore, sit above those functions designed specifically for processing\r\n- *  individual data layer and covariate classification bar preferences:\r\n- *  \t- editPreferences\r\n- *  \t- setPrefsDivSizing\r\n- *  \t- showLayerPrefs\r\n- *      - showClassPrefs\r\n- *      - showRowsColsPrefs\r\n- *      - prefsCancel\r\n- *      - prefsApply\r\n- *      - prefsValidate\r\n- *      - prefsValidateBreakPoints\r\n- *      - prefsValidateBreakColors\r\n- *      - prefsApplyBreaks\r\n- *      - getNewBreakColors\r\n- *      - getNewBreakThresholds  \r\n- *      - prefsSave\r\n- =================================================================================*/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - editPreferences: This is the MAIN driver function for edit \r\n- * preferences processing.  It is called under two conditions (1) The Edit \r\n- * preferences "gear" button is pressed on the main application screen \r\n- * (2) User preferences have been applied BUT errors have occurred.\r\n- * \r\n- * Processing for this function is documented in detail in the body of the function.\r\n- **********************************************************************************/\r\n-function editPreferences(e,errorMsg){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\r\n-\t// If helpPrefs element already exists, the user is pressing the gear button\r\n-\t// when preferences are already open. Disregard.\r\n-\tvar helpExists = document.getElementById(\'prefsPanel\');\r\n-\tif ((isSub) || (helpExists !== null)) {\r\n-\t\treturn;\r\n-\t}\r\n-\r\n-\t//If first time thru, save the dataLayer colorMap\r\n-\t//This is done because the colorMap must be edited to add/delete breakpoints while retaining their state\r\n-\tvar colorMap = heatMap.getColorMapManager().getColorMap("dl1"); //TODO - Modify when multiple data layers (flick) are added\r\n-\tif (bkpColorMap === null) {\r\n-\t\tbkpColorMap = colorMap;\r\n-\t} \r\n-\r\n-\t//Create a "master" DIV for displaying edit preferences\r\n-\tvar prefspanel = getDivElement("prefsPanel");\r\n-\tdocument.getElementsByTagName(\'body\')[0].appendChild(prefspanel);\r\n-\t\r\n-\t//Create a one cell table and populate the header and tab elements in the first 3 table rows\r\n-\tvar prefContents = document.createElement("TABLE");\r\n-\tvar headDiv = document.createElement(\'div\');\r\n-\theadDiv.className = \'prefsHeader\';\r\n-\theadDiv.id = \'prefsHeader\';\r\n-\tprefspanel.appendChild(headDiv);\r\n-\theadDiv.textContent = \'Heat Map Display Properties\';\r\n-\t\r\n-\tprefContents.insertRow().innerHTML = formatBlankRow();\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'line-height:30px;\'>&nbsp;</td>";\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'border-bottom-style:solid;border-bottom-width:2px;position: relative;\'><div id=\'prefTab_buttons\' style=\'position: absolute; bottom: 0;\' align=\'left\'><img id=\'prefRowsCols_btn\' src=\'" + staticPath + "rowsColsOn.png\' alt=\'Edit Rows & Columns\' onclick=\'showRowsColsPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefLayer_btn\' src=\'" + staticPath + "images/dataLayersOff.png\' alt=\'Edit Data Layers\' onclick=\'showLayerPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefClass_btn\' src=\'" + staticPath+ "images/covariateBarsOff.png\' alt=\'Edit Classifications\' onclick=\'showClassPrefs();\' align=\'top\'/></div></td>";\r\n-\t//Initialize rowCtr variable\r\n-\tvar rowCtr = 3;\r\n-\r\n-\t//Cr'..b'******************************************/\r\n-function showDendroSelections() {\r\n-\tvar dendrogram = heatMap.getDendrogram();\r\n-\tvar rowLabels = heatMap.getRowLabels();\r\n-\tvar rowOrder = rowLabels[\'order_method\'];\r\n-\tif (rowOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'row_dendro_show\'];\r\n-\t\tdocument.getElementById("rowDendroShowPref").value = dendroShowVal;\r\n-\t\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = rowHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\trowHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\trowHeightPref.add(option);\r\n-\t\t\trowHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\trowHeightPref.value = dendrogram[\'row_dendro_height\'];\r\n-\t}\r\n-\tvar colLabels = heatMap.getColLabels();\r\n-\tvar colOrder = colLabels[\'order_method\'];\r\n-\tif (colOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'col_dendro_show\'];\r\n-\t\tdocument.getElementById("colDendroShowPref").value = dendroShowVal;\r\n-\t\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = colHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\tcolHeightPref.add(option);\r\n-\t\t\tcolHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\tcolHeightPref.value = dendrogram[\'col_dendro_height\'];\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroRowShowChange() {\r\n-\tvar newValue = document.getElementById("rowDendroShowPref").value;\r\n-\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\trowHeightPref.add(option);\r\n-\t\trowHeightPref.value = \'10\';\r\n-\t\trowHeightPref.disabled = true;\r\n-\t} else if (rowHeightPref.disabled) {\r\n-\t\tvar opt = rowHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\trowHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\trowHeightPref.value = \'100\';\r\n-\t\trowHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroColShowChange() {\r\n-\tvar newValue = document.getElementById("colDendroShowPref").value;\r\n-\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\tcolHeightPref.add(option);\r\n-\t\tcolHeightPref.value = \'10\';\r\n-\t\tcolHeightPref.disabled = true;\r\n-\t} else if (colHeightPref.disabled) {\r\n-\t\tvar opt = colHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\tcolHeightPref.value = \'100\';\r\n-\t\tcolHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js.sav
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/UserPreferenceManager.js.sav Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,1159 +0,0 @@\n-/**********************************************************************************\r\n- * USER PREFERENCE FUNCTIONS:  The following functions handle the processing \r\n- * for user preference editing. \r\n- **********************************************************************************/\r\n-\r\n-//Global variables for preference processing\r\n-var maxRows = 0;\r\n-var helpRowSize = 0;\r\n-var bkpColorMap = null;\r\n-var filterVal;\r\n-var searchPerformed = false;\r\n-\r\n-/*===================================================================================\r\n- *  COMMON PREFERENCE PROCESSING FUNCTIONS\r\n- *  \r\n- *  The following functions are utilized to present the entire heat map preferences\r\n- *  dialog and, therefore, sit above those functions designed specifically for processing\r\n- *  individual data layer and covariate classification bar preferences:\r\n- *  \t- editPreferences\r\n- *  \t- setPrefsDivSizing\r\n- *  \t- showLayerPrefs\r\n- *      - showClassPrefs\r\n- *      - showRowsColsPrefs\r\n- *      - prefsCancel\r\n- *      - prefsApply\r\n- *      - prefsValidate\r\n- *      - prefsValidateBreakPoints\r\n- *      - prefsValidateBreakColors\r\n- *      - prefsApplyBreaks\r\n- *      - getNewBreakColors\r\n- *      - getNewBreakThresholds  \r\n- *      - prefsSave\r\n- =================================================================================*/\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - editPreferences: This is the MAIN driver function for edit \r\n- * preferences processing.  It is called under two conditions (1) The Edit \r\n- * preferences "gear" button is pressed on the main application screen \r\n- * (2) User preferences have been applied BUT errors have occurred.\r\n- * \r\n- * Processing for this function is documented in detail in the body of the function.\r\n- **********************************************************************************/\r\n-function editPreferences(e,errorMsg){\r\n-\tmaxRows = 0;\r\n-\tuserHelpClose();\r\n-\r\n-\t// If helpPrefs element already exists, the user is pressing the gear button\r\n-\t// when preferences are already open. Disregard.\r\n-\tvar helpExists = document.getElementById(\'prefsPanel\');\r\n-\tif ((isSub) || (helpExists !== null)) {\r\n-\t\treturn;\r\n-\t}\r\n-\r\n-\t//If first time thru, save the dataLayer colorMap\r\n-\t//This is done because the colorMap must be edited to add/delete breakpoints while retaining their state\r\n-\tvar colorMap = heatMap.getColorMapManager().getColorMap("dl1"); //TODO - Modify when multiple data layers (flick) are added\r\n-\tif (bkpColorMap === null) {\r\n-\t\tbkpColorMap = colorMap;\r\n-\t} \r\n-\r\n-\t//Create a "master" DIV for displaying edit preferences\r\n-\tvar prefspanel = getDivElement("prefsPanel");\r\n-\tdocument.getElementsByTagName(\'body\')[0].appendChild(prefspanel);\r\n-\t\r\n-\t//Create a one cell table and populate the header and tab elements in the first 3 table rows\r\n-\tvar prefContents = document.createElement("TABLE");\r\n-\tvar headDiv = document.createElement(\'div\');\r\n-\theadDiv.className = \'prefsHeader\';\r\n-\theadDiv.id = \'prefsHeader\';\r\n-\tprefspanel.appendChild(headDiv);\r\n-\theadDiv.textContent = \'Heat Map Display Properties\';\r\n-\t\r\n-\tprefContents.insertRow().innerHTML = formatBlankRow();\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'line-height:30px;\'>&nbsp;</td>";\r\n-\tprefContents.insertRow().innerHTML = "<td style=\'border-bottom-style:solid;border-bottom-width:2px;position: relative;\'><div id=\'prefTab_buttons\' style=\'position: absolute; bottom: 0;\' align=\'left\'><img id=\'prefRowsCols_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/rowsColsOn.png\' alt=\'Edit Rows & Columns\' onclick=\'showRowsColsPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefLayer_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/dataLayersOff.png\' alt=\'Edit Data Layers\' onclick=\'showLayerPrefs();\' align=\'top\'/>&nbsp;<img id=\'prefClass_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/covariateBarsOff.png\' alt=\'Edit Classifications\' onclick=\'showClassPrefs();\' align=\'t'..b'******************************************/\r\n-function showDendroSelections() {\r\n-\tvar dendrogram = heatMap.getDendrogram();\r\n-\tvar rowLabels = heatMap.getRowLabels();\r\n-\tvar rowOrder = rowLabels[\'order_method\'];\r\n-\tif (rowOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'row_dendro_show\'];\r\n-\t\tdocument.getElementById("rowDendroShowPref").value = dendroShowVal;\r\n-\t\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = rowHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\trowHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\trowHeightPref.add(option);\r\n-\t\t\trowHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\trowHeightPref.value = dendrogram[\'row_dendro_height\'];\r\n-\t}\r\n-\tvar colLabels = heatMap.getColLabels();\r\n-\tvar colOrder = colLabels[\'order_method\'];\r\n-\tif (colOrder === "Hierarchical") {\r\n-\t\tvar dendroShowVal = dendrogram[\'col_dendro_show\'];\r\n-\t\tdocument.getElementById("colDendroShowPref").value = dendroShowVal;\r\n-\t\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\t\tif (dendroShowVal === \'NONE\') {\r\n-\t\t\tvar opt = colHeightPref.options[6];\r\n-\t\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t\t}\r\n-\t\t\tvar option = document.createElement("option");\r\n-\t\t\toption.text = "NA";\r\n-\t\t\toption.value = \'10\';\r\n-\t\t\tcolHeightPref.add(option);\r\n-\t\t\tcolHeightPref.disabled = true;\r\n-\t\t}\r\n-\t\tcolHeightPref.value = dendrogram[\'col_dendro_height\'];\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroRowShowChange() {\r\n-\tvar newValue = document.getElementById("rowDendroShowPref").value;\r\n-\tvar rowHeightPref = document.getElementById("rowDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\trowHeightPref.add(option);\r\n-\t\trowHeightPref.value = \'10\';\r\n-\t\trowHeightPref.disabled = true;\r\n-\t} else if (rowHeightPref.disabled) {\r\n-\t\tvar opt = rowHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\trowHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\trowHeightPref.value = \'100\';\r\n-\t\trowHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-/**********************************************************************************\r\n- * FUNCTION - dendroRowShowChange: The purpose of this function is to respond to\r\n- * a change event on the show row dendrogram dropdown.  If the change is to Hide, \r\n- * the row dendro height is set to 10 and the dropdown disabled. If the change is to\r\n- * one of the 2 Show options AND was previously Hide, set height to the default\r\n- * value of 100 and enable the dropdown.\r\n- **********************************************************************************/\r\n-function dendroColShowChange() {\r\n-\tvar newValue = document.getElementById("colDendroShowPref").value;\r\n-\tvar colHeightPref = document.getElementById("colDendroHeightPref");\r\n-\tif (newValue === \'NONE\') {\r\n-\t\tvar option = document.createElement("option");\r\n-\t\toption.text = "NA";\r\n-\t\toption.value = \'10\';\r\n-\t\tcolHeightPref.add(option);\r\n-\t\tcolHeightPref.value = \'10\';\r\n-\t\tcolHeightPref.disabled = true;\r\n-\t} else if (colHeightPref.disabled) {\r\n-\t\tvar opt = colHeightPref.options[6];\r\n-\t\tif (typeof opt != \'undefined\') {\r\n-\t\t\tcolHeightPref.options[6].remove();\r\n-\t\t}\r\n-\t\tcolHeightPref.value = \'100\';\r\n-\t\tcolHeightPref.disabled = false;\r\n-\t}\r\n-}\r\n-\r\n-\r\n-\r\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/custom.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/custom.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,42 +0,0 @@
-/*
- *  TO DO: give custom.js its own namespace so it can't modify variables used outside
- *  Only outside function/variable it should be able to access right now is addLinkout and the inputs of each custom function (label text or index)
- */
-
-addLinkout("Search Google", "Samples", "labels", searchGoogle);
-
-addLinkout("Search Google", "Genes", "labels", searchGoogle);
-addLinkout("Search GeneCards", "Genes", "labels", searchGeneCards);
-addLinkout("Search PubMed for All", "Genes", "labels", searchPubMedForAll);
-addLinkout("Search PubMed for Any", "Genes", "labels", searchPubMedForAny);
-
-function searchGoogle(selection, axis){
- window.open('https://www.google.com/#q=' + selection.join("+"));
-}
-
-function searchGeneCards(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(1);
- window.open('http://www.genecards.org/Search/Keyword?queryString=' + searchTerm);
-}
-
-function searchPubMedForAll(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+AND+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(5);
- window.open("http://www.ncbi.nlm.nih.gov/pubmed/?term=" + searchTerm)
-}
-
-function searchPubMedForAny(labels){
- var searchTerm = '';
- for (var i = 0; i < labels.length; i++){
- searchTerm += "+OR+" + labels[i].split("|")[0];
- }
- searchTerm = searchTerm.substring(4);
- window.open("http://www.ncbi.nlm.nih.gov/pubmed/?term=" + searchTerm)
-}
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/lib/deflate.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/lib/deflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2060 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\n-\tvar MAX_BITS = 15;\n-\tvar D_CODES = 30;\n-\tvar BL_CODES = 19;\n-\n-\tvar LENGTH_CODES = 29;\n-\tvar LITERALS = 256;\n-\tvar L_CODES = (LITERALS + 1 + LENGTH_CODES);\n-\tvar HEAP_SIZE = (2 * L_CODES + 1);\n-\n-\tvar END_BLOCK = 256;\n-\n-\t// Bit length codes must not exceed MAX_BL_BITS bits\n-\tvar MAX_BL_BITS = 7;\n-\n-\t// repeat previous bit length 3-6 times (2 bits of repeat count)\n-\tvar REP_3_6 = 16;\n-\n-\t// repeat a zero length 3-10 times (3 bits of repeat count)\n-\tvar REPZ_3_10 = 17;\n-\n-\t// repeat a zero length 11-138 times (7 bits of repeat count)\n-\tvar REPZ_11_138 = 18;\n-\n-\t// The lengths of the bit length codes are sent in order of decreasing\n-\t// probability, to avoid transmitting the lengths for unused bit\n-\t// length codes.\n-\n-\tvar Buf_size = 8 * 2;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_DEFAULT_COMPRESSION = -1;\n-\n-\t// compression strategy\n-\tvar Z_FILTERED = 1;\n-\tvar Z_HUFFMAN_ONLY = 2;\n-\tvar Z_DEFAULT_STRATEGY = 0;\n-\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_PARTIAL_FLUSH = 1;\n-\tvar Z_FULL_FLUSH = 3;\n-\tvar Z_FINISH = 4;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\t// Tree\n-\n-\t// see definition of array dist_code below\n-\tvar _dist_code = [ 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,\n-\t\t\t10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,\n-\t\t\t12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,\n-\t\t\t13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,\n-\t\t\t14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,\n-\t\t\t15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15,'..b's may wish to modify it to avoid\n-\t\t// allocating a large strm->next_in buffer and copying from it.\n-\t\t// (See also flush_pending()).\n-\t\tread_buf : function(buf, start, size) {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.avail_in;\n-\t\t\tif (len > size)\n-\t\t\t\tlen = size;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn 0;\n-\t\t\tthat.avail_in -= len;\n-\t\t\tbuf.set(that.next_in.subarray(that.next_in_index, that.next_in_index + len), start);\n-\t\t\tthat.next_in_index += len;\n-\t\t\tthat.total_in += len;\n-\t\t\treturn len;\n-\t\t},\n-\n-\t\t// Flush as much pending output as possible. All deflate() output goes\n-\t\t// through this function so some applications may wish to modify it\n-\t\t// to avoid allocating a large strm->next_out buffer and copying into it.\n-\t\t// (See also read_buf()).\n-\t\tflush_pending : function() {\n-\t\t\tvar that = this;\n-\t\t\tvar len = that.dstate.pending;\n-\n-\t\t\tif (len > that.avail_out)\n-\t\t\t\tlen = that.avail_out;\n-\t\t\tif (len === 0)\n-\t\t\t\treturn;\n-\n-\t\t\t// if (that.dstate.pending_buf.length <= that.dstate.pending_out || that.next_out.length <= that.next_out_index\n-\t\t\t// || that.dstate.pending_buf.length < (that.dstate.pending_out + len) || that.next_out.length < (that.next_out_index +\n-\t\t\t// len)) {\n-\t\t\t// console.log(that.dstate.pending_buf.length + ", " + that.dstate.pending_out + ", " + that.next_out.length + ", " +\n-\t\t\t// that.next_out_index + ", " + len);\n-\t\t\t// console.log("avail_out=" + that.avail_out);\n-\t\t\t// }\n-\n-\t\t\tthat.next_out.set(that.dstate.pending_buf.subarray(that.dstate.pending_out, that.dstate.pending_out + len), that.next_out_index);\n-\n-\t\t\tthat.next_out_index += len;\n-\t\t\tthat.dstate.pending_out += len;\n-\t\t\tthat.total_out += len;\n-\t\t\tthat.avail_out -= len;\n-\t\t\tthat.dstate.pending -= len;\n-\t\t\tif (that.dstate.pending === 0) {\n-\t\t\t\tthat.dstate.pending_out = 0;\n-\t\t\t}\n-\t\t}\n-\t};\n-\n-\t// Deflater\n-\n-\tfunction Deflater(options) {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar level = options ? options.level : Z_DEFAULT_COMPRESSION;\n-\t\tif (typeof level == "undefined")\n-\t\t\tlevel = Z_DEFAULT_COMPRESSION;\n-\t\tz.deflateInit(level);\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (!data.length)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(flush);\n-\t\t\t\tif (err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index == bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tvar err, buffers = [], bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\terr = z.deflate(Z_FINISH);\n-\t\t\t\tif (err != Z_STREAM_END && err != Z_OK)\n-\t\t\t\t\tthrow new Error("deflating: " + z.msg);\n-\t\t\t\tif (bufsize - z.avail_out > 0)\n-\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tz.deflateEnd();\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Deflater = env._jzlib_Deflater = Deflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/lib/inflate.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/lib/inflate.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,2155 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright \n- notice, this list of conditions and the following disclaimer in \n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-/*\n- * This program is based on JZlib 1.0.2 ymnk, JCraft,Inc.\n- * JZlib is based on zlib-1.1.3, so all credit should go authors\n- * Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)\n- * and contributors of zlib.\n- */\n-\n-(function(global) {\n-\t"use strict";\n-\n-\t// Global\n-\tvar MAX_BITS = 15;\n-\n-\tvar Z_OK = 0;\n-\tvar Z_STREAM_END = 1;\n-\tvar Z_NEED_DICT = 2;\n-\tvar Z_STREAM_ERROR = -2;\n-\tvar Z_DATA_ERROR = -3;\n-\tvar Z_MEM_ERROR = -4;\n-\tvar Z_BUF_ERROR = -5;\n-\n-\tvar inflate_mask = [ 0x00000000, 0x00000001, 0x00000003, 0x00000007, 0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f, 0x000000ff, 0x000001ff, 0x000003ff,\n-\t\t\t0x000007ff, 0x00000fff, 0x00001fff, 0x00003fff, 0x00007fff, 0x0000ffff ];\n-\n-\tvar MANY = 1440;\n-\n-\t// JZlib version : "1.0.2"\n-\tvar Z_NO_FLUSH = 0;\n-\tvar Z_FINISH = 4;\n-\n-\t// InfTree\n-\tvar fixed_bl = 9;\n-\tvar fixed_bd = 5;\n-\n-\tvar fixed_tl = [ 96, 7, 256, 0, 8, 80, 0, 8, 16, 84, 8, 115, 82, 7, 31, 0, 8, 112, 0, 8, 48, 0, 9, 192, 80, 7, 10, 0, 8, 96, 0, 8, 32, 0, 9, 160, 0, 8, 0,\n-\t\t\t0, 8, 128, 0, 8, 64, 0, 9, 224, 80, 7, 6, 0, 8, 88, 0, 8, 24, 0, 9, 144, 83, 7, 59, 0, 8, 120, 0, 8, 56, 0, 9, 208, 81, 7, 17, 0, 8, 104, 0, 8, 40,\n-\t\t\t0, 9, 176, 0, 8, 8, 0, 8, 136, 0, 8, 72, 0, 9, 240, 80, 7, 4, 0, 8, 84, 0, 8, 20, 85, 8, 227, 83, 7, 43, 0, 8, 116, 0, 8, 52, 0, 9, 200, 81, 7, 13,\n-\t\t\t0, 8, 100, 0, 8, 36, 0, 9, 168, 0, 8, 4, 0, 8, 132, 0, 8, 68, 0, 9, 232, 80, 7, 8, 0, 8, 92, 0, 8, 28, 0, 9, 152, 84, 7, 83, 0, 8, 124, 0, 8, 60,\n-\t\t\t0, 9, 216, 82, 7, 23, 0, 8, 108, 0, 8, 44, 0, 9, 184, 0, 8, 12, 0, 8, 140, 0, 8, 76, 0, 9, 248, 80, 7, 3, 0, 8, 82, 0, 8, 18, 85, 8, 163, 83, 7,\n-\t\t\t35, 0, 8, 114, 0, 8, 50, 0, 9, 196, 81, 7, 11, 0, 8, 98, 0, 8, 34, 0, 9, 164, 0, 8, 2, 0, 8, 130, 0, 8, 66, 0, 9, 228, 80, 7, 7, 0, 8, 90, 0, 8,\n-\t\t\t26, 0, 9, 148, 84, 7, 67, 0, 8, 122, 0, 8, 58, 0, 9, 212, 82, 7, 19, 0, 8, 106, 0, 8, 42, 0, 9, 180, 0, 8, 10, 0, 8, 138, 0, 8, 74, 0, 9, 244, 80,\n-\t\t\t7, 5, 0, 8, 86, 0, 8, 22, 192, 8, 0, 83, 7, 51, 0, 8, 118, 0, 8, 54, 0, 9, 204, 81, 7, 15, 0, 8, 102, 0, 8, 38, 0, 9, 172, 0, 8, 6, 0, 8, 134, 0,\n-\t\t\t8, 70, 0, 9, 236, 80, 7, 9, 0, 8, 94, 0, 8, 30, 0, 9, 156, 84, 7, 99, 0, 8, 126, 0, 8, 62, 0, 9, 220, 82, 7, 27, 0, 8, 110, 0, 8, 46, 0, 9, 188, 0,\n-\t\t\t8, 14, 0, 8, 142, 0, 8, 78, 0, 9, 252, 96, 7, 256, 0, 8, 81, 0, 8, 17, 85, 8, 131, 82, 7, 31, 0, 8, 113, 0, 8, 49, 0, 9, 194, 80, 7, 10, 0, 8, 97,\n-\t\t\t0, 8, 33, 0, 9, 162, 0, 8, 1, 0, 8, 129, 0, 8, 65, 0, 9, 226, 80, 7, 6, 0, 8, 89, 0, 8, 25, 0, 9, 146, 83, 7, 59, 0, 8, 121'..b'tate.marker = m;\n-\n-\t\t\t// return no joy or set up to restart on a new block\n-\t\t\tif (m != 4) {\n-\t\t\t\treturn Z_DATA_ERROR;\n-\t\t\t}\n-\t\t\tr = z.total_in;\n-\t\t\tw = z.total_out;\n-\t\t\tinflateReset(z);\n-\t\t\tz.total_in = r;\n-\t\t\tz.total_out = w;\n-\t\t\tz.istate.mode = BLOCKS;\n-\t\t\treturn Z_OK;\n-\t\t};\n-\n-\t\t// Returns true if inflate is currently at the end of a block generated\n-\t\t// by Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP\n-\t\t// implementation to provide an additional safety check. PPP uses\n-\t\t// Z_SYNC_FLUSH\n-\t\t// but removes the length bytes of the resulting empty stored block. When\n-\t\t// decompressing, PPP checks that at the end of input packet, inflate is\n-\t\t// waiting for these length bytes.\n-\t\tthat.inflateSyncPoint = function(z) {\n-\t\t\tif (!z || !z.istate || !z.istate.blocks)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn z.istate.blocks.sync_point();\n-\t\t};\n-\t}\n-\n-\t// ZStream\n-\n-\tfunction ZStream() {\n-\t}\n-\n-\tZStream.prototype = {\n-\t\tinflateInit : function(bits) {\n-\t\t\tvar that = this;\n-\t\t\tthat.istate = new Inflate();\n-\t\t\tif (!bits)\n-\t\t\t\tbits = MAX_BITS;\n-\t\t\treturn that.istate.inflateInit(that, bits);\n-\t\t},\n-\n-\t\tinflate : function(f) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflate(that, f);\n-\t\t},\n-\n-\t\tinflateEnd : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\tvar ret = that.istate.inflateEnd(that);\n-\t\t\tthat.istate = null;\n-\t\t\treturn ret;\n-\t\t},\n-\n-\t\tinflateSync : function() {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSync(that);\n-\t\t},\n-\t\tinflateSetDictionary : function(dictionary, dictLength) {\n-\t\t\tvar that = this;\n-\t\t\tif (!that.istate)\n-\t\t\t\treturn Z_STREAM_ERROR;\n-\t\t\treturn that.istate.inflateSetDictionary(that, dictionary, dictLength);\n-\t\t},\n-\t\tread_byte : function(start) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + 1)[0];\n-\t\t},\n-\t\tread_buf : function(start, size) {\n-\t\t\tvar that = this;\n-\t\t\treturn that.next_in.subarray(start, start + size);\n-\t\t}\n-\t};\n-\n-\t// Inflater\n-\n-\tfunction Inflater() {\n-\t\tvar that = this;\n-\t\tvar z = new ZStream();\n-\t\tvar bufsize = 512;\n-\t\tvar flush = Z_NO_FLUSH;\n-\t\tvar buf = new Uint8Array(bufsize);\n-\t\tvar nomoreinput = false;\n-\n-\t\tz.inflateInit();\n-\t\tz.next_out = buf;\n-\n-\t\tthat.append = function(data, onprogress) {\n-\t\t\tvar err, buffers = [], lastIndex = 0, bufferIndex = 0, bufferSize = 0, array;\n-\t\t\tif (data.length === 0)\n-\t\t\t\treturn;\n-\t\t\tz.next_in_index = 0;\n-\t\t\tz.next_in = data;\n-\t\t\tz.avail_in = data.length;\n-\t\t\tdo {\n-\t\t\t\tz.next_out_index = 0;\n-\t\t\t\tz.avail_out = bufsize;\n-\t\t\t\tif ((z.avail_in === 0) && (!nomoreinput)) { // if buffer is empty and more input is available, refill it\n-\t\t\t\t\tz.next_in_index = 0;\n-\t\t\t\t\tnomoreinput = true;\n-\t\t\t\t}\n-\t\t\t\terr = z.inflate(flush);\n-\t\t\t\tif (nomoreinput && (err === Z_BUF_ERROR)) {\n-\t\t\t\t\tif (z.avail_in !== 0)\n-\t\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\t} else if (err !== Z_OK && err !== Z_STREAM_END)\n-\t\t\t\t\tthrow new Error("inflating: " + z.msg);\n-\t\t\t\tif ((nomoreinput || err === Z_STREAM_END) && (z.avail_in === data.length))\n-\t\t\t\t\tthrow new Error("inflating: bad input");\n-\t\t\t\tif (z.next_out_index)\n-\t\t\t\t\tif (z.next_out_index === bufsize)\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf));\n-\t\t\t\t\telse\n-\t\t\t\t\t\tbuffers.push(new Uint8Array(buf.subarray(0, z.next_out_index)));\n-\t\t\t\tbufferSize += z.next_out_index;\n-\t\t\t\tif (onprogress && z.next_in_index > 0 && z.next_in_index != lastIndex) {\n-\t\t\t\t\tonprogress(z.next_in_index);\n-\t\t\t\t\tlastIndex = z.next_in_index;\n-\t\t\t\t}\n-\t\t\t} while (z.avail_in > 0 || z.avail_out === 0);\n-\t\t\tarray = new Uint8Array(bufferSize);\n-\t\t\tbuffers.forEach(function(chunk) {\n-\t\t\t\tarray.set(chunk, bufferIndex);\n-\t\t\t\tbufferIndex += chunk.length;\n-\t\t\t});\n-\t\t\treturn array;\n-\t\t};\n-\t\tthat.flush = function() {\n-\t\t\tz.inflateEnd();\n-\t\t};\n-\t}\n-\n-\t// \'zip\' may not be defined in z-worker and some tests\n-\tvar env = global.zip || global;\n-\tenv.Inflater = env._jzlib_Inflater = Inflater;\n-})(this);\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/lib/jspdf.debug.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/lib/jspdf.debug.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,9359 +0,0 @@\n-/** @preserve\r\n- * jsPDF - PDF Document creation from JavaScript\r\n- * Version 1.0.272-git Built on 2014-09-29T15:09\r\n- *                           CommitID d4770725ca\r\n- *\r\n- * Copyright (c) 2010-2014 James Hall, https://github.com/MrRio/jsPDF\r\n- *               2010 Aaron Spike, https://github.com/acspike\r\n- *               2012 Willow Systems Corporation, willow-systems.com\r\n- *               2012 Pablo Hess, https://github.com/pablohess\r\n- *               2012 Florian Jenett, https://github.com/fjenett\r\n- *               2013 Warren Weckesser, https://github.com/warrenweckesser\r\n- *               2013 Youssef Beddad, https://github.com/lifof\r\n- *               2013 Lee Driscoll, https://github.com/lsdriscoll\r\n- *               2013 Stefan Slonevskiy, https://github.com/stefslon\r\n- *               2013 Jeremy Morel, https://github.com/jmorel\r\n- *               2013 Christoph Hartmann, https://github.com/chris-rock\r\n- *               2014 Juan Pablo Gaviria, https://github.com/juanpgaviria\r\n- *               2014 James Makes, https://github.com/dollaruw\r\n- *               2014 Diego Casorran, https://github.com/diegocr\r\n- *\r\n- * Permission is hereby granted, free of charge, to any person obtaining\r\n- * a copy of this software and associated documentation files (the\r\n- * "Software"), to deal in the Software without restriction, including\r\n- * without limitation the rights to use, copy, modify, merge, publish,\r\n- * distribute, sublicense, and/or sell copies of the Software, and to\r\n- * permit persons to whom the Software is furnished to do so, subject to\r\n- * the following conditions:\r\n- *\r\n- * The above copyright notice and this permission notice shall be\r\n- * included in all copies or substantial portions of the Software.\r\n- *\r\n- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,\r\n- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r\n- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\r\n- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\r\n- * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\r\n- * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\r\n- * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r\n- *\r\n- * Contributor(s):\r\n- *    siefkenj, ahwolf, rickygu, Midnith, saintclair, eaparango,\r\n- *    kim3er, mfo, alnorth,\r\n- */\r\n-\r\n-/**\r\n- * Creates new jsPDF document object instance.\r\n- *\r\n- * @class\r\n- * @param orientation One of "portrait" or "landscape" (or shortcuts "p" (Default), "l")\r\n- * @param unit        Measurement unit to be used when coordinates are specified.\r\n- *                    One of "pt" (points), "mm" (Default), "cm", "in"\r\n- * @param format      One of \'pageFormats\' as shown below, default: a4\r\n- * @returns {jsPDF}\r\n- * @name jsPDF\r\n- */\r\n-var jsPDF = (function(global) {\r\n-\t\'use strict\';\r\n-\tvar pdfVersion = \'1.3\',\r\n-\t\tpageFormats = { // Size in pt of various paper formats\r\n-\t\t\t\'a0\'  : [2383.94, 3370.39], \'a1\'  : [1683.78, 2383.94],\r\n-\t\t\t\'a2\'  : [1190.55, 1683.78], \'a3\'  : [ 841.89, 1190.55],\r\n-\t\t\t\'a4\'  : [ 595.28,  841.89], \'a5\'  : [ 419.53,  595.28],\r\n-\t\t\t\'a6\'  : [ 297.64,  419.53], \'a7\'  : [ 209.76,  297.64],\r\n-\t\t\t\'a8\'  : [ 147.40,  209.76], \'a9\'  : [ 104.88,  147.40],\r\n-\t\t\t\'a10\' : [  73.70,  104.88], \'b0\'  : [2834.65, 4008.19],\r\n-\t\t\t\'b1\'  : [2004.09, 2834.65], \'b2\'  : [1417.32, 2004.09],\r\n-\t\t\t\'b3\'  : [1000.63, 1417.32], \'b4\'  : [ 708.66, 1000.63],\r\n-\t\t\t\'b5\'  : [ 498.90,  708.66], \'b6\'  : [ 354.33,  498.90],\r\n-\t\t\t\'b7\'  : [ 249.45,  354.33], \'b8\'  : [ 175.75,  249.45],\r\n-\t\t\t\'b9\'  : [ 124.72,  175.75], \'b10\' : [  87.87,  124.72],\r\n-\t\t\t\'c0\'  : [2599.37, 3676.54], \'c1\'  : [1836.85, 2599.37],\r\n-\t\t\t\'c2\'  : [1298.27, 1836.85], \'c3\'  : [ 918.43, 1298.27],\r\n-\t\t\t\'c4\'  : [ 649.13,  918.43], \'c5\'  : [ 459.21,  649.13],\r\n-\t\t\t\'c6\'  : [ 323.15,  459.21], \'c7\'  : [ 229.61,  323.15],\r\n-\t\t\t\'c8\'  : [ 161.57,  229.61], \'c9\'  : [ 113.39,  161.57],\r\n-\t\t\t\'c10\' : [  79.37,  113.39], \'dl\'  : ['..b'\t\t\t//    input by: Aman Gupta\r\n-\t\t\t//    input by: Brett Zamir (http://brett-zamir.me)\r\n-\t\t\t// bugfixed by: Onno Marsman\r\n-\t\t\t// bugfixed by: Pellentesque Malesuada\r\n-\t\t\t// bugfixed by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)\r\n-\t\t\t//   example 1: base64_decode(\'S2V2aW4gdmFuIFpvbm5ldmVsZA==\');\r\n-\t\t\t//   returns 1: \'Kevin van Zonneveld\'\r\n-\r\n-\t\t\tvar o1,o2,o3,h1,h2,h3,h4,bits,i = 0,ac = 0,dec = \'\',tmp_arr = [];\r\n-\r\n-\t\t\tif (!data) {\r\n-\t\t\t\treturn data;\r\n-\t\t\t}\r\n-\r\n-\t\t\tdata += \'\';\r\n-\r\n-\t\t\tdo { // unpack four hexets into three octets using index points in b64\r\n-\t\t\t\th1 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th2 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th3 = b64.indexOf(data.charAt(i++));\r\n-\t\t\t\th4 = b64.indexOf(data.charAt(i++));\r\n-\r\n-\t\t\t\tbits = h1 << 18 | h2 << 12 | h3 << 6 | h4;\r\n-\r\n-\t\t\t\to1 = bits >> 16 & 0xff;\r\n-\t\t\t\to2 = bits >> 8 & 0xff;\r\n-\t\t\t\to3 = bits & 0xff;\r\n-\r\n-\t\t\t\tif (h3 == 64) {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1);\r\n-\t\t\t\t} else if (h4 == 64) {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1, o2);\r\n-\t\t\t\t} else {\r\n-\t\t\t\t\ttmp_arr[ac++] = String.fromCharCode(o1, o2, o3);\r\n-\t\t\t\t}\r\n-\t\t\t} while (i < data.length);\r\n-\r\n-\t\t\tdec = tmp_arr.join(\'\');\r\n-\r\n-\t\t\treturn dec;\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Array.prototype.map) {\r\n-\t\tArray.prototype.map = function(fun /*, thisArg */) {\r\n-\t\t\tif (this === void 0 || this === null || typeof fun !== "function")\r\n-\t\t\t\tthrow new TypeError();\r\n-\r\n-\t\t\tvar t = Object(this), len = t.length >>> 0, res = new Array(len);\r\n-\t\t\tvar thisArg = arguments.length > 1 ? arguments[1] : void 0;\r\n-\t\t\tfor (var i = 0; i < len; i++) {\r\n-\t\t\t\t// NOTE: Absolute correctness would demand Object.defineProperty\r\n-\t\t\t\t//       be used.  But this method is fairly new, and failure is\r\n-\t\t\t\t//       possible only if Object.prototype or Array.prototype\r\n-\t\t\t\t//       has a property |i| (very unlikely), so use a less-correct\r\n-\t\t\t\t//       but more portable alternative.\r\n-\t\t\t\tif (i in t)\r\n-\t\t\t\t\tres[i] = fun.call(thisArg, t[i], i, t);\r\n-\t\t\t}\r\n-\r\n-\t\t\treturn res;\r\n-\t\t};\r\n-\t}\r\n-\r\n-\r\n-\tif(!Array.isArray) {\r\n-\t\tArray.isArray = function(arg) {\r\n-\t\t\treturn Object.prototype.toString.call(arg) === \'[object Array]\';\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Array.prototype.forEach) {\r\n-\t\tArray.prototype.forEach = function(fun, thisArg) {\r\n-\t\t\t"use strict";\r\n-\r\n-\t\t\tif (this === void 0 || this === null || typeof fun !== "function")\r\n-\t\t\t\tthrow new TypeError();\r\n-\r\n-\t\t\tvar t = Object(this), len = t.length >>> 0;\r\n-\t\t\tfor (var i = 0; i < len; i++) {\r\n-\t\t\t\tif (i in t)\r\n-\t\t\t\t\tfun.call(thisArg, t[i], i, t);\r\n-\t\t\t}\r\n-\t\t};\r\n-\t}\r\n-\r\n-\tif (!Object.keys) {\r\n-\t\tObject.keys = (function () {\r\n-\t\t\t\'use strict\';\r\n-\r\n-\t\t\tvar hasOwnProperty = Object.prototype.hasOwnProperty,\r\n-\t\t\t\thasDontEnumBug = !({toString: null}).propertyIsEnumerable(\'toString\'),\r\n-\t\t\t\tdontEnums = [\'toString\',\'toLocaleString\',\'valueOf\',\'hasOwnProperty\',\r\n-\t\t\t\t\t\'isPrototypeOf\',\'propertyIsEnumerable\',\'constructor\'],\r\n-\t\t\t\tdontEnumsLength = dontEnums.length;\r\n-\r\n-\t\t\treturn function (obj) {\r\n-\t\t\t\tif (typeof obj !== \'object\' && (typeof obj !== \'function\' || obj === null)) {\r\n-\t\t\t\t\tthrow new TypeError();\r\n-\t\t\t\t}\r\n-\t\t\t\tvar result = [], prop, i;\r\n-\r\n-\t\t\t\tfor (prop in obj) {\r\n-\t\t\t\t\tif (hasOwnProperty.call(obj, prop)) {\r\n-\t\t\t\t\t\tresult.push(prop);\r\n-\t\t\t\t\t}\r\n-\t\t\t\t}\r\n-\r\n-\t\t\t\tif (hasDontEnumBug) {\r\n-\t\t\t\t\tfor (i = 0; i < dontEnumsLength; i++) {\r\n-\t\t\t\t\t\tif (hasOwnProperty.call(obj, dontEnums[i])) {\r\n-\t\t\t\t\t\t\tresult.push(dontEnums[i]);\r\n-\t\t\t\t\t\t}\r\n-\t\t\t\t\t}\r\n-\t\t\t\t}\r\n-\t\t\t\treturn result;\r\n-\t\t\t};\r\n-\t\t}());\r\n-\t}\r\n-\r\n-\tif (!String.prototype.trim) {\r\n-\t\tString.prototype.trim = function () {\r\n-\t\t\treturn this.replace(/^\\s+|\\s+$/g, \'\');\r\n-\t\t};\r\n-\t}\r\n-\tif (!String.prototype.trimLeft) {\r\n-\t\tString.prototype.trimLeft = function() {\r\n-\t\t\treturn this.replace(/^\\s+/g, "");\r\n-\t\t};\r\n-\t}\r\n-\tif (!String.prototype.trimRight) {\r\n-\t\tString.prototype.trimRight = function() {\r\n-\t\t\treturn this.replace(/\\s+$/g, "");\r\n-\t\t};\r\n-\t}\r\n-\r\n-})(typeof self !== "undefined" && self || typeof window !== "undefined" && window || this);\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/lib/z-worker.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/lib/z-worker.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,153 +0,0 @@
-/* jshint worker:true */
-(function main(global) {
- "use strict";
-
- if (global.zWorkerInitialized)
- throw new Error('z-worker.js should be run only once');
- global.zWorkerInitialized = true;
-
- addEventListener("message", function(event) {
- var message = event.data, type = message.type, sn = message.sn;
- var handler = handlers[type];
- if (handler) {
- try {
- handler(message);
- } catch (e) {
- onError(type, sn, e);
- }
- }
- //for debug
- //postMessage({type: 'echo', originalType: type, sn: sn});
- });
-
- var handlers = {
- importScripts: doImportScripts,
- newTask: newTask,
- append: processData,
- flush: processData,
- };
-
- // deflater/inflater tasks indexed by serial numbers
- var tasks = {};
-
- function doImportScripts(msg) {
- if (msg.scripts && msg.scripts.length > 0)
- importScripts.apply(undefined, msg.scripts);
- postMessage({type: 'importScripts'});
- }
-
- function newTask(msg) {
- var CodecClass = global[msg.codecClass];
- var sn = msg.sn;
- if (tasks[sn])
- throw Error('duplicated sn');
- tasks[sn] =  {
- codec: new CodecClass(msg.options),
- crcInput: msg.crcType === 'input',
- crcOutput: msg.crcType === 'output',
- crc: new Crc32(),
- };
- postMessage({type: 'newTask', sn: sn});
- }
-
- // performance may not be supported
- var now = global.performance ? global.performance.now.bind(global.performance) : Date.now;
-
- function processData(msg) {
- var sn = msg.sn, type = msg.type, input = msg.data;
- var task = tasks[sn];
- // allow creating codec on first append
- if (!task && msg.codecClass) {
- newTask(msg);
- task = tasks[sn];
- }
- var isAppend = type === 'append';
- var start = now();
- var output;
- if (isAppend) {
- try {
- output = task.codec.append(input, function onprogress(loaded) {
- postMessage({type: 'progress', sn: sn, loaded: loaded});
- });
- } catch (e) {
- delete tasks[sn];
- throw e;
- }
- } else {
- delete tasks[sn];
- output = task.codec.flush();
- }
- var codecTime = now() - start;
-
- start = now();
- if (input && task.crcInput)
- task.crc.append(input);
- if (output && task.crcOutput)
- task.crc.append(output);
- var crcTime = now() - start;
-
- var rmsg = {type: type, sn: sn, codecTime: codecTime, crcTime: crcTime};
- var transferables = [];
- if (output) {
- rmsg.data = output;
- transferables.push(output.buffer);
- }
- if (!isAppend && (task.crcInput || task.crcOutput))
- rmsg.crc = task.crc.get();
-
- // posting a message with transferables will fail on IE10
- try {
- postMessage(rmsg, transferables);
- } catch(ex) {
- postMessage(rmsg); // retry without transferables
- }
- }
-
- function onError(type, sn, e) {
- var msg = {
- type: type,
- sn: sn,
- error: formatError(e)
- };
- postMessage(msg);
- }
-
- function formatError(e) {
- return { message: e.message, stack: e.stack };
- }
-
- // Crc32 code copied from file zip.js
- function Crc32() {
- this.crc = -1;
- }
- Crc32.prototype.append = function append(data) {
- var crc = this.crc | 0, table = this.table;
- for (var offset = 0, len = data.length | 0; offset < len; offset++)
- crc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];
- this.crc = crc;
- };
- Crc32.prototype.get = function get() {
- return ~this.crc;
- };
- Crc32.prototype.table = (function() {
- var i, j, t, table = []; // Uint32Array is actually slower than []
- for (i = 0; i < 256; i++) {
- t = i;
- for (j = 0; j < 8; j++)
- if (t & 1)
- t = (t >>> 1) ^ 0xEDB88320;
- else
- t = t >>> 1;
- table[i] = t;
- }
- return table;
- })();
-
- // "no-op" codec
- function NOOP() {}
- global.NOOP = NOOP;
- NOOP.prototype.append = function append(bytes, onprogress) {
- return bytes;
- };
- NOOP.prototype.flush = function flush() {};
-})(this);
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/static/javascript/lib/zip.js
--- a/naNGCHMheatmap/MDAheatmap/static/javascript/lib/zip.js Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,966 +0,0 @@\n-/*\n- Copyright (c) 2013 Gildas Lormeau. All rights reserved.\n-\n- Redistribution and use in source and binary forms, with or without\n- modification, are permitted provided that the following conditions are met:\n-\n- 1. Redistributions of source code must retain the above copyright notice,\n- this list of conditions and the following disclaimer.\n-\n- 2. Redistributions in binary form must reproduce the above copyright\n- notice, this list of conditions and the following disclaimer in\n- the documentation and/or other materials provided with the distribution.\n-\n- 3. The names of the authors may not be used to endorse or promote products\n- derived from this software without specific prior written permission.\n-\n- THIS SOFTWARE IS PROVIDED ``AS IS\'\' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\n- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\n- FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,\n- INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,\n- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\n- OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\n- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\n- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,\n- EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n- */\n-\n-(function(obj) {\n-\t"use strict";\n-\n-\tvar ERR_BAD_FORMAT = "File format is not recognized.";\n-\tvar ERR_CRC = "CRC failed.";\n-\tvar ERR_ENCRYPTED = "File contains encrypted entry.";\n-\tvar ERR_ZIP64 = "File is using Zip64 (4gb+ file size).";\n-\tvar ERR_READ = "Error while reading zip file.";\n-\tvar ERR_WRITE = "Error while writing zip file.";\n-\tvar ERR_WRITE_DATA = "Error while writing file data.";\n-\tvar ERR_READ_DATA = "Error while reading file data.";\n-\tvar ERR_DUPLICATED_NAME = "File already exists.";\n-\tvar CHUNK_SIZE = 512 * 1024;\n-\t\n-\tvar TEXT_PLAIN = "text/plain";\n-\n-\tvar appendABViewSupported;\n-\ttry {\n-\t\tappendABViewSupported = new Blob([ new DataView(new ArrayBuffer(0)) ]).size === 0;\n-\t} catch (e) {\n-\t}\n-\n-\tfunction Crc32() {\n-\t\tthis.crc = -1;\n-\t}\n-\tCrc32.prototype.append = function append(data) {\n-\t\tvar crc = this.crc | 0, table = this.table;\n-\t\tfor (var offset = 0, len = data.length | 0; offset < len; offset++)\n-\t\t\tcrc = (crc >>> 8) ^ table[(crc ^ data[offset]) & 0xFF];\n-\t\tthis.crc = crc;\n-\t};\n-\tCrc32.prototype.get = function get() {\n-\t\treturn ~this.crc;\n-\t};\n-\tCrc32.prototype.table = (function() {\n-\t\tvar i, j, t, table = []; // Uint32Array is actually slower than []\n-\t\tfor (i = 0; i < 256; i++) {\n-\t\t\tt = i;\n-\t\t\tfor (j = 0; j < 8; j++)\n-\t\t\t\tif (t & 1)\n-\t\t\t\t\tt = (t >>> 1) ^ 0xEDB88320;\n-\t\t\t\telse\n-\t\t\t\t\tt = t >>> 1;\n-\t\t\ttable[i] = t;\n-\t\t}\n-\t\treturn table;\n-\t})();\n-\t\n-\t// "no-op" codec\n-\tfunction NOOP() {}\n-\tNOOP.prototype.append = function append(bytes, onprogress) {\n-\t\treturn bytes;\n-\t};\n-\tNOOP.prototype.flush = function flush() {};\n-\n-\tfunction blobSlice(blob, index, length) {\n-\t\tif (index < 0 || length < 0 || index + length > blob.size)\n-\t\t\tthrow new RangeError(\'offset:\' + index + \', length:\' + length + \', size:\' + blob.size);\n-\t\tif (blob.slice)\n-\t\t\treturn blob.slice(index, index + length);\n-\t\telse if (blob.webkitSlice)\n-\t\t\treturn blob.webkitSlice(index, index + length);\n-\t\telse if (blob.mozSlice)\n-\t\t\treturn blob.mozSlice(index, index + length);\n-\t\telse if (blob.msSlice)\n-\t\t\treturn blob.msSlice(index, index + length);\n-\t}\n-\n-\tfunction getDataHelper(byteLength, bytes) {\n-\t\tvar dataBuffer, dataArray;\n-\t\tdataBuffer = new ArrayBuffer(byteLength);\n-\t\tdataArray = new Uint8Array(dataBuffer);\n-\t\tif (bytes)\n-\t\t\tdataArray.set(bytes, 0);\n-\t\treturn {\n-\t\t\tbuffer : dataBuffer,\n-\t\t\tarray : dataArray,\n-\t\t\tview : new DataView(dataBuffer)\n-\t\t};\n-\t}\n-\n-\t// Readers\n-\tfunction Reader() {\n-\t}\n-\n-\tfunction TextReader(text) {\n-\t\tvar that = this, blobReader;\n-\n-\t\tfunction init(callback'..b"\tdata.view.setUint16(index + 10, filenames.length, true);\n-\t\t\t\tdata.view.setUint32(index + 12, length, true);\n-\t\t\t\tdata.view.setUint32(index + 16, datalength, true);\n-\t\t\t\twriter.writeUint8Array(data.array, function() {\n-\t\t\t\t\twriter.getData(callback);\n-\t\t\t\t}, onwriteerror);\n-\t\t\t},\n-\t\t\t_worker: null\n-\t\t};\n-\n-\t\tif (!obj.zip.useWebWorkers)\n-\t\t\tcallback(zipWriter);\n-\t\telse {\n-\t\t\tcreateWorker('deflater',\n-\t\t\t\tfunction(worker) {\n-\t\t\t\t\tzipWriter._worker = worker;\n-\t\t\t\t\tcallback(zipWriter);\n-\t\t\t\t},\n-\t\t\t\tfunction(err) {\n-\t\t\t\t\tonerror(err);\n-\t\t\t\t}\n-\t\t\t);\n-\t\t}\n-\t}\n-\n-\tfunction resolveURLs(urls) {\n-\t\tvar a = document.createElement('a');\n-\t\treturn urls.map(function(url) {\n-\t\t\ta.href = url;\n-\t\t\treturn a.href;\n-\t\t});\n-\t}\n-\n-\tvar DEFAULT_WORKER_SCRIPTS = {\n-\t\tdeflater: ['z-worker.js', 'deflate.js'],\n-\t\tinflater: ['z-worker.js', 'inflate.js']\n-\t};\n-\tfunction createWorker(type, callback, onerror) {\n-\t\tif (obj.zip.workerScripts !== null && obj.zip.workerScriptsPath !== null) {\n-\t\t\tonerror(new Error('Either zip.workerScripts or zip.workerScriptsPath may be set, not both.'));\n-\t\t\treturn;\n-\t\t}\n-\t\tvar scripts;\n-\t\tif (obj.zip.workerScripts) {\n-\t\t\tscripts = obj.zip.workerScripts[type];\n-\t\t\tif (!Array.isArray(scripts)) {\n-\t\t\t\tonerror(new Error('zip.workerScripts.' + type + ' is not an array!'));\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tscripts = resolveURLs(scripts);\n-\t\t} else {\n-\t\t\tscripts = DEFAULT_WORKER_SCRIPTS[type].slice(0);\n-\t\t\tscripts[0] = (obj.zip.workerScriptsPath || '') + scripts[0];\n-\t\t}\n-\t\tvar worker = new Worker(scripts[0]);\n-\t\t// record total consumed time by inflater/deflater/crc32 in this worker\n-\t\tworker.codecTime = worker.crcTime = 0;\n-\t\tworker.postMessage({ type: 'importScripts', scripts: scripts.slice(1) });\n-\t\tworker.addEventListener('message', onmessage);\n-\t\tfunction onmessage(ev) {\n-\t\t\tvar msg = ev.data;\n-\t\t\tif (msg.error) {\n-\t\t\t\tworker.terminate(); // should before onerror(), because onerror() may throw.\n-\t\t\t\tonerror(msg.error);\n-\t\t\t\treturn;\n-\t\t\t}\n-\t\t\tif (msg.type === 'importScripts') {\n-\t\t\t\tworker.removeEventListener('message', onmessage);\n-\t\t\t\tworker.removeEventListener('error', errorHandler);\n-\t\t\t\tcallback(worker);\n-\t\t\t}\n-\t\t}\n-\t\t// catch entry script loading error and other unhandled errors\n-\t\tworker.addEventListener('error', errorHandler);\n-\t\tfunction errorHandler(err) {\n-\t\t\tworker.terminate();\n-\t\t\tonerror(err);\n-\t\t}\n-\t}\n-\n-\tfunction onerror_default(error) {\n-\t\tconsole.error(error);\n-\t}\n-\tobj.zip = {\n-\t\tReader : Reader,\n-\t\tWriter : Writer,\n-\t\tBlobReader : BlobReader,\n-\t\tData64URIReader : Data64URIReader,\n-\t\tTextReader : TextReader,\n-\t\tBlobWriter : BlobWriter,\n-\t\tData64URIWriter : Data64URIWriter,\n-\t\tTextWriter : TextWriter,\n-\t\tcreateReader : function(reader, callback, onerror) {\n-\t\t\tonerror = onerror || onerror_default;\n-\n-\t\t\treader.init(function() {\n-\t\t\t\tcreateZipReader(reader, callback, onerror);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tcreateWriter : function(writer, callback, onerror, dontDeflate) {\n-\t\t\tonerror = onerror || onerror_default;\n-\t\t\tdontDeflate = !!dontDeflate;\n-\n-\t\t\twriter.init(function() {\n-\t\t\t\tcreateZipWriter(writer, callback, onerror, dontDeflate);\n-\t\t\t}, onerror);\n-\t\t},\n-\t\tuseWebWorkers : true,\n-\t\t/**\n-\t\t * Directory containing the default worker scripts (z-worker.js, deflate.js, and inflate.js), relative to current base url.\n-\t\t * E.g.: zip.workerScripts = './';\n-\t\t */\n-\t\tworkerScriptsPath : null,\n-\t\t/**\n-\t\t * Advanced option to control which scripts are loaded in the Web worker. If this option is specified, then workerScriptsPath must not be set.\n-\t\t * workerScripts.deflater/workerScripts.inflater should be arrays of urls to scripts for deflater/inflater, respectively.\n-\t\t * Scripts in the array are executed in order, and the first one should be z-worker.js, which is used to start the worker.\n-\t\t * All urls are relative to current base url.\n-\t\t * E.g.:\n-\t\t * zip.workerScripts = {\n-\t\t *   deflater: ['z-worker.js', 'deflate.js'],\n-\t\t *   inflater: ['z-worker.js', 'inflate.js']\n-\t\t * };\n-\t\t */\n-\t\tworkerScripts : null,\n-\t};\n-\n-})(this);\n"
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.mako
--- a/naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.mako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
b'@@ -1,145 +0,0 @@\n-<HTML>\r\n-   <HEAD>\r\n-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserHelpManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserPreferenceManager.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/PdfGenerator.js"></script>\r\n-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/jspdf.debug.js"></script>\r\n- \t <script src="/plugins/visualizations/MDAheatmap/static/javascript/custom.js"></script>\r\n-\r\n-\t <meta id=\'viewport\' name ="viewport" content="">\r\n-\r\n-   </HEAD>\r\n-   \r\n-   <BODY onresize="chmResize()">\r\n-    <%\r\n-       from galaxy import model\r\n-       users_current_history = trans.history\r\n-       url_dict = { }\r\n-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]\r\n-       output_datasets = hda.creating_job.output_datasets\r\n-       for o in output_datasets:\r\n-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )\r\n-    %>\r\n-\r\n-    <script>\r\n-       heatMap = null;  //global - heatmap object.\r\n- \t  staticPath = "/plugins/visualizations/MDAheatmap/static/"; //path for static web content - changes in galaxy.\r\n-\r\n-       var url_dict = ${ h.dumps( url_dict ) };\r\n-       var hdaId   = \'${trans.security.encode_id( hda.id )}\';\r\n-       var hdaExt  = \'${hda.ext}\';\r\n-       var ajaxUrl = "${h.url_for( controller=\'/datasets\', action=\'index\')}/" + hdaId + "/display?to_ext=" + hdaExt;\r\n-\r\n-       var xmlhttp=new XMLHttpRequest();\r\n-       xmlhttp.open("GET", ajaxUrl, true);\r\n-       xmlhttp.responseType = \'blob\';\r\n-       xmlhttp.onload = function(e) {\r\n-           if (this.status == 200) {\r\n-               var blob = new Blob([this.response], {type: \'compress/zip\'});\r\n-               zip.useWebWorkers = false;\r\n-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);\r\n-               var name = this.getResponseHeader("Content-Disposition");\r\n-               if (name.indexOf(\'[\') > -1) {\r\n-                 name = name.substring(name.indexOf(\'[\')+1, name.indexOf(\']\'));\r\n-               }               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);\r\n-               heatMap.addEventListener(processDetailMapUpdate);\r\n-               initSummaryDisplay();\r\n-               initDetailDisplay()\r\n-           }\r\n-       };\r\n-       xmlhttp.send();\r\n-\r\n-       function chmResize() {\r\n-          detailResize();\r\n-       }\r\n-\r\n-    </script>\r\n-\r\n-    <div class="mdaServiceHeader">\r\n-        <div class="mdaServiceHeaderLogo">\r\n-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">\r\n-        </div>\r\n-      \r\n-\t   <div id=\'detail_buttons\' align="center" style="display:none">\r\n- \t\t    <img id=\'zoomOut_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/zoom-out.png\' alt=\'Zoom Out\' onmouseover=\'detailDataToolHelp(this,"Zoom Out")\' onclick=\'detailDataZoomOut();\'   align="top"   />\r\n-\t\t    <img id=\'zoomIn_btn\' src=\'/plugins/visualizati'..b'MDAheatmap/static/images/prev.png\' alt=\'Previous\' onmouseover=\'userHelpClose();\' style="display:none;" onclick=\'searchPrev();\'  align="top"  />\r\n-\t\t    <img id=\'next_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/next.png\' alt=\'Next\' onmouseover=\'userHelpClose();\' style="display:none;" onclick=\'searchNext();\'  align="top"  />\r\n-\t\t    <img id=\'cancel_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/cancel.png\' alt=\'Cancel\' onmouseover=\'detailDataToolHelp(this,"Clear current search")\' style="display:none;" onclick=\'clearSearch();\'  align="top"  />\r\n-\t\t    <img id=\'pdf_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/pdf.png\' alt=\'go\' onmouseover=\'detailDataToolHelp(this,"Save as PDF")\' onclick=\'openPdfPrefs(this,null);\'  align="top" style="position: absolute; right: 60;"  />\r\n- \t    \t    <img id=\'gear_btn\' src=\'/plugins/visualizations/MDAheatmap/static/images/gear.png\' alt=\'Modify Map\' onmouseover=\'detailDataToolHelp(this,"Modify Map Preferences")\' onclick=\'editPreferences(this,null);\' align="top" style="position: absolute; right: 30;"  />\r\n-       </div>\r\n-    </div>\r\n-\r\n-    <div id="container">\r\n-\r\n-       <div id=\'summary_chm\' style=\'position: relative;\'>\r\n-          <canvas id=\'summary_canvas\'></canvas>\r\n-\t\t<div id=\'sumlabelDiv\' style="display: inline-block"></div>\r\n-       </div>\r\n-\r\n-\t  <div id= \'divider\' style=\'position: relative;\' onmousedown="dividerStart()" ontouchstart="dividerStart()">\r\n-\t  </div>\r\n-\r\n-       <div id=\'detail_chm\' style=\'position: relative;\'>\r\n-          <canvas id=\'detail_canvas\' style=\'display: inline-block\'></canvas>\r\n-          <div id=\'labelDiv\' style="display: inline-block"></div>\r\n-       </div>\r\n-   </div>\r\n-\r\n-\t<div id="pdfPrefsPanel" style="display: none; position: absolute; background-color: rgb(203, 219, 246);">\r\n-\t\t<div class="prefsHeader" id="pdfPrefsHeader">PDF Generation</div>\r\n-\t\t<table>\r\n-\t\t\t<tbody>\r\n-\t\t\t\t<tr>\r\n-\t\t\t\t\t<td>\r\n-\t\t\t\t\t\t<div id="pdfprefprefs" style="display: block; background-color: rgb(203, 219, 246);">\r\n-\t\t\t\t\t\t\t<div style="display: inherit; width: 220px; height: 220px;">\r\n-\t\t\t\t\t\t\t\t<h3 style="margin-bottom:0px;">Show maps:</h3>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputSummaryMap" type="radio" name="pages" value="summary"> Summary<br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputDetailMap" type="radio" name="pages" value="detail"> Detail<br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputBothMaps" type="radio" name="pages" value="both" checked> Both<br><br>\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputPages" type="checkbox" name="pages" value="separate"> Show maps on separate pages<br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputPortrait" type="radio" name="orientation" value="portrait"> Portrait \r\n-\t\t\t\t\t\t\t\t<input id="pdfInputLandscape" type="radio" name="orientation" value="Landscape" checked> Landscape <br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<h3 style="margin-bottom:0px;">Show classification bars:</h3>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputCondensed" type="radio" name="condensed" value="condensed"> Condensed \r\n-\t\t\t\t\t\t\t\t<input id="pdfInputHistogram" type="radio" name="condensed" value="histogram" checked> Histogram <br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputColumn" type="checkbox" name="class" value="row" checked> Column<br>\t\t\t\t\t\t\t\r\n-\t\t\t\t\t\t\t\t<input id="pdfInputRow" type="checkbox" name="class" value="column" checked> Row\r\n-\t\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t\t\t<table>\r\n-\t\t\t\t\t\t\t\t<tbody>\r\n-\t\t\t\t\t\t\t\t\t<tr>\r\n-\t\t\t\t\t\t\t\t\t\t<td style="font-weight: bold;">\r\n-\t\t\t\t\t\t\t\t\t\t\t<div id="pref_buttons" align="right">\r\n-\t\t\t\t\t\t\t\t\t\t\t\t<img id="prefCancel_btn" src="/plugins/visualizations/MDAheatmap/static/images/prefCancel.png" alt="Cancel changes" onclick="pdfCancelButton();" align="top">&nbsp;&nbsp;\r\n-\t\t\t\t\t\t\t\t\t\t\t\t<img id="prefCreate_btn" src="/plugins/visualizations/MDAheatmap/static/images/createPdf.png" alt="Create PDF" onclick="getPDF();" align="top">\r\n-\t\t\t\t\t\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t\t\t\t\t\t</td>\r\n-\t\t\t\t\t\t\t\t\t</tr>\r\n-\t\t\t\t\t\t\t\t</tbody>\r\n-\t\t\t\t\t\t\t</table>\r\n-\t\t\t\t\t\t</div>\r\n-\t\t\t\t\t</td>\r\n-\t\t\t\t</tr>\r\n-\t\t\t</tbody>\r\n-\t\t</table>\r\n-\t</div>\r\n-</BODY >\r\n-</HTML>\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.oldmako
--- a/naNGCHMheatmap/MDAheatmap/templates/MDAheatmap.oldmako Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,98 +0,0 @@
-<HTML>
-   <HEAD>
-      <link rel="stylesheet" href="/plugins/visualizations/MDAheatmap/static/css/NGCHM.css">
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/zip.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/lib/inflate.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/NGCHM_Util.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SelectionManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/MatrixManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/ColorMapManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/SummaryHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/DetailHeatMapDisplay.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserHelpManager.js"></script>
-      <script src="/plugins/visualizations/MDAheatmap/static/javascript/UserPreferenceManager.js"></script>
-
- <meta id='viewport' name ="viewport" content="">
-
-   </HEAD>
-   
-   <BODY onresize="chmResize()">
-    <%
-       from galaxy import model
-       users_current_history = trans.history
-       url_dict = { }
-       dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]
-       output_datasets = hda.creating_job.output_datasets
-       for o in output_datasets:
-              url_dict[ o.name ] = trans.security.encode_id( o.dataset_id )
-    %>
-
-    <script>
-       heatMap = null;  //global - heatmap object.
-
-       var url_dict = ${ h.dumps( url_dict ) };
-       var hdaId   = '${trans.security.encode_id( hda.id )}';
-       var hdaExt  = '${hda.ext}';
-       var ajaxUrl = "${h.url_for( controller='/datasets', action='index')}/" + hdaId + "/display?to_ext=" + hdaExt;
-
-       var xmlhttp=new XMLHttpRequest();
-       xmlhttp.open("GET", ajaxUrl, true);
-       xmlhttp.responseType = 'blob';
-       xmlhttp.onload = function(e) {
-           if (this.status == 200) {
-               var blob = new Blob([this.response], {type: 'compress/zip'});
-               zip.useWebWorkers = false;
-               var matrixMgr = new MatrixManager(MatrixManager.FILE_SOURCE);
-               var name = 'NGCHM';
-               heatMap = matrixMgr.getHeatMap(name,  processSummaryMapUpdate, blob);
-               heatMap.addEventListener(processDetailMapUpdate);
-               initSummaryDisplay();
-               initDetailDisplay()
-           }
-       };
-       xmlhttp.send();
-
-       function chmResize() {
-          detailResize();
-       }
-
-    </script>
-
-    <div class="mdaServiceHeader">
-        <div class="mdaServiceHeaderLogo">
-            <img src="/plugins/visualizations/MDAheatmap/static/images/mdandersonlogo260x85.png" alt="">
-        </div>
-      
-        <div id='detail_buttons' align="center" style="display:none">
-  <img id='zoomOut_btn' src='/plugins/visualizations/MDAheatmap/static/images/zoom-out.png' alt='Zoom Out' onmouseover='detailDataToolHelp(this,"Zoom Out")' onclick='detailDataZoomOut();'   align="top"   />
-     <img id='zoomIn_btn' src='/plugins/visualizations/MDAheatmap/static/images/zoom-in.png' alt='Zoom In' onmouseover='detailDataToolHelp(this,"Zoom In")' onclick='detailDataZoomIn();' align="top"   />
-     <img id='full_btn' src='/plugins/visualizations/MDAheatmap/static/images/full_selected.png' alt='Full' onmouseover='detailDataToolHelp(this,"Normal View")' onclick='detailNormal();' align="top"   />
-     <img id='ribbonH_btn' src='/plugins/visualizations/MDAheatmap/static/images/ribbonH.png' alt='Ribbon H' onmouseover='detailDataToolHelp(this,"Horizontal Ribbon View")' onclick='detailHRibbonButton();' align="top"  />
-     <img id='ribbonV_btn' src='/plugins/visualizations/MDAheatmap/static/images/ribbonV.png' alt='Ribbon V' onmouseover='detailDataToolHelp(this,"Vertical Ribbon View")' onclick='detailVRibbonButton();'  align="top"  />
-    <span style='display: inline-block;'><b>Search: </b><input type="text" id="search_text" name="search" onkeypress='clearSrchBtns();' onchange='detailSearch();'
-                                                         onmouseover='detailDataToolHelp(this,"Search Row/Column Labels. Separate search terms with spaces or commas. Use * for wild card matching. Hit enter or Go to run the search. If the search box turns red none of the search terms were found. If it turns yellow only some of the search terms were found.", 200)' ></span>
-     <img id='go_btn' src='/plugins/visualizations/MDAheatmap/static/images/go.png' alt='Go' onmouseover='detailDataToolHelp(this,"Search Row/Column Labels")'  onclick='detailSearch();' align="top"  />
-     <img id='prev_btn' src='/plugins/visualizations/MDAheatmap/static/images/prev.png' alt='Previous' onmouseover='userHelpClose();' style="display:none;" onclick='searchPrev();'  align="top"  />
-     <img id='next_btn' src='/plugins/visualizations/MDAheatmap/static/images/next.png' alt='Next' onmouseover='userHelpClose();' style="display:none;" onclick='searchNext();'  align="top"  />
-     <img id='cancel_btn' src='/plugins/visualizations/MDAheatmap/static/images/cancel.png' alt='Cancel' onmouseover='detailDataToolHelp(this,"Clear current search")' style="display:none;" onclick='clearSearch();'  align="top"  />
-       </div>
-    </div>
-
-    <div id="container">
-
-       <div id='summary_chm' style='position: relative;'>
-          <canvas id='summary_canvas'></canvas>
- <div id='sumlabelDiv' style="display: inline-block"></div>
-       </div>
-
-   <div id= 'divider' style='position: relative;' onmousedown="dividerStart()" ontouchstart="dividerStart()">
-   </div>
-
-       <div id='detail_chm' style='position: relative;'>
-          <canvas id='detail_canvas' style='display: inline-block'></canvas>
-          <div id='labelDiv' style="display: inline-block"></div>
-       </div>
-   </div>
-
-</BODY >
-</HTML>
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/NGCHMheatmap.xml
--- a/naNGCHMheatmap/NGCHMheatmap.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,84 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<tool id="NGCHMheatmap" name="NGCHM Heatmap" version="4.1.2">
-  <description>Create Dynamic Clustered HeatMap from Matrix and Covariate files</description>
-<command>$GALAXY_ROOT_DIR/tools/MDA_Heatmaps/heatmap.sh  '$hmname' '$hmdesc' '$inputmatrix' $rowOrderMethod $rowDistanceMeasure $rowAgglomerationMethod $columnOrderMethod $columnDistanceMeasure $columnAgglomerationMethod '$summarymethod' '$GALAXY_ROOT_DIR/tools/MDA_Heatmaps/'
-    #for $op in $operations
-       ${op.class_name}
-       ${op.repeatinput.file_name}
-       ${op.cat}
-      #end for
-  '$output' 
- </command>
- <stdio>
-      <exit_code range="1:" level="fatal" />
- </stdio>
-  <inputs>
-    <param name="inputmatrix" type="data" label="Input Matrix" />
-    <param name="hmname" size="20" type="text" value="HM_name" label="User Defined HeatMap Name"/>
-    <param name="hmdesc" size="100" optional="true" type="text" value="_" label="Optional HeatMap Description"/>
-    <param name="summarymethod"  type="select"  label="Data Summarization Method">
- <option value="average">average</option>
- <option value="sample">sample</option>
- <option value="mode">mode</option>
-    </param>
- <param name="rowOrderMethod" type="select" label="Row ordering method" help="Choices -- Hierarchical Clustering, Original Order, Random">
- <option value="Hierarchical">Hierarchical Clustering</option>
- <option value="Original">Original Order</option>     
- <option value="Random">Random</option>     
- </param>
- <param name="rowDistanceMeasure" type="select"  label="Row Distance Metric" help="euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation">
- <option value="euclidean">Euclidean</option>
- <option value="binary">Binary</option>
- <option value="manhattan">Manhattan</option>
- <option value="maximum">Maximum</option>
- <option value="canberra">Canberra</option>     
- <option value="minkowski">Minkowski</option>     
- <option value="correlation">Correlation</option>     
- </param>
- <param name="rowAgglomerationMethod" type="select"  label="Row Clustering Method" help="Choices: 'average' for Average Linkage, 'complete' for Complete Linkage, 'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.">
- <option value="average">Average Linkage</option>
- <option value="complete">Complete Linkage</option>
- <option value="single">Single Linkage</option>
- <option value="ward">Ward</option>
- <option value="mcquitty">Mcquitty</option>     
- <option value="median">Median</option>     
- <option value="centroid">Centroid</option>     
- </param>
- <param name="columnOrderMethod" type="select" label="Column ordering method" help="Choices -- Hierarchical Clustering, Original Order, Random">
- <option value="Hierarchical">Hierarchical Clustering</option>
- <option value="Original">Original Order</option>     
- <option value="Random">Random</option>     
- </param>
- <param name="columnDistanceMeasure" type="select"  label="Column Distance Metric" help="euclidean, binary, manhattan, maximum, canberra, minkowski, or correlation">
- <option value="euclidean">Euclidean</option>
- <option value="binary">Binary</option>
- <option value="manhattan">Manhattan</option>
- <option value="maximum">Maximum</option>
- <option value="canberra">Canberra</option>     
- <option value="minkowski">Minkowski</option>     
- <option value="correlation">Correlation</option>     
- </param>
- <param name="columnAgglomerationMethod" type="select"  label="Column Clustering Method" help="Choices: 'average' for Average Linkage, 'complete' for Complete Linkage, 'single' for Single Linkage, 'ward', 'mcquitty', 'median', or 'centroid'.">
- <option value="average">Average Linkage</option>
- <option value="complete">Complete Linkage</option>
- <option value="single">Single Linkage</option>
- <option value="ward">Ward</option>
- <option value="mcquitty">Mcquitty</option>     
- <option value="median">Median</option>     
- <option value="centroid">Centroid</option>     
- </param>
-    <repeat name="operations" title="Covariate Bars">
-        <param name="class_name" size="20" type="text" value="" label="Axis Covariate Name"/>
-        <param name="repeatinput" type="data" format="text" label="Axis Covariate File"/>        
- <param name="cat" type="select" label="Axis Covariate Type">
-   <option value="row_categorical" >row categorical</option>
-   <option value="row_continuous" >row continuous</option>
-   <option value="column_categorical" >column categorical</option>
-   <option value="column_continuous" >column continuous</option>
- </param>
-    </repeat>       
-  </inputs>
-  <outputs>
-    <data name="output" label='${hmname}' format="zip"/>
-  </outputs>
-</tool>
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/._400x400-column-covariate.txt
b
Binary file naNGCHMheatmap/TestFiles/._400x400-column-covariate.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/._400x400-row-covariate.txt
b
Binary file naNGCHMheatmap/TestFiles/._400x400-row-covariate.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/._400x400.txt
b
Binary file naNGCHMheatmap/TestFiles/._400x400.txt has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/._Galaxy400x400-noCovariates.ngchm
b
Binary file naNGCHMheatmap/TestFiles/._Galaxy400x400-noCovariates.ngchm has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/400x400-column-covariate.txt
--- a/naNGCHMheatmap/TestFiles/400x400-column-covariate.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,1 +0,0 @@\n-TCGA_SAMP_1\t1111\rTCGA_SAMP_2\t1111\rTCGA_SAMP_3\t1111\rTCGA_SAMP_4\t1111\rTCGA_SAMP_5\t1111\rTCGA_SAMP_6\t1111\rTCGA_SAMP_7\t1111\rTCGA_SAMP_8\t1111\rTCGA_SAMP_9\t1111\rTCGA_SAMP_10\t1111\rTCGA_SAMP_11\t1111\rTCGA_SAMP_12\t1111\rTCGA_SAMP_13\t1111\rTCGA_SAMP_14\t1111\rTCGA_SAMP_15\t1111\rTCGA_SAMP_16\t1111\rTCGA_SAMP_17\t1111\rTCGA_SAMP_18\t1111\rTCGA_SAMP_19\t1111\rTCGA_SAMP_20\t1111\rTCGA_SAMP_21\t1111\rTCGA_SAMP_22\t22\rTCGA_SAMP_23\t22\rTCGA_SAMP_24\t22\rTCGA_SAMP_25\t22\rTCGA_SAMP_26\t22\rTCGA_SAMP_27\t22\rTCGA_SAMP_28\t22\rTCGA_SAMP_29\t22\rTCGA_SAMP_30\t22\rTCGA_SAMP_31\t22\rTCGA_SAMP_32\t22\rTCGA_SAMP_33\t22\rTCGA_SAMP_34\t22\rTCGA_SAMP_35\t22\rTCGA_SAMP_36\t22\rTCGA_SAMP_37\t333\rTCGA_SAMP_38\t333\rTCGA_SAMP_39\t333\rTCGA_SAMP_40\t333\rTCGA_SAMP_41\t333\rTCGA_SAMP_42\t333\rTCGA_SAMP_43\t333\rTCGA_SAMP_44\t333\rTCGA_SAMP_45\t333\rTCGA_SAMP_46\t333\rTCGA_SAMP_47\t333\rTCGA_SAMP_48\t333\rTCGA_SAMP_49\t333\rTCGA_SAMP_50\t333\rTCGA_SAMP_51\t1111\rTCGA_SAMP_52\t1111\rTCGA_SAMP_53\t1111\rTCGA_SAMP_54\t1111\rTCGA_SAMP_55\t1111\rTCGA_SAMP_56\t1111\rTCGA_SAMP_57\t1111\rTCGA_SAMP_58\t1111\rTCGA_SAMP_59\t1111\rTCGA_SAMP_60\t1111\rTCGA_SAMP_61\t1111\rTCGA_SAMP_62\t1111\rTCGA_SAMP_63\t1111\rTCGA_SAMP_64\t1111\rTCGA_SAMP_65\t1111\rTCGA_SAMP_66\t1111\rTCGA_SAMP_67\t1111\rTCGA_SAMP_68\t1111\rTCGA_SAMP_69\t1111\rTCGA_SAMP_70\t1111\rTCGA_SAMP_71\t1111\rTCGA_SAMP_72\t22\rTCGA_SAMP_73\t22\rTCGA_SAMP_74\t22\rTCGA_SAMP_75\t22\rTCGA_SAMP_76\t22\rTCGA_SAMP_77\t22\rTCGA_SAMP_78\t22\rTCGA_SAMP_79\t22\rTCGA_SAMP_80\t22\rTCGA_SAMP_81\t22\rTCGA_SAMP_82\t22\rTCGA_SAMP_83\t22\rTCGA_SAMP_84\t22\rTCGA_SAMP_85\t22\rTCGA_SAMP_86\t22\rTCGA_SAMP_87\t333\rTCGA_SAMP_88\t333\rTCGA_SAMP_89\t333\rTCGA_SAMP_90\t333\rTCGA_SAMP_91\t333\rTCGA_SAMP_92\t333\rTCGA_SAMP_93\t333\rTCGA_SAMP_94\t333\rTCGA_SAMP_95\t333\rTCGA_SAMP_96\t333\rTCGA_SAMP_97\t333\rTCGA_SAMP_98\t333\rTCGA_SAMP_99\t333\rTCGA_SAMP_100\t333\rTCGA_SAMP_101\t1111\rTCGA_SAMP_102\t1111\rTCGA_SAMP_103\t1111\rTCGA_SAMP_104\t1111\rTCGA_SAMP_105\t1111\rTCGA_SAMP_106\t1111\rTCGA_SAMP_107\t1111\rTCGA_SAMP_108\t1111\rTCGA_SAMP_109\t1111\rTCGA_SAMP_110\t1111\rTCGA_SAMP_111\t1111\rTCGA_SAMP_112\t1111\rTCGA_SAMP_113\t1111\rTCGA_SAMP_114\t1111\rTCGA_SAMP_115\t1111\rTCGA_SAMP_116\t1111\rTCGA_SAMP_117\t1111\rTCGA_SAMP_118\t1111\rTCGA_SAMP_119\t1111\rTCGA_SAMP_120\t1111\rTCGA_SAMP_121\t1111\rTCGA_SAMP_122\t22\rTCGA_SAMP_123\t22\rTCGA_SAMP_124\t22\rTCGA_SAMP_125\t22\rTCGA_SAMP_126\t22\rTCGA_SAMP_127\t22\rTCGA_SAMP_128\t22\rTCGA_SAMP_129\t22\rTCGA_SAMP_130\t22\rTCGA_SAMP_131\t22\rTCGA_SAMP_132\t22\rTCGA_SAMP_133\t22\rTCGA_SAMP_134\t22\rTCGA_SAMP_135\t22\rTCGA_SAMP_136\t22\rTCGA_SAMP_137\t333\rTCGA_SAMP_138\t333\rTCGA_SAMP_139\t333\rTCGA_SAMP_140\t333\rTCGA_SAMP_141\t333\rTCGA_SAMP_142\t333\rTCGA_SAMP_143\t333\rTCGA_SAMP_144\t333\rTCGA_SAMP_145\t333\rTCGA_SAMP_146\t333\rTCGA_SAMP_147\t333\rTCGA_SAMP_148\t333\rTCGA_SAMP_149\t333\rTCGA_SAMP_150\t333\rTCGA_SAMP_151\t1111\rTCGA_SAMP_152\t1111\rTCGA_SAMP_153\t1111\rTCGA_SAMP_154\t1111\rTCGA_SAMP_155\t1111\rTCGA_SAMP_156\t1111\rTCGA_SAMP_157\t1111\rTCGA_SAMP_158\t1111\rTCGA_SAMP_159\t1111\rTCGA_SAMP_160\t1111\rTCGA_SAMP_161\t1111\rTCGA_SAMP_162\t1111\rTCGA_SAMP_163\t1111\rTCGA_SAMP_164\t1111\rTCGA_SAMP_165\t1111\rTCGA_SAMP_166\t1111\rTCGA_SAMP_167\t1111\rTCGA_SAMP_168\t1111\rTCGA_SAMP_169\t1111\rTCGA_SAMP_170\t1111\rTCGA_SAMP_171\t1111\rTCGA_SAMP_172\t22\rTCGA_SAMP_173\t22\rTCGA_SAMP_174\t22\rTCGA_SAMP_175\t22\rTCGA_SAMP_176\t22\rTCGA_SAMP_177\t22\rTCGA_SAMP_178\t22\rTCGA_SAMP_179\t22\rTCGA_SAMP_180\t22\rTCGA_SAMP_181\t22\rTCGA_SAMP_182\t22\rTCGA_SAMP_183\t22\rTCGA_SAMP_184\t22\rTCGA_SAMP_185\t22\rTCGA_SAMP_186\t22\rTCGA_SAMP_187\t333\rTCGA_SAMP_188\t333\rTCGA_SAMP_189\t333\rTCGA_SAMP_190\t333\rTCGA_SAMP_191\t333\rTCGA_SAMP_192\t333\rTCGA_SAMP_193\t333\rTCGA_SAMP_194\t333\rTCGA_SAMP_195\t333\rTCGA_SAMP_196\t333\rTCGA_SAMP_197\t333\rTCGA_SAMP_198\t333\rTCGA_SAMP_199\t333\rTCGA_SAMP_200\t333\rTCGA_SAMP_201\t1111\rTCGA_SAMP_202\t1111\rTCGA_SAMP_203\t1111\rTCGA_SAMP_204\t1111\rTCGA_SAMP_205\t1111\rTCGA_SAMP_206\t1111\rTCGA_SAMP_207\t1111\rTCGA_SAMP_208\t1111\rTCGA_SAMP_209\t1111\rTCGA_SAMP_210\t1111\rTCGA_SAMP_211\t1111\rTCGA_SAMP_212\t1111\rTCGA_SAMP_213\t1111\rTCGA_SAMP_214\t1111\rTCGA_SAMP_215\t1111\rTCGA_SAMP_216\t1111\rTCGA_SAMP_217\t1111\rTCGA_SAMP_218\t1111\rTCGA_SAMP_219\t1111\rTCGA_SAMP_220\t1111\rTCGA_SAMP_221\t1111\rTCGA_SAMP_222\t22\rTCGA_SAMP_223\t22\rTCGA_SAMP_224\t22\rTCGA_SAMP_225\t22'..b'\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\r\t\n\\ No newline at end of file\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/400x400-row-covariate.txt
--- a/naNGCHMheatmap/TestFiles/400x400-row-covariate.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,1 +0,0 @@
-Gene_1 aaa Gene_2 aaa Gene_3 aaa Gene_4 aaa Gene_5 aaa Gene_6 aaa Gene_7 bb Gene_8 bb Gene_9 bb Gene_10 bb Gene_11 bb Gene_12 bb Gene_13 bb Gene_14 bb Gene_15 bb Gene_16 bb Gene_17 bb Gene_18 bb Gene_19 bb Gene_20 bb Gene_21 bb Gene_22 bb Gene_23 bb Gene_24 bb Gene_25 bb Gene_26 bb Gene_27 bb Gene_28 bb Gene_29 bb Gene_30 bb Gene_31 bb Gene_32 cccc Gene_33 cccc Gene_34 cccc Gene_35 cccc Gene_36 cccc Gene_37 cccc Gene_38 cccc Gene_39 cccc Gene_40 cccc Gene_41 cccc Gene_42 cccc Gene_43 cccc Gene_44 cccc Gene_45 cccc Gene_46 cccc Gene_47 cccc Gene_48 cccc Gene_49 aaa Gene_50 aaa Gene_51 aaa Gene_52 aaa Gene_53 aaa Gene_54 aaa Gene_55 bb Gene_56 bb Gene_57 aaa Gene_58 aaa Gene_59 aaa Gene_60 aaa Gene_61 aaa Gene_62 aaa Gene_63 bb Gene_64 bb Gene_65 bb Gene_66 bb Gene_67 bb Gene_68 bb Gene_69 bb Gene_70 bb Gene_71 bb Gene_72 bb Gene_73 bb Gene_74 bb Gene_75 bb Gene_76 bb Gene_77 bb Gene_78 bb Gene_79 bb Gene_80 bb Gene_81 bb Gene_82 bb Gene_83 bb Gene_84 bb Gene_85 bb Gene_86 bb Gene_87 bb Gene_88 cccc Gene_89 cccc Gene_90 cccc Gene_91 cccc Gene_92 cccc Gene_93 cccc Gene_94 cccc Gene_95 cccc Gene_96 cccc Gene_97 cccc Gene_98 cccc Gene_99 cccc Gene_100 cccc Gene_101 cccc Gene_102 cccc Gene_103 cccc Gene_104 cccc Gene_105 aaa Gene_106 aaa Gene_107 aaa Gene_108 aaa Gene_109 aaa Gene_110 aaa Gene_111 bb Gene_112 bb Gene_113 aaa Gene_114 aaa Gene_115 aaa Gene_116 aaa Gene_117 aaa Gene_118 aaa Gene_119 bb Gene_120 bb Gene_121 bb Gene_122 bb Gene_123 bb Gene_124 bb Gene_125 bb Gene_126 bb Gene_127 bb Gene_128 bb Gene_129 bb Gene_130 bb Gene_131 bb Gene_132 bb Gene_133 bb Gene_134 bb Gene_135 bb Gene_136 bb Gene_137 bb Gene_138 bb Gene_139 bb Gene_140 bb Gene_141 bb Gene_142 bb Gene_143 bb Gene_144 cccc Gene_145 cccc Gene_146 cccc Gene_147 cccc Gene_148 cccc Gene_149 cccc Gene_150 cccc Gene_151 cccc Gene_152 cccc Gene_153 cccc Gene_154 cccc Gene_155 cccc Gene_156 cccc Gene_157 cccc Gene_158 cccc Gene_159 cccc Gene_160 cccc Gene_161 aaa Gene_162 aaa Gene_163 aaa Gene_164 aaa Gene_165 aaa Gene_166 aaa Gene_167 bb Gene_168 bb Gene_169 aaa Gene_170 aaa Gene_171 aaa Gene_172 aaa Gene_173 aaa Gene_174 aaa Gene_175 bb Gene_176 bb Gene_177 bb Gene_178 bb Gene_179 bb Gene_180 bb Gene_181 bb Gene_182 bb Gene_183 bb Gene_184 bb Gene_185 bb Gene_186 bb Gene_187 bb Gene_188 bb Gene_189 bb Gene_190 bb Gene_191 bb Gene_192 bb Gene_193 bb Gene_194 bb Gene_195 bb Gene_196 bb Gene_197 bb Gene_198 bb Gene_199 bb Gene_200 cccc Gene_201 cccc Gene_202 cccc Gene_203 cccc Gene_204 cccc Gene_205 cccc Gene_206 cccc Gene_207 cccc Gene_208 cccc Gene_209 cccc Gene_210 cccc Gene_211 cccc Gene_212 cccc Gene_213 cccc Gene_214 cccc Gene_215 cccc Gene_216 cccc Gene_217 aaa Gene_218 aaa Gene_219 aaa Gene_220 aaa Gene_221 aaa Gene_222 aaa Gene_223 bb Gene_224 bb Gene_225 aaa Gene_226 aaa Gene_227 aaa Gene_228 aaa Gene_229 aaa Gene_230 aaa Gene_231 bb Gene_232 bb Gene_233 bb Gene_234 bb Gene_235 bb Gene_236 bb Gene_237 bb Gene_238 bb Gene_239 bb Gene_240 bb Gene_241 bb Gene_242 bb Gene_243 bb Gene_244 bb Gene_245 bb Gene_246 bb Gene_247 bb Gene_248 bb Gene_249 bb Gene_250 bb Gene_251 bb Gene_252 bb Gene_253 bb Gene_254 bb Gene_255 bb Gene_256 cccc Gene_257 cccc Gene_258 cccc Gene_259 cccc Gene_260 cccc Gene_261 cccc Gene_262 cccc Gene_263 cccc Gene_264 cccc Gene_265 cccc Gene_266 cccc Gene_267 cccc Gene_268 cccc Gene_269 cccc Gene_270 cccc Gene_271 cccc Gene_272 cccc Gene_273 aaa Gene_274 aaa Gene_275 aaa Gene_276 aaa Gene_277 aaa Gene_278 aaa Gene_279 bb Gene_280 bb Gene_281 aaa Gene_282 aaa Gene_283 aaa Gene_284 aaa Gene_285 aaa Gene_286 aaa Gene_287 bb Gene_288 bb Gene_289 bb Gene_290 bb Gene_291 bb Gene_292 bb Gene_293 bb Gene_294 bb Gene_295 bb Gene_296 bb Gene_297 bb Gene_298 bb Gene_299 bb Gene_300 bb Gene_301 bb Gene_302 bb Gene_303 bb Gene_304 bb Gene_305 bb Gene_306 bb Gene_307 bb Gene_308 bb Gene_309 bb Gene_310 bb Gene_311 bb Gene_312 cccc Gene_313 cccc Gene_314 cccc Gene_315 cccc Gene_316 cccc Gene_317 cccc Gene_318 cccc Gene_319 cccc Gene_320 cccc Gene_321 cccc Gene_322 cccc Gene_323 cccc Gene_324 cccc Gene_325 cccc Gene_326 cccc Gene_327 cccc Gene_328 cccc Gene_329 aaa Gene_330 aaa Gene_331 aaa Gene_332 aaa Gene_333 aaa Gene_334 aaa Gene_335 bb Gene_336 bb Gene_337 aaa Gene_338 aaa Gene_339 aaa Gene_340 aaa Gene_341 aaa Gene_342 aaa Gene_343 bb Gene_344 bb Gene_345 bb Gene_346 bb Gene_347 bb Gene_348 bb Gene_349 bb Gene_350 bb Gene_351 bb Gene_352 bb Gene_353 bb Gene_354 bb Gene_355 bb Gene_356 bb Gene_357 bb Gene_358 bb Gene_359 bb Gene_360 bb Gene_361 bb Gene_362 bb Gene_363 bb Gene_364 bb Gene_365 bb Gene_366 bb Gene_367 bb Gene_368 cccc Gene_369 cccc Gene_370 cccc Gene_371 cccc Gene_372 cccc Gene_373 cccc Gene_374 cccc Gene_375 cccc Gene_376 cccc Gene_377 cccc Gene_378 cccc Gene_379 cccc Gene_380 cccc Gene_381 cccc Gene_382 cccc Gene_383 cccc Gene_384 cccc Gene_385 aaa Gene_386 aaa Gene_387 aaa Gene_388 aaa Gene_389 aaa Gene_390 aaa Gene_391 bb Gene_392 bb Gene_393 aaa Gene_394 aaa Gene_395 aaa Gene_396 aaa Gene_397 aaa Gene_398 aaa Gene_399 bb Gene_400 bb
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/400x400.txt
--- a/naNGCHMheatmap/TestFiles/400x400.txt Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,401 +0,0 @@\n-\tTCGA_SAMP_1\tTCGA_SAMP_2\tTCGA_SAMP_3\tTCGA_SAMP_4\tTCGA_SAMP_5\tTCGA_SAMP_6\tTCGA_SAMP_7\tTCGA_SAMP_8\tTCGA_SAMP_9\tTCGA_SAMP_10\tTCGA_SAMP_11\tTCGA_SAMP_12\tTCGA_SAMP_13\tTCGA_SAMP_14\tTCGA_SAMP_15\tTCGA_SAMP_16\tTCGA_SAMP_17\tTCGA_SAMP_18\tTCGA_SAMP_19\tTCGA_SAMP_20\tTCGA_SAMP_21\tTCGA_SAMP_22\tTCGA_SAMP_23\tTCGA_SAMP_24\tTCGA_SAMP_25\tTCGA_SAMP_26\tTCGA_SAMP_27\tTCGA_SAMP_28\tTCGA_SAMP_29\tTCGA_SAMP_30\tTCGA_SAMP_31\tTCGA_SAMP_32\tTCGA_SAMP_33\tTCGA_SAMP_34\tTCGA_SAMP_35\tTCGA_SAMP_36\tTCGA_SAMP_37\tTCGA_SAMP_38\tTCGA_SAMP_39\tTCGA_SAMP_40\tTCGA_SAMP_41\tTCGA_SAMP_42\tTCGA_SAMP_43\tTCGA_SAMP_44\tTCGA_SAMP_45\tTCGA_SAMP_46\tTCGA_SAMP_47\tTCGA_SAMP_48\tTCGA_SAMP_49\tTCGA_SAMP_50\tTCGA_SAMP_51\tTCGA_SAMP_52\tTCGA_SAMP_53\tTCGA_SAMP_54\tTCGA_SAMP_55\tTCGA_SAMP_56\tTCGA_SAMP_57\tTCGA_SAMP_58\tTCGA_SAMP_59\tTCGA_SAMP_60\tTCGA_SAMP_61\tTCGA_SAMP_62\tTCGA_SAMP_63\tTCGA_SAMP_64\tTCGA_SAMP_65\tTCGA_SAMP_66\tTCGA_SAMP_67\tTCGA_SAMP_68\tTCGA_SAMP_69\tTCGA_SAMP_70\tTCGA_SAMP_71\tTCGA_SAMP_72\tTCGA_SAMP_73\tTCGA_SAMP_74\tTCGA_SAMP_75\tTCGA_SAMP_76\tTCGA_SAMP_77\tTCGA_SAMP_78\tTCGA_SAMP_79\tTCGA_SAMP_80\tTCGA_SAMP_81\tTCGA_SAMP_82\tTCGA_SAMP_83\tTCGA_SAMP_84\tTCGA_SAMP_85\tTCGA_SAMP_86\tTCGA_SAMP_87\tTCGA_SAMP_88\tTCGA_SAMP_89\tTCGA_SAMP_90\tTCGA_SAMP_91\tTCGA_SAMP_92\tTCGA_SAMP_93\tTCGA_SAMP_94\tTCGA_SAMP_95\tTCGA_SAMP_96\tTCGA_SAMP_97\tTCGA_SAMP_98\tTCGA_SAMP_99\tTCGA_SAMP_100\tTCGA_SAMP_101\tTCGA_SAMP_102\tTCGA_SAMP_103\tTCGA_SAMP_104\tTCGA_SAMP_105\tTCGA_SAMP_106\tTCGA_SAMP_107\tTCGA_SAMP_108\tTCGA_SAMP_109\tTCGA_SAMP_110\tTCGA_SAMP_111\tTCGA_SAMP_112\tTCGA_SAMP_113\tTCGA_SAMP_114\tTCGA_SAMP_115\tTCGA_SAMP_116\tTCGA_SAMP_117\tTCGA_SAMP_118\tTCGA_SAMP_119\tTCGA_SAMP_120\tTCGA_SAMP_121\tTCGA_SAMP_122\tTCGA_SAMP_123\tTCGA_SAMP_124\tTCGA_SAMP_125\tTCGA_SAMP_126\tTCGA_SAMP_127\tTCGA_SAMP_128\tTCGA_SAMP_129\tTCGA_SAMP_130\tTCGA_SAMP_131\tTCGA_SAMP_132\tTCGA_SAMP_133\tTCGA_SAMP_134\tTCGA_SAMP_135\tTCGA_SAMP_136\tTCGA_SAMP_137\tTCGA_SAMP_138\tTCGA_SAMP_139\tTCGA_SAMP_140\tTCGA_SAMP_141\tTCGA_SAMP_142\tTCGA_SAMP_143\tTCGA_SAMP_144\tTCGA_SAMP_145\tTCGA_SAMP_146\tTCGA_SAMP_147\tTCGA_SAMP_148\tTCGA_SAMP_149\tTCGA_SAMP_150\tTCGA_SAMP_151\tTCGA_SAMP_152\tTCGA_SAMP_153\tTCGA_SAMP_154\tTCGA_SAMP_155\tTCGA_SAMP_156\tTCGA_SAMP_157\tTCGA_SAMP_158\tTCGA_SAMP_159\tTCGA_SAMP_160\tTCGA_SAMP_161\tTCGA_SAMP_162\tTCGA_SAMP_163\tTCGA_SAMP_164\tTCGA_SAMP_165\tTCGA_SAMP_166\tTCGA_SAMP_167\tTCGA_SAMP_168\tTCGA_SAMP_169\tTCGA_SAMP_170\tTCGA_SAMP_171\tTCGA_SAMP_172\tTCGA_SAMP_173\tTCGA_SAMP_174\tTCGA_SAMP_175\tTCGA_SAMP_176\tTCGA_SAMP_177\tTCGA_SAMP_178\tTCGA_SAMP_179\tTCGA_SAMP_180\tTCGA_SAMP_181\tTCGA_SAMP_182\tTCGA_SAMP_183\tTCGA_SAMP_184\tTCGA_SAMP_185\tTCGA_SAMP_186\tTCGA_SAMP_187\tTCGA_SAMP_188\tTCGA_SAMP_189\tTCGA_SAMP_190\tTCGA_SAMP_191\tTCGA_SAMP_192\tTCGA_SAMP_193\tTCGA_SAMP_194\tTCGA_SAMP_195\tTCGA_SAMP_196\tTCGA_SAMP_197\tTCGA_SAMP_198\tTCGA_SAMP_199\tTCGA_SAMP_200\tTCGA_SAMP_201\tTCGA_SAMP_202\tTCGA_SAMP_203\tTCGA_SAMP_204\tTCGA_SAMP_205\tTCGA_SAMP_206\tTCGA_SAMP_207\tTCGA_SAMP_208\tTCGA_SAMP_209\tTCGA_SAMP_210\tTCGA_SAMP_211\tTCGA_SAMP_212\tTCGA_SAMP_213\tTCGA_SAMP_214\tTCGA_SAMP_215\tTCGA_SAMP_216\tTCGA_SAMP_217\tTCGA_SAMP_218\tTCGA_SAMP_219\tTCGA_SAMP_220\tTCGA_SAMP_221\tTCGA_SAMP_222\tTCGA_SAMP_223\tTCGA_SAMP_224\tTCGA_SAMP_225\tTCGA_SAMP_226\tTCGA_SAMP_227\tTCGA_SAMP_228\tTCGA_SAMP_229\tTCGA_SAMP_230\tTCGA_SAMP_231\tTCGA_SAMP_232\tTCGA_SAMP_233\tTCGA_SAMP_234\tTCGA_SAMP_235\tTCGA_SAMP_236\tTCGA_SAMP_237\tTCGA_SAMP_238\tTCGA_SAMP_239\tTCGA_SAMP_240\tTCGA_SAMP_241\tTCGA_SAMP_242\tTCGA_SAMP_243\tTCGA_SAMP_244\tTCGA_SAMP_245\tTCGA_SAMP_246\tTCGA_SAMP_247\tTCGA_SAMP_248\tTCGA_SAMP_249\tTCGA_SAMP_250\tTCGA_SAMP_251\tTCGA_SAMP_252\tTCGA_SAMP_253\tTCGA_SAMP_254\tTCGA_SAMP_255\tTCGA_SAMP_256\tTCGA_SAMP_257\tTCGA_SAMP_258\tTCGA_SAMP_259\tTCGA_SAMP_260\tTCGA_SAMP_261\tTCGA_SAMP_262\tTCGA_SAMP_263\tTCGA_SAMP_264\tTCGA_SAMP_265\tTCGA_SAMP_266\tTCGA_SAMP_267\tTCGA_SAMP_268\tTCGA_SAMP_269\tTCGA_SAMP_270\tTCGA_SAMP_271\tTCGA_SAMP_272\tTCGA_SAMP_273\tTCGA_SAMP_274\tTCGA_SAMP_275\tTCGA_SAMP_276\tTCGA_SAMP_277\tTCGA_SAMP_278\tTCGA_SAMP_279\tTCGA_SAMP_280\tTCGA_SAMP_281\tTCGA_SAMP_282\tTCGA_SAMP_283\tTCGA_SAMP_284\tTCGA_SAMP_285\tTCGA_SAMP_286\tTCGA_SAMP_287\tTCGA_SAMP_288\tTCGA_SAMP_289\tTCGA_SAMP_290\tTCGA_SAMP_291\tTCGA_SAMP_292'..b'-0.1234\t-0.5552\t-1.0011\t-0.7683\t-0.9426\t0.4153\t-0.9074\t-0.8332\t-0.7285\t-0.7919\t-0.7821\t-0.1604\t-0.9555\t-0.5453\t-0.5558\t-0.4777\t0.9927\t-0.5413\t-0.4734\t-0.4588\t-0.5805\t-1.0253\t-0.7693\t-0.4296\t-0.6796\t0.8262\t-0.7745\t-0.6376\t-0.0074\t0.3159\t-0.9130\t-0.9774\t0.6942\t-0.5006\t-0.8757\t0.5845\t0.7145\t0.8540\t0.9361\t0.8116\t0.2409\t-0.5179\t0.8032\t1.1316\t1.0940\t0.6173\t1.0097\t0.7659\t1.1171\t0.0157\t0.6325\t1.1164\t0.4553\t0.9517\t1.0558\t0.6920\t0.5512\t-0.0023\t0.6649\t0.1056\t0.0373\t0.3099\t-0.4889\t0.2225\t0.1384\t0.1885\t0.2696\t-0.3968\t0.0435\t-0.1625\t0.3381\t-0.5490\t-0.8873\t-0.1601\t-0.0382\t-0.1281\t0.5346\t0.1330\t-0.0225\t-0.0469\t0.3917\t-0.2018\t0.0124\t0.0971\t0.0586\t-0.2148\t-0.0725\t0.2933\t0.2434\t-0.1930\t-0.2130\t-0.0815\t-0.1020\t0.1226\t-0.8454\t0.2793\t0.0076\t-0.0491\t0.4567\t-0.5813\t-0.1195\t-0.0545\t0.4301\t0.6602\t0.0026\t-0.0107\t0.0924\t0.2801\t0.0994\t0.1995\t-0.5433\t-0.1273\t-0.2183\t0.3139\t0.7543\n-Gene_400\t-0.4675\t-0.5625\t-0.9426\t-0.9125\t-0.7059\t-1.0095\t-0.5360\t0.5494\t-0.8530\t-0.6565\t-0.5113\t-0.7029\t-0.9266\t-0.5604\t-0.6257\t-0.5704\t-0.7289\t-0.8479\t0.2874\t-0.5555\t-0.7253\t0.7134\t-0.8393\t-0.7263\t-0.1907\t-0.9337\t-0.9875\t-0.9372\t-0.7513\t-0.5924\t-0.6478\t-1.0565\t-0.4282\t-1.0247\t-0.7741\t-0.7328\t-0.6240\t-0.7278\t-0.1866\t-0.7209\t-0.5869\t-0.9104\t-0.8722\t0.7306\t-0.8916\t-0.7944\t-0.7026\t0.3330\t-0.8422\t-0.8180\t-1.0085\t-0.8501\t-0.7878\t-0.0265\t-0.8514\t-0.5027\t-0.6785\t-0.7414\t-1.0339\t0.9769\t-0.8676\t-0.6131\t-0.5971\t-1.0292\t-0.7050\t-0.9822\t-0.6119\t0.8307\t0.4432\t-0.6735\t-0.7362\t0.9352\t0.3047\t-0.6156\t-0.8046\t-0.8011\t-0.9673\t-0.0873\t-0.5907\t-0.7913\t-0.6618\t-0.7793\t-0.6049\t-0.5591\t-1.0178\t-0.5226\t-0.5416\t-0.5813\t-0.8697\t0.1654\t-1.0279\t0.6686\t-0.9866\t-0.7457\t-0.6320\t-0.5601\t-0.5332\t-0.5421\t-0.2444\t-0.9276\t-0.9135\t-0.8742\t-0.9947\t-0.9066\t-0.5072\t-0.7124\t-0.6779\t-0.7269\t-0.7067\t-1.0756\t-0.7878\t-0.9654\t-0.7497\t0.8585\t-0.8088\t-0.2993\t-0.4758\t-0.6342\t-0.9970\t-0.9072\t-0.8251\t-0.5799\t-0.8863\t-0.6786\t0.1716\t-0.7152\t-0.3949\t-0.7811\t-0.7618\t-0.5131\t-0.9968\t-0.5984\t-0.7348\t-0.6830\t0.6360\t0.4276\t-0.6148\t-0.5662\t-0.4814\t-0.7204\t-1.0230\t-0.6352\t-0.8532\t-0.9810\t-1.0715\t0.5990\t-0.7936\t-0.5936\t-0.7362\t-0.8250\t-0.6988\t-0.9429\t-0.7175\t0.2144\t-0.8203\t-0.7717\t-0.6864\t0.8223\t-0.8283\t0.9115\t-0.7985\t-0.6492\t-0.8979\t-0.9065\t-0.0489\t-1.0277\t-0.3150\t-0.0747\t-0.9950\t-0.3324\t-0.0221\t0.1903\t-0.1714\t0.9333\t-0.4070\t-0.1338\t0.1442\t-0.4161\t-0.2932\t-0.5282\t-0.5717\t-0.4622\t0.8190\t-0.3340\t-0.5111\t-0.0428\t-0.2564\t-0.2569\t-0.1697\t0.4051\t-0.6920\t-0.3264\t-0.0712\t-0.2308\t-0.1695\t-0.0590\t-0.3065\t-0.1910\t-0.1837\t-0.1376\t-0.2802\t0.4537\t-0.5248\t-0.2884\t-0.3138\t-0.3883\t-0.0174\t-0.0968\t0.1407\t-0.2415\t-0.4150\t0.2691\t-0.2863\t-0.0553\t-0.1940\t-0.3862\t-0.5521\t0.3513\t0.5377\t-0.0957\t-0.1367\t-0.0404\t-0.6388\t0.7555\t0.6765\t-0.2095\t0.1232\t0.9740\t0.0258\t-0.2023\t-0.2714\t-0.2547\t-0.0517\t-0.3214\t0.6261\t-0.0485\t-0.0965\t-0.1772\t-0.0664\t-0.2283\t-0.0235\t-0.3385\t-0.5397\t0.9498\t-0.2252\t-0.4920\t0.3937\t-0.9364\t-0.0602\t0.1564\t-0.7009\t0.4962\t0.5710\t-0.2458\t-0.0143\t-0.4776\t-0.2535\t-0.1612\t-0.2521\t-0.4946\t-0.3643\t-0.0460\t0.6374\t-0.5389\t-0.6337\t-0.1551\t-0.1683\t-0.2280\t-0.5649\t0.1563\t-0.3811\t-0.5550\t-0.3368\t-0.3596\t-0.9880\t-0.8343\t-0.3819\t-0.2793\t0.6773\t0.0126\t-0.4956\t-0.5080\t-0.4040\t-0.0193\t-0.3502\t-0.5371\t-0.1358\t-0.2151\t-0.6968\t-0.0244\t-0.4420\t-0.7311\t-0.4241\t-0.3395\t-0.1330\t-0.4521\t-0.2395\t-0.1335\t-0.1596\t-0.4195\t-0.7585\t-0.3474\t0.2321\t-0.2345\t-0.3285\t0.8975\t-0.1729\t-0.5696\t-0.4128\t-0.3681\t-0.1093\t-0.0937\t0.0969\t-0.7263\t-0.9508\t-0.2285\t-0.1364\t-0.2778\t-0.2074\t-0.1128\t-0.0071\t0.3693\t0.2008\t-0.0301\t0.8537\t-0.0354\t-0.3364\t-0.6988\t-0.4083\t-0.4346\t-0.5064\t-0.3832\t-0.1229\t0.4540\t-0.5451\t-0.2981\t0.0137\t-0.9264\t0.3926\t0.7172\t0.1079\t-0.9814\t-0.6913\t-0.2629\t0.5726\t-0.9126\t-0.1970\t0.0353\t0.0183\t0.0080\t0.1573\t-0.1910\t0.1862\t-0.1535\t-0.0711\t0.0457\t-0.0962\t-0.9497\t-0.2888\t0.0767\t-0.2824\t0.0747\t0.1759\t-0.3013\t0.1017\t-0.1491\t-0.3433\t-0.3226\t-0.1821\t-0.0231\t0.1140\t-0.9329\t-0.7741\t0.9107\t-0.8045\t-0.5862\t-0.8495\t0.7974\t-0.9572\t-0.4193\t-0.9811\t0.4838\t-0.5628\t-0.4886\t0.4722\t-0.6954\t-0.4979\t-0.7257\t-0.8920\t-0.3473\t0.9870\t-0.5745\t-0.8121\t-0.5114\t-1.0267\t-0.2803\t-0.5134\t-0.8283\t0.4809\t-0.5844\n'
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/TestFiles/Galaxy400x400-noCovariates.ngchm
b
Binary file naNGCHMheatmap/TestFiles/Galaxy400x400-noCovariates.ngchm has changed
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/heatmap.sh
--- a/naNGCHMheatmap/heatmap.sh Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
[
@@ -1,22 +0,0 @@
-echo $1 $2 $3 $4 $5 $6 $7 $8 $9 ${10} ${11} ${12} ${13} ${14} ${15}
-#create temp directory for row and col order and dendro files.
-tdir=${11}/$(date +%y%m%d%k%M%S)
-echo $tdir
-mkdir $tdir
-#run R to cluster matrix
-output="$(R --slave --vanilla --file=${11}/CHM.R --args $3 $4 $5 $6 $7 $8 $9 $tdir/ROfile.txt $tdir/COfile.txt $tdir/RDfile.txt $tdir/CDfile.txt)"
-rc=$?; if [[ $rc != 0 ]]; then echo $output; exit $rc; fi
-#there are a variable number of triplicate parameters for classification bars
-count=0
-classifcations=''
-for i in "$@"; do
-  if [ $count -gt 10 ]
-  then
-    classifications=$classifications' '$i
-  fi
-  count=$((count+1))
-done
-#call java program to generate NGCHM viewer files.
-java -jar ${11}/GalaxyMapGen.jar "${1}" "${2}" DataLayer1 $3 linear Row Column $4 $5 $6 $tdir/ROfile.txt $tdir/RDfile.txt $7 $8 $9 $tdir/COfile.txt $tdir/CDfile.txt ${10} $classifications
-#clean up tempdir
-rm -rf $tdir
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b naNGCHMheatmap/repository_dependencies.xml
--- a/naNGCHMheatmap/repository_dependencies.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,20 +0,0 @@
-<?xml version="1.0"?>
-<tool_dependency>
-    <package name="NGCHMheatmap" version="4.1.2">
-        <repository name="package_NGCHMheatmap_4_1_2" owner="devuser" prior_installation_required="False" toolshed="http://10.9.10.4:8082" />
-    </package>
-  <actions_group>
-        <action type="make_directory">$Galaxy_Dir/config/plugins/visualizations/MDAheatmap
-        </action>
-        <action type="move_directory_files">
-            <source_directory>./MDAheatmap</source_directory>
-            <destination_directory>$Galaxy_Dir/config/plugins/visualizations/MDAheatmap</destination_directory>
-        </action>
-        <action type="make_directory">$Galaxy_Dir/test-data/MDAheatmap
-        </action>
-        <action type="move_directory_files">
-            <source_directory>./TestFiles</source_directory>
-            <destination_directory>$Galaxy_Dir/test-data/MDAheatmap</destination_directory>
-        </action>
-  </actions_group>
-</tool_dependency>
\ No newline at end of file
b
diff -r 00fc62d280a0 -r 2f45bc8d5b9b repository_dependencies.xml
--- a/repository_dependencies.xml Mon Dec 19 13:43:29 2016 -0500
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,20 +0,0 @@
-<?xml version="1.0"?>
-<tool_dependency>
-    <package name="NGCHMheatmap" version="4.1.2">
-        <repository name="package_NGCHMheatmap_4_1_2" owner="devuser" prior_installation_required="False" toolshed="http://10.9.10.4:8082" />
-    </package>
-  <actions_group>
-        <action type="make_directory">$Galaxy_Dir/config/plugins/visualizations/MDAheatmap
-        </action>
-        <action type="move_directory_files">
-            <source_directory>./MDAheatmap</source_directory>
-            <destination_directory>$Galaxy_Dir/config/plugins/visualizations/MDAheatmap</destination_directory>
-        </action>
-        <action type="make_directory">$Galaxy_Dir/test-data/MDAheatmap
-        </action>
-        <action type="move_directory_files">
-            <source_directory>./TestFiles</source_directory>
-            <destination_directory>$Galaxy_Dir/test-data/MDAheatmap</destination_directory>
-        </action>
-  </actions_group>
-</tool_dependency>
\ No newline at end of file