I have a transaction data set of 10 customers from 01-01-2013 to 01-11-2016. I split data set for each customer manually as below but I couldn't find how to create a loop to do it. What is the best loop for this?
customer_1 <- transactions[1:47,]
customer_2 <- transactions[48:94,]
customer_3 <- transactions[95:141,]
customer_4 <- transactions[142:188,]
customer_5 <- transactions[189:235,]
customer_6 <- transactions[236:282,]
customer_7 <- transactions[283:329,]
customer_8 <- transactions[330:376,]
customer_9 <- transactions[377:423,]
customer_10 <- transactions[424:468,]