R: some work on runTask