In Numpy ein Perzentil in 2D mit etwas Zustand findenPython

Python-Programme
Anonymous
 In Numpy ein Perzentil in 2D mit etwas Zustand finden

Post by Anonymous »

Ich habe diese Art von Array < /p>

Code: Select all

a = np.array([[-999, 9, 7, 3],
[2, 1, -999, 1],
[1, 5, 4, 6],
[0, 6, -999, 9],
[1, -999, -999, 6],
[8, 4, 4, 8]])
Ich möchte in diesem Array 40% Perzentil jeder Zeile erhalten, in der es nicht gleich ist. /> Die Ausgabe, die ich möchte, wird so sein < /p>

Code: Select all

[
6.2, # 3 or 7 also ok
1,
4.2, # 4 or 5 also ok
4.8, # 0 or 6 also ok
1,
4
]
Danke

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post