V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
bin222
V2EX  ›  Python

Pandas 数据合并求助

  •  
  •   bin222 · 2018-07-27 11:42:01 +08:00 · 1128 次点击
    这是一个创建于 2098 天前的主题,其中的信息可能已经有所发展或是发生改变。

    有这样两个表: 表 A: Y type 0 a 1 a 1 a 1 a 1 a 0 b 0 b 1 b 1 b 1 b 0 c 0 c

    表 B: type r a 0.1 b 0.2 c 0.3


    如何将 A 表中的 Type 替换成 B 表中的 r,注意是替换噢!!! 举个栗子,A 第一行: 0 a,由于 B 表中 a=0.1,所以应该变成: Y type 0 0.1 1 0.1 1 0.1 ...

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   1634 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 30ms · UTC 16:57 · PVG 00:57 · LAX 09:57 · JFK 12:57
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.