My guesses would be,
(1) You think you're running the same version of the code, but you're not.
(2) You think you're running it on the same data, but you're not.
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!