Skip to content
Prev 30780 / 63421 Next

R in a sandbox/jail

I've not tried an automated system like you describe but I have tried to make 
test scripts available that compare the output of their programs to correct 
output.  That way the students can check their progress as they work.  In 
general, I find this approach doesn't work well for grading because in order to 
specify a homework to the point where the students' output matches your output, 
the homework ends up being 10 pages long (not unlike a legal document).

For example, in a number of instances I'd say "the function should return a 
number..." and then I'd compare the returned result to the actual answer.  But a 
student would 'print' the number instead, not knowing the difference between 
'return+autoprint' and 'print'.  I found it difficult to write a test script 
that gives partial credit for getting the answer right but the concept wrong. 
Perhaps that's a problem with the way I grade things, but I found it difficult 
to write an acceptable test script.

-roger
Barry Rowlingson wrote: