https://github.com/yihui/rlp
  
  
    An Example of Using Literate Programming for R Package Development 
    https://github.com/yihui/rlp
  
gnu-make literate-programming makefile r r-package
        Last synced: 7 months ago 
        JSON representation
    
An Example of Using Literate Programming for R Package Development
- Host: GitHub
 - URL: https://github.com/yihui/rlp
 - Owner: yihui
 - License: other
 - Created: 2014-12-29T21:47:25.000Z (almost 11 years ago)
 - Default Branch: master
 - Last Pushed: 2023-02-23T23:27:20.000Z (over 2 years ago)
 - Last Synced: 2025-03-19T06:38:57.798Z (8 months ago)
 - Topics: gnu-make, literate-programming, makefile, r, r-package
 - Language: R
 - Homepage: https://yihui.org/rlp/
 - Size: 70.3 KB
 - Stars: 52
 - Watchers: 7
 - Forks: 8
 - Open Issues: 0
 - 
            Metadata Files:
            
- Readme: README.md
 - License: LICENSE
 
 
Awesome Lists containing this project
- jimsghstars - yihui/rlp - An Example of Using Literate Programming for R Package Development (R)
 
README
          # rlp
This is an example package of using Literate Programming for developing R
packages. Most R package authors probably write R code in the R scripts under
the `R/` directory, and use comments to explain code. This package shows that
you do not have to develop a package in this way. You may write R code in R
Markdown documents, and extract the code to the `R/` directory automatically via
`knitr::purl()`. At the same time, you will get a nicely formatted output
document displaying the source code chunks as well as the text/prose chunks, and
this output document can be a package vignette. Please see the package homepage
for more details: . This package is licensed under MIT,
and you are welcome to file issues or submit pull requests.
## Acknowledgements
This approach is not possible (at least not easy) without a few important
components in the toolchain:
- The support for non-Sweave vignettes since R 3.0.0, which has opened far more
  possibilities than I originally imagined;
- The RStudio IDE, which allows us to build an R package by clicking a button;
- The **rmarkdown** package, which generates beautiful HTML/PDF output;
- GNU make, which makes it easy to define how and when to compile a file;
Let me also thank whomever invented holidays, which is often my most productive
time. Oh I cannot live without holidays.