1 of 1 people found this helpful
Do you have some sort of date field or distinct order identifier (order id) that would allow you to sequence the visits? What's the question you're trying to answer? Whether the purchase of large volume leads to repeat visits? Whether promotions or the purchase of promotional items leads to repeat visits?
If there was a unique order identifier and a date column you count the order IDs within a specific time frame by customer. Without a unique order identifier however, it's difficult to sequence the purchases.
Yes, I have the date of purchase to sequence the visits. Any ideas?
I attached a workbook that accomplished turning the first data set into the second using a running count calculated field.
- I created a calculated field that concatenated the customer ID with the order ID (the orderID could be a date value if you don't have an order ID. However if there is more than one order for a date then there might be a problem because we need unique values. Assuming it's unique, it could work)
- Then I created a running_count calculated field that is computed using the distinct field calculated in 1 above.
- To change the column headers I did a custom number format (right click running count pill and change the number format) "Visit" # which turns 1, 2, 3, 4 into Visit 1 , Visit 2, Visit 3, Visit 4
Hopefully this is something close to what you're after.
repeatVisits.twbx 19.0 KB
Thanks Cory. This works !