Intro to R statistic programming


Published on

This is an introduction by Ram of Dawn Analytics. This was presented in a Meetup group at
File can be found at
Free Intro to R statistic programming with complete download of Microsoft Powerpoint and accompanying R script files #rstats #free
Files can be downloaded at

1 Comment
  • Nice intro. For those who are looking for free video introduction course on R, check out:
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Intro to R statistic programming

  1. 1. An Introduction to R for Traders Ram Venkat Dawn Analytics
  2. 2. R environment• R is an open source environment for statistical computing• An Integrated environment for data manipulation, calculation and graphical output• R is also a dynamic and object-oriented programming language• Standard install consists of around 30 core packages that cover most common statistical and other tasks• CRAN contains over 4000 contributed packages and it is growing
  3. 3. R , RStudio installation• Both R and RStudio are available in Windows, Mac, unix and Linux• R installation instruction : http://cran.r-• Rstudio is a free open source IDE for R, we will be using Rstudio for this tutorial• RStudio can be downloaded from
  4. 4. R packages and sample datasets• Installing an R package: e.g >install.packages(“quantmod “)• “quantmod” is package for trading and we will be using this for this tutorial• Using quantmod to load some basic data• Using in-built data sets of R
  5. 5. R as an object-orientedlanguage• Everything is an Object in R• A brief look at an R program• Calling R programs in batch mode• R functions and packages in-under-6-minutes/• Calling R from other languages• R Programming Model• Parallel R
  6. 6. R Objects and classes• Core Objects – Vector – List – Functions• Other Objects Matrix – Array – Data Frames – Factors
  7. 7. Data inputs and Data Cleaning• Through package interfaces• From CSV• From Databases• Excel interface• Data Cleaning facilities
  8. 8. R Graphics• graphics, lattice and grid packages• graphics Package charts: – barplot,dot chart,histogram,density plots,strp charts, quantile plots, scatter plots, image plots, contour plots, interaction plots, sunflower plots• Lattice splits a chart into different panels or groups , making multiple plots on same page easy
  9. 9. Statistical computing• Data Analysis : Summary, Correlation, principal Component Analysis, Factor Analysis• Time Series• Probablity Distributions• Statistical tests• Regression Models• Classification Models• Clustering
  10. 10. quantmod package• “A rapid prototyping environment, where quant traders can quickly and cleanly explore and build trading models. “• Quantmod example on data handling• Quantmod example on charting• Quantmod example on modelling• For more :
  11. 11. Other packages of interest toTraders• R-sig-finance is your best bet to keep track of the packages:• Other packages mentioned frequently : Rmetrics(fportfolio),portfolio, Rglpk_solve_LP (portfolio optimization)• Broker-specific: Ibrokers (IB)
  12. 12. R Books and Tutorials• Book - “R in a Nutshell” by Joseph Adler (OReilly)• cran-R “An introduction to R”• Quck-R site : gives a discount on the book “R in Action” from Manning• R and time-series:
  13. 13. Thank YouFor any clarification, send e-mail