Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

count true in a dataframe

df.has_cancer.value_counts()
Out[345]: 
False    6
True     1
Name: has_cancer, dtype: int64
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #count #true #dataframe
ADD COMMENT
Topic
Name
9+9 =