Plotly graph configuration
This commit is contained in:
parent
ff402b8fcb
commit
0494d553d0
@ -17,6 +17,7 @@ class Graph {
|
|||||||
const values = [{
|
const values = [{
|
||||||
x: this.dataset.xValues(),
|
x: this.dataset.xValues(),
|
||||||
y: this.dataset.yValues(),
|
y: this.dataset.yValues(),
|
||||||
|
mode: 'scatter',
|
||||||
}]
|
}]
|
||||||
|
|
||||||
this.layout = {
|
this.layout = {
|
||||||
@ -26,7 +27,11 @@ class Graph {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
Plotly.react(this.graphValues, values, this.layout);
|
this.config = {
|
||||||
|
displayModeBar: true,
|
||||||
|
}
|
||||||
|
|
||||||
|
Plotly.react(this.graphValues, values, this.layout, this.config);
|
||||||
this.graphValues.on('plotly_relayout', attr => this.relayoutHandler(attr))
|
this.graphValues.on('plotly_relayout', attr => this.relayoutHandler(attr))
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -39,6 +44,7 @@ class Graph {
|
|||||||
const values = [{
|
const values = [{
|
||||||
x: this.dataset.xValues(),
|
x: this.dataset.xValues(),
|
||||||
y: this.dataset.yValues(),
|
y: this.dataset.yValues(),
|
||||||
|
mode: 'scatter',
|
||||||
}]
|
}]
|
||||||
Plotly.react(this.graphValues, values, this.layout)
|
Plotly.react(this.graphValues, values, this.layout)
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user