I want to predict future user activities (e.g., account cancellation) but I don't know how I'm supposed to represent the data.
The raw data is a sequence of all activities by all users:
2015-01-01T04:04|user1|created account
2015-01-01T05:04|user2|created account
2015-01-01T06:04|user1|changed plan
2015-01-01T07:04|user2|changed plan
2015-01-01T08:04|user1|cancelled submission
In the simplest prediction I'd like to label a user as 0=Cancelled and 1=Not Cancelled and subsequently would train a classifier for this label.
The question is how would I prepare the data for a machine learning algorithm (e.g. SVM or logistic regression)?. I now have multiple rows per user which are ordered by the time they happened, but I'm thinking of having only one row per user. How would I represent the activities? Furthermore, the number of activities per user is not limited (1 to n
where n
would hardly ever exceed 10
), and the the number of features per activity can be large (up to 100 features).
I'd really appreciate it if anyone could help me out here :-)
Thx