i have:
df['tabela_qar.pergunta'].value_counts()
df['tabela_qar.resposta'].value_counts()
I need to change the values in tabela_qar.resposta from some conditions.
Example:
If tabela_qar.pergunta= x & tabela_qar.resposta = y: tabela_qar.resposta changes value to z
Tried:
df.loc[(df['tabela_qar.resposta']=='NÃO') & (df['tabela_qar.pergunta']=='POSSUI GARAGEM NO LOCAL DE TRABALHO')] = df['tabela_qar.resposta'].str.replace('NÃO','GARAGEM TRABALHO')
I tried in several ways, but I can't do it. Someone help me?