Vectoren bewerken

Introductie tot R voor Financiën

Lore Dirick

Manager of Data Science Curriculum at Flatiron School

Vectoren en meer

dan <- 100
rob <- 50
total <- dan + rob
dan <- c(100, 200, 150)
rob <- c(50, 75, 100)

monthly_total <- dan + rob
monthly_total
150 275 250
sum(monthly_total)
675
Introductie tot R voor Financiën

Meer voorbeelden

a <- c(2.2, 12, 7)
b <- c(11.5, 8, 3.4)

# Aftrekken!
c <- a - b
c
-9.3 4.0  3.6
# Vermenigvuldigen!
d <- a * b
d
25.3 96.0 23.8
# Recycling!
e <- 2
f <- a * e
f
4.4 24.0 14.0
Introductie tot R voor Financiën

Laten we oefenen!

Introductie tot R voor Financiën

Preparing Video For Download...