Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X
Hi,
I'm experimenting with some data for analytics. My data (data.json, data.csv) are always no-timeseries. What I have todo (in json and csv file) have timeseries data?
Or have someone example data which is timeseries?
Solved! Go to Solution.
Hi
I am assuming you are using ThingWorx Analytics 8.1 or over.
For a dataset to be seen as a time series one you need to have in the csv
- one column that represents the asset id (for example pump1, pump2 ...)
- one column representing the time interval.
in the json file you need to set
- opType: ENTITY_ID for the field that define the column representing the asset id in csv
- opType: TEMPORAL for the field representing the column for the time interval in csv.
you also indicate the attribute timeSamplingInterval for this TEMPORAL field which indicate the time in milliseconds at which the data should come in
The Transition Guide has got some information about this around page 28 -29
For example
Device -- timing --- sensor1 --- sensor 2
Pump1 -- 1 --- 12 --- 84
Pump2 --- 1 ---- 7 ---- 56
Pump1 -- 2 ---- 18 ---- 110
Pump2--- 2 ---- 25 --- 64
Pump1 --- 3 ----- 5 ---- 58
Pump2 ---3 ------ 30 ---- 80
in the json you would have
{
"fieldName": "Device",
"dataType": "STRING",
"opType": "ENTITY_ID",
},
{
"fieldName": "timing",
"dataType": "DOUBLE",
"opType": "TEMPORAL",
"timeSamplingInterval": 1,
},
Hope this helps
Kind regards
Christophe
Can you describe a little better
1. How you are gathering the data
2. When you say Analysis, how do you intend to use it
3. Why does that Analysis require timeseries
The gathering process is for my example irrelevant. I only need the look of the *.json and the *.csv, so I can create data by hand or via excel or something else.
At the moment a create prediction models with non-timeseries data but for a real project I will predict something like "xx days to failure" so I will test the prediction stuff with timeseries data.
Hi
I am assuming you are using ThingWorx Analytics 8.1 or over.
For a dataset to be seen as a time series one you need to have in the csv
- one column that represents the asset id (for example pump1, pump2 ...)
- one column representing the time interval.
in the json file you need to set
- opType: ENTITY_ID for the field that define the column representing the asset id in csv
- opType: TEMPORAL for the field representing the column for the time interval in csv.
you also indicate the attribute timeSamplingInterval for this TEMPORAL field which indicate the time in milliseconds at which the data should come in
The Transition Guide has got some information about this around page 28 -29
For example
Device -- timing --- sensor1 --- sensor 2
Pump1 -- 1 --- 12 --- 84
Pump2 --- 1 ---- 7 ---- 56
Pump1 -- 2 ---- 18 ---- 110
Pump2--- 2 ---- 25 --- 64
Pump1 --- 3 ----- 5 ---- 58
Pump2 ---3 ------ 30 ---- 80
in the json you would have
{
"fieldName": "Device",
"dataType": "STRING",
"opType": "ENTITY_ID",
},
{
"fieldName": "timing",
"dataType": "DOUBLE",
"opType": "TEMPORAL",
"timeSamplingInterval": 1,
},
Hope this helps
Kind regards
Christophe
Hi
I have just made some update to the article https://www.ptc.com/en/support/article?n=CS258345 and added a sample dataset for time series that works with release 8.2
Hope that helps
Kind regards
Christophe
I am using the Version 8.2, the analysis of time series based models always fails with
The dataset must contain entity ID and temporal fields in order to perform TimeSeries training. Please set the timeSeries post body field to null to perform standard training or supply a TimeSeries appropriate dataset.
Even, if I import your pump example. ENTIT_ID and TEMPORAL are always provided, but analysis fails with the error above.
Hi skef
This post was about the syntax in for a time series model. What you are mentionning is a different issue.
From what I can grasp is an error while usign ThignPredictor.
You could use the scoring in Analytics Builder directly and you would not have this error.
For ThingPredictor look at this post: https://community.ptc.com/t5/ThingWorx-Developers/Analytics-Prediction-with-time-series-data/m-p/538717/highlight/false#M26541 .
Kind rgeards
Christophe