Description
Creating a DataFrame with two columns given duplicate names, changing data via indexer changes both columns:
a = pd.DataFrame(index=['a', 'b', 'c'], columns=['d', 'e', 'd']).fillna(0)
a.iloc[:, 0]['a'] = 3
Gives:
d e d
a 3 0 3
b 0 0 0
c 0 0 0
Instead, it should only edit first column:
d e d
a 3 0 0
b 0 0 0
c 0 0 0
INSTALLED VERSIONS
commit: None
python: 3.4.3.final.0
python-bits: 64
OS: Linux
OS-release: 3.13.0-68-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: de_DE.UTF-8
pandas: 0.17.1
nose: 1.3.6
pip: 1.5.4
setuptools: 3.3
Cython: None
numpy: 1.10.1
scipy: 0.13.3
statsmodels: None
IPython: 3.1.0
sphinx: 1.3.1
patsy: None
dateutil: 2.4.2
pytz: 2015.7
blosc: None
bottleneck: None
tables: 3.1.1
numexpr: 2.2.2
matplotlib: 1.3.1
openpyxl: None
xlrd: 0.9.3
xlwt: 0.8.0
xlsxwriter: 0.7.7
lxml: 3.3.3
bs4: 4.2.1
html5lib: 0.999
httplib2: 0.8
apiclient: None
sqlalchemy: 1.0.4
pymysql: None
psycopg2: 2.6.1 (dt dec pq3 ext lo64)
Jinja2: None