Can someone please help me with the following below, I am not sure what I am doing wrong, I have tested this in the arcade playground, but cant get it to work with my data.
I am trying pull data from a table and determine the percentage contacted
VAR Owners = FEATURESETBYNAME($DATASTORE,"Owners",["TractID","Contacted"])
VAR ID = $feature.TractID
VAR OwnerID = Filter(owners,"TractID=@ID")
VAR Cont = 0
VAR NCont =0
FOR(VAR F in OwnerID){
If(OwnerID[F] == 'Yes'){
Cont +=1}
}
FOR(VAR F in OwnerID){
If(OwnerID[F] == 'No'){
NCont +=1}
}
Return CONT/(Cont+NCont)