a = {1:"a", 2:"b", 3:"c"}
b = {2:"e", 3:"f"}
a.update(b)
print(a)
> {1: 'a', 2: 'e', 3: 'f'}
【 在 formydream 的大作中提到: 】
: 比如series1为 values= [1,2,3,4,5],index=[a,b,c,d,e]
: series2为 values=[88,99,100],index=[c,d,e]
: 我的需求是要用series2的c,d,e的值去替代series1的c,d,e的对应值,其他的值保持不变。
: ...................
--
FROM 213.95.148.*