1
Suppose there is a basis with two variables as follows:
Município IF
RIOBOM Cooperativa
RIOBOM Cooperativa
ABADIA Múltiplo
ABADIA Múltiplo
ABADIA Cooperativa
ABADIA Banco
DOURADOS Banco
DOURADOS Múltiplo
DOURADOS Banco
DOURADOS Cooperativa
DOURADOS Múltiplo
How to create an indicator that marks only those municipalities that have only "cooperative" and "bank" and do not have "multiple". Resulting in the following basis:
Município IF Indicador
RIOBOM Cooperativa 0
RIOBOM Cooperativa 0
ABADIA Múltiplo 0
ABADIA Múltiplo 0
ABADIA Cooperativa 0
ABADIA Banco 0
DOURADOS Banco 0
DOURADOS Cooperativa 1
DOURADOS Banco 0
I asked a similar question but only with a conditional one, and the solution found was with the average of the indicator grouped:
I was a little confused by your question. The municipality of DOURADOS should not have the marker 1 in all lines?
– Flavio Silva
The same one for the county of RIOBOM.
– Rui Barradas