Commit 0f74975f authored by Daria Zenkova's avatar Daria Zenkova

labels work only with geom_text, but not with geom_text_repel, that's upsetting me :(

parent eae9abb9
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -181,9 +181,6 @@ morpheus.Dataset.prototype = {
}
},
getESSession : function () {
if (this.esSession == null) {
this.setESSession();
}
return this.esSession;
}
......
......@@ -879,7 +879,7 @@ morpheus.DatasetUtil.toProtoMessage = function (dataset) {
attrName : "dim",
attrValue : {
rclass : "INTEGER",
intValue : [dataset.rows, dataset.columns]
intValue : [dataset.getColumnCount(), dataset.getRowCount()]
}
}, {
rclass : "STRING",
......
......@@ -115,7 +115,7 @@ morpheus.PcaPlotTool = function (chartOptions) {
formBuilder.append({
name: 'color',
type: 'bootstrap-select',
options: numericOptions
options: options
});
formBuilder.append({
name: 'x-axis',
......@@ -127,6 +127,11 @@ morpheus.PcaPlotTool = function (chartOptions) {
type: 'bootstrap-select',
options: pcaOptions
});
formBuilder.append({
name: 'label',
type: 'bootstrap-select',
options: columnOptions
});
formBuilder.append({
name: 'draw',
......@@ -139,7 +144,7 @@ morpheus.PcaPlotTool = function (chartOptions) {
function setVisibility() {
formBuilder.setOptions('color', options, true);
formBuilder.setOptions('size', numericOptions, true);
formBuilder.setEnabled('draw', true);
formBuilder.setOptions('label', columnOptions, true);
}
this.tooltip = [];
......@@ -293,12 +298,17 @@ morpheus.PcaPlotTool.prototype = {
var project = this.project;
if (_this.project.getFullDataset().getESSession()) {
_this.formBuilder.setEnabled('draw', true);
}
this.formBuilder.$form.find('[name="draw"]').on('click', function () {
_this.$chart.empty();
var colorBy = _this.formBuilder.getValue('color');
var sizeBy = _this.formBuilder.getValue('size');
var pc1 = _this.formBuilder.getValue('x-axis');
var pc2 = _this.formBuilder.getValue('y-axis');
var label = _this.formBuilder.getValue('label');
console.log('draw plot button clicked');
var dataset = _this.project.getSelectedDataset({
......@@ -314,7 +324,7 @@ morpheus.PcaPlotTool.prototype = {
console.log(columnIndices);
console.log(rowIndices);
console.log(colorBy, sizeBy, pc1, pc2);
console.log(colorBy, sizeBy, pc1, pc2, label);
arguments = {
es : expressionSet,
c1 : pc1,
......@@ -332,6 +342,11 @@ morpheus.PcaPlotTool.prototype = {
if (sizeBy != "") {
arguments.size = sizeBy;
}
if (label != "") {
arguments.label = label;
}
console.log(arguments);
var req = ocpu.call("pcaPlot", arguments, function (session) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment