R Programming
  • The wikipedia of R by me
  • Hello R
    • -What is R & RStudio
    • -Learning sources
    • -R online editor
    • -R environment
  • Data types
    • -Dealing with Number
    • -Dealing with String
    • -Dealing with Dates
    • -Dealing with NA's
    • -Dealing with Logicals
    • -Dealing with Factors
  • R data
    • -R object
    • -Data structures
      • --Basics
      • --Managing Vectors
      • --Managing Matrices
      • --Managing Data Frames
    • -Functions
    • -Importing/exporting data
    • -Shape&Transform data
    • -R management
  • Visualizations
  • Intro to R Bootcamp
    • -01-introduction
    • -02-data preparation
    • -03-data transformation
    • -04-visualization
  • R programming track
    • -a-Introduction to R
      • --1-Intro to basics
      • --2-Vectors
      • --3-Matrices
      • --4-Factors
      • --5-Data frames
      • --6-Lists
    • -b-Intermediate R
      • --1-Conditionals and Control Flow
      • --2-Loops
      • --3-Functions
      • --4-The apply family
      • --5-Utilities
    • -d-Writing Functions in R
      • --1-A quick refresher
      • --2-When and how you should write a function
      • --3-Functional programming
      • --4-Advanced inputs and outputs
      • --5-Robust functions
  • Data Wrangling with R
  • R-tutor
    • #R introduction
    • #Elementary Statistics with R
  • Hands-On Programming with R
  • R for Data Science
  • Advanced R
  • ggplot2
  • R packages
  • Statistik-1
  • Statistik-2
  • Statistik-3
  • Zeitreihen & Prognosen
  • Descriptive Analytics
  • Predictive Analytics
  • Prescriptive Analytics
  • R Graphics Cookbook
    • ggplot2 intro
    • ggplot2 custome
    • ggplot top-50
  • #Exploratory Data Analysis
    • -Data Summary
    • -Checklist Solution
  • #Data Mining
    • Untitled
    • Untitled
  • #Machine Learning
    • Intro to ML
    • Intro alghorithms
    • 1. Supervised Learning
  • Master R for Data Science
    • Learning R
    • Untitled
    • Untitled
  • Data Science Projects
    • Simple linear regression:
Powered by GitBook
On this page
  • #R vs RStudio
  • #RStudio User Interface
  • #RStudio support
  • #R directories
  • #R packages
  • #R input/output
  • #R extra environment:
  1. Hello R

-R environment

#R vs RStudio

Term:

-Graphical User Interface (GUI): User Interface or a simple term anything that you can see on your computer

-Integrated Development Environment (IDE): A software application to write a computer programm

Introduction to R: R is a language and environment for statistical computing and graphics

The R environment (R-IDE) has some of features, it includes:

  • Input and output , loops function, rekursive

  • Create an analytical graph

  • Operators in different data object such as matrices, data frame, etc

  • Storage facility

  • Data handling

  • Simple GUI

  • Saving graph as pdf

Introduction to R-Studio: R-Studio is open-source IDE for R and has better GUI to connect with R

#RStudio User Interface

RStudio has 4 layer of GUI

#RStudio support

RStudio built in "Help"

?mean()         # help about function mean()
help(mean)      # another help syntax about function mean()
help.start()    # go to manuals help (built in help system)
example(mean)   # show an example of function mean()
apropos("mean") # show all functions containing at least string "mean()"

#R directories

R directories is the current workspace working directory in our computer- or the address of our folder for save the R objects

getwd() #get the current working director
setwd(mydirectory) #setting the directory, use / in windows

Or use the RStudio GUI : Session pane->Set Working Directory->Choose Directory

#R packages

Packages are collections of R code. The directory where packages are stored is called the library

Available Packages:

Setting the library:

library()    # to know all packages 
installed search()     # to see packages currently loaded
.libPaths()  # get library path (location)

Installing additional Packages:

install.packages("nameofpackages") #install
library(nameofpackages) #or    #using the packages in RStudio
require(nameofpackages)        #same with library()

Creating Your Own Packages:

#R input/output

Input from the current working directory:

# input a file 
source("myfile")

Reusing output results:

The R output can easily be saved and used as input

x<-200 #save x which has value 
200y<-x+1000 #x as input for yxy

#R extra environment:

-The bookdown package is a free and open-source R package built on top of R Markdown to make it really easy to write books and long-form articles/reports.:

Previous-R online editorNextData types

Last updated 6 years ago

​​

​​

A complete is available from ​

Search for newest packages, functions, authors, etc from ​

​ from r-project

from F Leisch

from Rossi's

-Build interactive web apps straight from R:

-Build interactive document straight from R:

​

For the comprehensive documentation of bookdown, please see .

- R Markdown thesis template using the bookdown package:

Getting Started with R
Getting Help with Rstudio
list of contributed packages
CRAN
RDocumentation
Writing R Extensions
Creating R Packages: A Tutorial
Making R packages Under Windows: A Tutorial
https://shiny.rstudio.com/​
https://rmarkdown.rstudio.com/index.html​
https://bookdown.org/
https://bookdown.org/yihui/bookdown
https://github.com/ismayc/thesisdown​