IF AVG([Covid Death Rate Cleaned]) >= 275 THEN "Extremely high COVID death rate"
ELSEIF AVG([Covid Death Rate Cleaned]) >= 226.3 THEN "High COVID death rate"
ELSEIF AVG([Covid Death Rate Cleaned]) <= 200 THEN "Low COVID death rate"
ELSE AVG([Covid Death Rate Cleaned]) <= 175 THEN "Extremely low COVID death rate"
END
This code is giving the an error. Not sure what is wrong. It gives me the error "Expected 'End' to match 'if' at character 0." This is in Tableau by the way, I am trying to make a KPI for data.
Your ELSE should be ELSEIF. Or you should remove the AVG([Covid Death Rate Cleaned]) <= 175 THEN
, which only makes sense with an ELSEIF, not an ELSE.