Update datacost.m

Rudimentary Octave compatibility.