A article published in Guardian argues for software openness in science.

.…if you are publishing research articles that use computer programs, if you want to claim that you are engaging in science, the programs are in your possession and you will not release them then I would not regard you as a scientist; I would also regard any papers based on the software as null and void.

For an emprical survey on why scientists do and do not share their software, see The Scientific Method in Practice: Reproducibility in the Computational Sciences by Victoria Stodden.