Hebb wrote, not all issues are psychological, but most are. I agree with Gram's answer. Simon's answer is true not only for code but for mathematical proofs too. However there is one other major issue and it is psychological I suggest.
Many researchers tenured or not falsely think: open, therefore free, therefore worthless. Too many imagine they lose face in front of colleagues who publish in journals that are not open... (For the apparently valid reason that because if somebody pays to read an article it means they value it more and it has more value...)
This argument isn't applicable here. Most paywalled journals are read because a university subscribes to them. The target readers don't usually pay for them. Furthermore in science value is not judged by willingness to pay anyway.
Indeed, tenured colleagues really have no reason to prefer publications with more prestige. Some would even reply they don't know what that even means. For at that point, articles are looked up and read, as they become aware of their possible utility, not journals.
So the reason is often irrational one can suggest. PNAS for instance becomes free after a year but that does not mean its somehow less important or valuable.
(For illustration, my university library subscribes to virtually all journals in any field. But that means they spent the money, not any scientific peers of the authors publishing there. The administrators who allocated the funds don't read the journal, although they did a great favor for us researchers. At another university, this one in Europe, there were very few journals accessible so people cited mostly books or cited a paper citing another paper if they couldn't find the other online for ...)
This also answers this question: Why do tenured professors still publish in pay-walled venues?
This post has been migrated from the Open Science private beta at StackExchange (A51.SE)