dcomtois / summarytools

R Package to Quickly and Neatly Summarize Data
522 stars 78 forks source link

Suggestion: Distinct count of factor/character column #54

Open leok31 opened 5 years ago

leok31 commented 5 years ago

It would be useful to have a distinct count of unique values of either factor or character column. For example, if I have a column labeled email, I would like to know how many unique emails I have in that column. Here is an example of my output. When the field type is Integer, then you get a distinct could of values, but when it's a character/factor then it counts frequency but not count of unique values.

1

Thank you

dcomtois commented 5 years ago

Sorry for late response... This information is indirectly given... For instance the email variable has 19974 + 3 = 19977 distinct values. Adding it would create redundancy in many cases and the summaries are already packed with information, I wouldn't want them to become overcrowded. I'll leave open for a while and see if other users would also like to have that feature.