Created
June 8, 2016 15:25
-
-
Save aammd/5772c7144a68b0075611a98871db76df to your computer and use it in GitHub Desktop.
experimenting with purr on gapminder
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(purrr) | |
library(gapminder) | |
gapminder %>% | |
transpose %>% | |
map(~ splice(., totalgdp = .$pop * .$gdpPercap)) %>% | |
transpose %>% | |
simplify_all() %>% | |
as.data.frame() %>% | |
head |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment