R Vocabulary – Week 5
# L8 Control structures
# if else statements
if (condition) { expression }
if (conditions) {
expression
} else {
expression
}
# explain why if(x==TRUE) is silly
|
||
&
&&
stopifnot
nchar
substr
# L9 loops
# loops
for (variable in sequence) expression
while (boolean test) expression
repeat expression
break
# functions
sample()
stopfinot()