added setSeed0 option to work.R