python 为何数组切片时最后加上0就能将array合并?

如图,a是28个数组,为何a[:,0]就能将所有数组合并?
clipboard.png

阅读 3.2k
2 个回答

read the doc. again. '0' in [:,0] should be accessing the element in each array, we can get a new array by this approach. it's not slicing.

参考这里
发现自己也不懂,抱着学习的态度把上面的翻译了一遍(翻译得太挫勿喷,能看英文尽量看英文吧)

贴在CSDN上了,链接在这

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题