넘파이 배열은 True, False 값을 통해 행을 선택 할 수 있다. 

 

ex)

 arr = np.array(['A', 'B', 'C', 'D',])

 print(arr[[True, True, False, False]])

 

 => ['A' 'B'] 

'0x005 Machine learning > 01. Python' 카테고리의 다른 글

[pandas] info() / describe()  (0) 2021.01.04

+ Recent posts