简体   繁体   中英

tableau calculated field with condition giving error

I am trying to sum how much records my ML model was TP - table_classification = 1 and labeled=1

sum([model_classification]=1 AND [model_labeled]=1)

getting the below error:

sum is being called with boolean, did you mean float? 

Try this

sum(INT([model_classification]=1 AND [model_labeled]=1)) 

INT will convert boolean to Integer/numeric and thereaftyou can perform arithmetic calculation on that.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM