R scripts for an artificial dataset