R packages /
Turn your R code into packages that others can easily download and use. This practical book shows you how to bundle reusable R functions, sample data, and documentation together by applying author Hadley Wickham's package development philosophy. In the process, you'll work with devtools, r...
Clasificación: | Libro Electrónico |
---|---|
Autor principal: | |
Formato: | Electrónico eBook |
Idioma: | Inglés |
Publicado: |
Sebastopol, CA :
O'Reilly Media,
2015.
|
Edición: | First edition. |
Temas: | |
Acceso en línea: | Texto completo (Requiere registro previo con correo institucional) |
Tabla de Contenidos:
- Machine generated contents note: pt. I Getting Started
- 1. Introduction
- Philosophy
- Getting Started
- Conventions
- Colophon
- 2. Package Structure
- Naming Your Package
- Requirements for a Name
- Strategies for Creating a Name
- Creating a Package
- RStudio Projects
- What Is an RStudio Project File?
- What Is a Package?
- Source Packages
- Bundled Packages
- Binary Packages
- Installed Packages
- In-Memory Packages
- What Is a Library?
- pt. II Package Components
- 3.R Code
- R Code Workflow
- Organizing Your Functions
- Code Style
- Object Names
- Spacing
- Curly Braces
- Line Length
- Indentation
- Assignment
- Commenting Guidelines
- Top-Level Code
- Loading Code
- The R Landscape
- When You Do Need Side Effects
- S4 Classes, Generics, and Methods
- CRAN Notes
- 4. Package Metadata
- Dependencies: What Does Your Package Need?
- Versioning
- Other Dependencies
- Title and Description: What Does Your Package Do?
- Author: Who Are You?
- On CRAN
- License: Who Can Use Your Package?
- On CRAN
- Version
- Other Components
- 5. Object Documentation
- The Documentation Workflow
- Alternative Documentation Workflow
- Roxygen Comments
- Documenting Functions
- Documenting Datasets
- Documenting Packages
- Documenting Classes, Generics, and Methods
- S3
- S4
- RC
- Special Characters
- Do Repeat Yourself
- Inheriting Parameters from Other Functions
- Documenting Multiple Functions in the Same File
- Text Formatting Reference Sheet
- Character Formatting
- Links
- Lists
- Mathematics
- Tables
- 6. Vignettes: Long-Form Documentation
- Vignette Workflow
- Metadata
- Markdown
- Sections
- Lists
- Inline Formatting
- Tables
- Code
- Knitr
- Options
- Development Cycle
- Advice for Writing Vignettes
- Organization
- CRAN Notes
- Where to Go Next
- 7. Testing
- Test Workflow
- Test Structure
- Expectations
- Writing Tests
- What to Test
- Skipping a Test
- Building Your Own Testing Tools
- Test Files
- CRAN Notes
- 8. Namespace
- Motivation
- Search Path
- The NAMESPACE
- Workflow
- Exports
- S3
- S4
- RC
- Data
- Imports
- R Functions
- S3
- S4
- Compiled Functions
- 9. External Data
- Exported Data
- Documenting Datasets
- Internal Data
- Raw Data
- Other Data
- CRAN Notes
- 10.Compiled Code
- C++
- Workflow
- Documentation
- Exporting C++ Code
- Importing C++ Code
- Best Practices
- C
- Getting Started with .Call()
- Getting Started with C()
- Workflow
- Exporting C Code
- Importing C Code
- Best Practices
- Debugging Compiled Code
- Makefiles
- Other Languages
- Licensing
- Development Workflow
- CRAN Issues
- 11. Installed Files
- Package Citation
- Other Languages
- 12. Other Components
- Demos
- pt. III Best Practices
- 13. Git and GitHub
- RStudio, Git, and GitHub
- Initial Setup
- Creating a Local Git Repository
- Seeing What's Changed
- Recording Changes
- Best Practices for Commits
- Ignoring Files
- Undoing Mistakes
- Synchronizing with GitHub
- Benefits of Using GitHub
- Working with Others
- Issues
- Branches
- Making a Pull Request
- Submitting a Pull Request to Another Repo
- Reviewing and Accepting Pull Requests
- Learning More
- 14. Automated Checking
- Workflow
- Checks
- Check Metadata
- Package Structure
- Description
- Namespace
- R Code
- Data
- Documentation
- Demos
- Compiled Code
- Tests
- Vignettes
- Checking After Every Commit with Travis
- Basic Config
- Other Uses
- 15. Releasing a Package
- Version Number
- Backward Compatibility
- The Submission Process
- Test Environments
- Check Results
- Reverse Dependencies
- CRAN Policies
- Important Files
- README.md
- README. Rmd
- NEWS.md
- Release
- On Failure
- Binary Builds
- Prepare for Next Version
- Publicizing Your Package
- Congratulations!