“STR Substitua os pandas” Respostas de código

Os pandas substituem string por outra string

df['prod_type'] = df['prod_type'].replace({'respon':'responsive', 'r':'responsive'})
Smoking Snake

STR Substitua os pandas

>>> pd.Series(['foo', 'fuz', np.nan]).str.replace('f.', 'ba', regex=True)
0    bao
1    baz
2    NaN
dtype: object
Distinct Dove

Respostas semelhantes a “STR Substitua os pandas”

Perguntas semelhantes a “STR Substitua os pandas”

Mais respostas relacionadas para “STR Substitua os pandas” em Python

Procure respostas de código populares por idioma

Procurar outros idiomas de código