Examp
# devtools::install_github("timelyportfolio/d3r")
library(d3r)
-library(dplyr)
-
+library(dplyr)
#> Warning: package ‘dplyr’ was built under R version 3.4.4
#>
+#> Attaching package: ‘dplyr’
#> The following object is masked from ‘package:testthat’:
+#>
+#> matches
#> The following objects are masked from ‘package:stats’:
+#>
+#> filter, lag
#> The following objects are masked from ‘package:base’:
+#>
+#> intersect, setdiff, setequal, union
#> Warning: package ‘bindrcpp’ was built under R version 3.4.4
tit_tb
#> {"children":[{"name":"1st","children":[{"name":"Child","children":[{"name":"No","children":[{"name":"Male","Freq":0,"colname":"Sex"},{"name":"Female","Freq":0,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":5,"colname":"Sex"},{"name":"Female","Freq":1,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"},{"name":"Adult","children":[{"name":"No","children":[{"name":"Male","Freq":118,"colname":"Sex"},{"name":"Female","Freq":4,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":57,"colname":"Sex"},{"name":"Female","Freq":140,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"}],"colname":"Class"},{"name":"2nd","children":[{"name":"Child","children":[{"name":"No","children":[{"name":"Male","Freq":0,"colname":"Sex"},{"name":"Female","Freq":0,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":11,"colname":"Sex"},{"name":"Female","Freq":13,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"},{"name":"Adult","children":[{"name":"No","children":[{"name":"Male","Freq":154,"colname":"Sex"},{"name":"Female","Freq":13,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":14,"colname":"Sex"},{"name":"Female","Freq":80,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"}],"colname":"Class"},{"name":"3rd","children":[{"name":"Child","children":[{"name":"No","children":[{"name":"Male","Freq":35,"colname":"Sex"},{"name":"Female","Freq":17,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":13,"colname":"Sex"},{"name":"Female","Freq":14,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"},{"name":"Adult","children":[{"name":"No","children":[{"name":"Male","Freq":387,"colname":"Sex"},{"name":"Female","Freq":89,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":75,"colname":"Sex"},{"name":"Female","Freq":76,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"}],"colname":"Class"},{"name":"Crew","children":[{"name":"Child","children":[{"name":"No","children":[{"name":"Male","Freq":0,"colname":"Sex"},{"name":"Female","Freq":0,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":0,"colname":"Sex"},{"name":"Female","Freq":0,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"},{"name":"Adult","children":[{"name":"No","children":[{"name":"Male","Freq":670,"colname":"Sex"},{"name":"Female","Freq":3,"colname":"Sex"}],"colname":"Survived"},{"name":"Yes","children":[{"name":"Male","Freq":192,"colname":"Sex"},{"name":"Female","Freq":20,"colname":"Sex"}],"colname":"Survived"}],"colname":"Age"}],"colname":"Class"}],"name":"titanic"}
# see as tibble
titanic_df %>%