Examinations in statistics have been criticized for failing to assess analytical thinking and practical problem-solving skills. Project-based assessment is a widely used alternative, but detection of plagiarism is a concern as students should arrive at the same results. Definition of plagiarism is also difficult; sharing ideas on methods is a positive learning experience, while sharing results and computer output is not. Creating a different dataset for each student can resolve these problems but requires automation to be feasible. We describe the experiences gained from programming a general algorithm for this in R and SPSS and piloting in two years of postgraduate healthcare research methods students. There is potential to introduce unfairness if the requirements of analysis, such as post-hoc testing, are not identical in all datasets. Our algorithm creates multiple datasets that are constrained to differ enough to be identifiable, while also sharing exactly the same analytical requirements.