Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fct_count(..., prop_OR_relative_OR_normalize_OR_freq= T) #146

Closed
grayskripko opened this issue Sep 7, 2018 · 3 comments
Closed

fct_count(..., prop_OR_relative_OR_normalize_OR_freq= T) #146

grayskripko opened this issue Sep 7, 2018 · 3 comments

Comments

@grayskripko
Copy link

@grayskripko grayskripko commented Sep 7, 2018

I wasn't able to find a good short approach to do

c("a", "a", "b") %>% table() %>% prop.table()

using forcats package. I think it's pretty handy to use a special argument for this purpose as in sklearn value_counts

@hadley
Copy link
Member

@hadley hadley commented Jan 4, 2019

Maybe c("a" ,"a", "b") %>% fct_count(prop = TRUE)?

@grayskripko
Copy link
Author

@grayskripko grayskripko commented Jan 7, 2019

should be OK and more R-thonic :) than normalize

@khailper
Copy link

@khailper khailper commented Jan 19, 2019

On it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants