Skip to content

Commit

Permalink
a few test cases in examples for #13
Browse files Browse the repository at this point in the history
  • Loading branch information
yihui committed Feb 11, 2015
1 parent e6ee2fa commit 7dd8547
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions inst/examples/datatable.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,10 @@ datatable(as.data.frame(m))
m = data.frame(a = 1, b = 2, c = 3)
datatable(m)
datatable(as.matrix(m))

# dates
datatable(data.frame(
date = seq(as.Date("2015-01-01"), by = "day", length.out = 5), x = 1:5
))
datatable(data.frame(x = Sys.Date()))
datatable(data.frame(x = Sys.time()))
7 changes: 7 additions & 0 deletions man/datatable.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,11 @@ datatable(as.data.frame(m))
m = data.frame(a = 1, b = 2, c = 3)
datatable(m)
datatable(as.matrix(m))

# dates
datatable(data.frame(
date = seq(as.Date("2015-01-01"), by = "day", length.out = 5), x = 1:5
))
datatable(data.frame(x = Sys.Date()))
datatable(data.frame(x = Sys.time()))
}

0 comments on commit 7dd8547

Please sign in to comment.