Predicting number of people
Hi,
I am currently developing a project for a client where I need to apply Thingworx Analytics.
I need to predict the number of people in a room every hour for the next 7 days.
To create the model I am gathering the following data:
- a UTC timestamp, which I exclude from the model but include in the dataset for a later timeseries representation on the mashup.
- Hour (1-24) dataType: Integer, opType: Categorical
- Weekday (1-7) dataType: Integer, opType: Categorical
- Month (1-12) dataType: Integer, opType: Categorical
- Holiday (boolean) dataType: Boolean, opType: Boolean
- Number of people, dataType: Integer, opType: Continuous
I exclude the timestamp because it has no relevance to the model.
The room has a sensor which sends the # of people every hour.
To make the process automatic I created a thing which receives the data onto an infotable. Now I will make a service which uses CreateJob() from "analytics_TrainingThing". There is no parameter to exclude fields from data on the service as there are on the Analytics Builder mashup. I have noticed that the thing "TW_ML_Toolkit_Helper" has a service "CreateModelAMS" which has the desired fields.
My question are:
- Is the data schema correct?
- Should I create a value stream instead of an infotable?
- Should I be using the "TW_ML_Toolkit" template on the thing I am invoking the services from? If not, how do I exclude data fields from training the model without Analytics Builder?
- On CreateJob() from "analytics_TrainingThing", how do I refer the dataset? Should I create it from the infotable first and call my DataThing to create the dataset?
- Once I have the model can I simply use RealtimeScore() from "analytics_PredictionThing" to predict the number of people, given the rest of the fields (hour, day, month, holiday)?
Thank you!

