hadley/adv-r — pull request #629 by earino (2014-12-02 11:07:07+00:00)
Title: Update Data-structures.rmd

"I assign the copyright of this contribution to Hadley Wickham".

I feel this was probably a typo:

x <- list()
print(is.atomic(x) || is.list(x))

prints TRUE, I believe it will print TRUE no matter what kind of list is passed.

x <- list()
print(is.atomic(x) && is.vector(x)) #FALSE
x <- list(a=1, b=c(1,2,3), c=list())
print(is.atomic(x) && is.vector(x)) #FALSE
x <- c(1,2,3)
print(is.atomic(x) && is.vector(x)) #TRUE

I hope I didn't miss something.