I have created a service that does some data preprocessing on sensor data. In the end, I have two one dimensional arrays of length n that I want to store and eventually visualize. One array includes the x-Axis values and the other one the related y-Axis values. When I run the service and put the array as a result and set output to JSON it shows me the array values (see screenshots for x and y array example with n=5).
Now, the question is how do I efficiently store this (assume n=1000 and consider that I would have the (x,y) data for several points in time)? Should I use an Infotable? And how to set up the datashape for the infotable considering that I have a 2x1000 matrix of values for a point in time. If I put the array as a result and select INFOTABLE as output with NumberArrayElement datashape it gives me an error Error "executing service. Message ::Unable To Convert From org.json.JSONArray to INFOTABLE - See Script Error Log for more details.". Any tips how I should solve this? Thank you very much.
Depending on how long you need to retain the data, a value stream might be the better choice.
Take a look at this post to see if this would help in your situation.
If this doesn't work, please provide more information on how the data is being received and the retention period needed.