This is an old revision of the document!


Knitr

Knitr is a package that can be used to generate dynamic reports or web pages from R code. The code is evaluated at the moment the report is generated.

Code can be easily written in RStudio use the Markdown language. View this page in Markdown language, and view the resulting web page.

Data Table

Data table is a very useful package in R which allows to facilitate and to improve the efficiency of certain operations in R. Data tables are just like data frames. You can even create them from data frames.

Introduction to Data table (PDF)

install.packages('data.table')
library(data.table)

Generate very long data frame with one column with letters, and one column with random numbers

mydf=data.frame(a=rep(LETTERS,each=1e5),b=rnorm(26*1e5))

Convert the data frame to a data table format.

mydt=data.table(mydf)

%0