# NOT RUN {
tmp <- value_(CO2,1,2)
attributes(tmp) # data frame
tmp <- value_(CO2,1:2,2)
attributes(tmp) # data frame
tmp <- value_(CO2,1:2,2:4)
attributes(tmp) # data frame
tmp <- value_(CO2,,2)
attributes(tmp) # data frame
tmp <- value_(CO2,2)
attributes(tmp) # same as CO2
tmp <- value_(CO2)
attributes(tmp) # same as CO2
df3 <- data.frame(id = 1:4,
age = c(40,50,60,50),
dose.a1 = c(1,2,1,2),
dose.a2 = c(2,1,2,1),
dose.a14 = c(3,3,3,3))
'modify_<-'(df3,1,2,6)
'modify_<-'(df3,1:3,2:4,data.frame(c(20,10,90),c(9,3,4),c(0,0,0)))
# }
Run the code above in your browser using DataLab