I am getting warnings for str.replace and str.split for the below codes
df['Amount'] = df['Amount'].str.replace(')', '')
df[['Inside','Outside']] = df.Amount.str.split(",",expand=True)
Below is the Warning
dynamic_module:222: SettingWithCopyWarning:
A value is trying to be set on a copy of a slice from a DataFrame.
Try using .loc[row_indexer,col_indexer] = value instead
See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/indexing.html#indexing-view-versus-copy
C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\frame.py:3391: SettingWithCopyWarning:
A value is trying to be set on a copy of a slice from a DataFrame.
Try using .loc[row_indexer,col_indexer] = value instead
See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/indexing.html#indexing-view-versus-copy
self[k1] = value[k2]
df['Amount'].loc usage doesn't help, may be not used properly, what could be the correct way?