diff --git a/src/helpers/flatten.ts b/src/helpers/flatten.ts index deb3af9..ed54da9 100644 --- a/src/helpers/flatten.ts +++ b/src/helpers/flatten.ts @@ -7,8 +7,8 @@ export default function flatten (data, keepArray = false) { // flatten object: result[prop] = cur; } else if (prop === `${globals.spectrum.spectrum}.${globals.spectrum.dpt}`) { - result[prop + '.labels'] = cur.map(e => e[0]); - result[prop + '.values'] = cur.map(e => e[1]); + result[prop + '.labels'] = cur.map(e => parseFloat(e[0])); + result[prop + '.values'] = cur.map(e => parseFloat(e[1])); } else if (Array.isArray(cur)) { if (keepArray) {