ajw*_*ood 6 python dictionary numpy python-3.x pandas
我有一个像这样的熊猫系列:
measure
0 0.3
6 0.6
9 0.2
11 0.3
14 0.0
17 0.1
23 0.9
Run Code Online (Sandbox Code Playgroud)
和像这样的numpy数组:
array([[ 0, 0, 9, 11],
[ 6, 14, 6, 17]])
Run Code Online (Sandbox Code Playgroud)
如何从numpy数组中的值到系列中的索引进行查找以获得:
array([[ 0.3, 0.3, 0.2, 0.3],
[ 0.6, 0.0, 0.6, 0.1]])
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
556 次 |
| 最近记录: |