fixed wavelength order in spectrogram
This commit is contained in:
@@ -22,11 +22,11 @@ function graphSpectralData (obj, dom) {
|
|||||||
var graphPoints = [];
|
var graphPoints = [];
|
||||||
var graphXTicks = [];
|
var graphXTicks = [];
|
||||||
|
|
||||||
Object.keys(obj).forEach((element, index) => {
|
const specter = 'ABCDEFGHRISJTUVWKL';
|
||||||
graphPoints.push([index, obj[element]]); // build array of points
|
for (var i = 0; i < specter.length; i++) {
|
||||||
graphXTicks.push([index, element]); // build array of axis labels
|
graphPoints.push([i, obj[specter[i]]]);
|
||||||
});
|
graphXTicks.push([i, specter[i]]);
|
||||||
// console.log(graphPoints);
|
}
|
||||||
const options = {
|
const options = {
|
||||||
grid: {color: 'white'},
|
grid: {color: 'white'},
|
||||||
xaxis: {ticks: graphXTicks}
|
xaxis: {ticks: graphXTicks}
|
||||||
|
|||||||
Reference in New Issue
Block a user