Browse Source

Finished writing r-programming blog post.

pull/77/head
Jeffery Russell 5 years ago
parent
commit
2aabcf1185
1 changed files with 11 additions and 3 deletions
  1. +11
    -3
      blogContent/posts/data-science/r-programming-language.md

+ 11
- 3
blogContent/posts/data-science/r-programming-language.md View File

@ -15,21 +15,29 @@ These things may feel weird at first, but, R's type system is one of the things
![R Arrays Start at 1](media/r/arrays.jpg) ![R Arrays Start at 1](media/r/arrays.jpg)
Did I mention that arrays start at 1? Did I mention that arrays start at 1?
Technically, the thing which we refer to as an array in C or Java is really a vector in R.
Technically, the thing which we refer to as an array in Java are really vectors in R.
Arrays in R are data objects which can store data in more than two dimensions. Arrays in R are data objects which can store data in more than two dimensions.
Since R tries to follow mathematical notation, indexing starts at 1 -- just like in linear algebra. Since R tries to follow mathematical notation, indexing starts at 1 -- just like in linear algebra.
Using zero based indexing makes sense for languages like C because the index is used to get at a particular memory location from a pointer. Using zero based indexing makes sense for languages like C because the index is used to get at a particular memory location from a pointer.
<youtube src="s3FozVfd7q4" /> <youtube src="s3FozVfd7q4" />
I don't have the time to go over the basic syntax of R in a single blog post, however, I feel that this youtube video does a pretty good job.
I don't have the time to go over the basic syntax of R in a single blog post; however, I feel that this youtube video does a pretty good job.
# R Markdown # R Markdown
One of my favorite aspects of R is its markdown language called Rmd.
Rmd is essentially markdown which has can have embedded R scripts run in it.
The Rmd file is compiled down to a markdown file which is converted to either a PDF, HTML file, or a slide show using pandoc.
You can provide options for the pandoc render using a YAMAL header in the Rmd file.
This is an amazing tool for creating reports and writing research papers.
The documents which you create are reproducible since you can share the source code to it.
If the data which you are using changes, you simply have to recompile to document to get an updated view.
You no longer have to re-generate a dozen graphs and update figures and statistics across your document.
# Resources # Resources
- [R for Data Science(Online Book)](https://r4ds.had.co.nz/)
- [R for Data Science (Online Book)](https://r4ds.had.co.nz/)
- [R Studio](https://www.rstudio.com/) - [R Studio](https://www.rstudio.com/)
- [R Official Website](https://www.r-project.org/) - [R Official Website](https://www.r-project.org/)

Loading…
Cancel
Save