In an effort to be more transparent in my analyses, advance the methods of our field, and provide an educational resource for implementation of complex methods, I'm releasing the analytic code (and if a simulation, the datasets) to much of my work. Where available, source code in R can be found on my repository on GitHub, and through DOI links besides each publication on my CV. Please respect the licensing agreement when using or sharing this code: attribution is a requirement.
For a brief tutorial on how to release source code using GitHub with a corresponding DOI citation, see this blog post, and for some light background reading, see this article in the journal Epidemiology.
Lastly, although I support the open source movement - I use R and donate to support it - I also firmly believe in the for profit paradigm. There is a cost to producing software and data, and unfettered access can devalue the substantial time, effort, and creativity that researchers have dedicated to their work. Generally in academia, at the point of publication, the specific research product has been delivered and the researcher compensated, therefore it is more amenable to sharing than a project in progress. Nevertheless, there can and should be a remuneration system for those who choose so, even if that payment is a simple acknowledgement as I have requested. I encourage others in the field to do the same.