about summary refs log tree commit diff
path: root/src/parser.rs
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi <fredmanglis@gmail.com>2022-08-06 07:45:19 +0300
committerFrederick Muriuki Muriithi <fredmanglis@gmail.com>2022-08-06 07:47:16 +0300
commit809a26505b5ceaf488151ba859f1a986d757b582 (patch)
treee80768b6b1ba630ac5e674366f98c46df11617d8 /src/parser.rs
parent1c2b508720e3918dbf814b584f7adae00b901a10 (diff)
downloadcorrelation_rust-809a26505b5ceaf488151ba859f1a986d757b582.tar.gz
Remove unnecessary parsing
JSON already has a way to denote an array of objects, so there is no
need to manually parse such arrays from strings.
Diffstat (limited to 'src/parser.rs')
-rw-r--r--src/parser.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/parser.rs b/src/parser.rs
index 97ed18a..2e263f8 100644
--- a/src/parser.rs
+++ b/src/parser.rs
@@ -6,7 +6,7 @@ use std::io::Read;
 
 pub struct JsonData {
     pub file_path: String,
-    pub x_vals: String,
+    pub x_vals: Vec<f64>,
     pub sample_values: String,
     pub method: String,
     pub file_delimiter: char,