Bottom Page

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 counting the occurence of a specified number in a numpy-matrix
There is a numpy-matrix with a couple column and about 100000 row. For now, only the last element of each row is important.
I wish to count, that how many row has the number 1 as the last element. Then how many row has the number 2 as the last element, and so on (until the number 1000). It would be also good, if i could count, how many row has greater then 1000 as the last element.

Is there any solution for this problem (without to write a code with tausends of lines)?

Or is there any way, to copy past the values of a matrix from Spyder IDE to Libreoffice Calc?
Oké, it seems, i have a solution. The newer versions of the Spyder IDE support the copy paste.

Top Page

Possibly Related Threads...
Thread Author Replies Views Last Post
  Alternative ways of plotting confusion matrix amjass12 0 70 Aug-14-2019, 07:21 PM
Last Post: amjass12
  import numpy in sub-files paul18fr 1 89 Aug-06-2019, 12:38 PM
Last Post: chakrimakam
  Converting set of tuples to set of 2D numpy arrays ThemePark 0 75 Aug-04-2019, 05:07 PM
Last Post: ThemePark
  Trying to replace for loops with numpy vspoloni 8 315 Aug-04-2019, 07:09 AM
Last Post: paul18fr
  Add column to numpy matrix Gigux 1 111 Aug-02-2019, 12:05 AM
Last Post: scidam
  Python/C API Matrix to Numpy jibarra 0 75 Jul-29-2019, 03:25 PM
Last Post: jibarra
  numpy.copy / numpy.delete paul18fr 3 129 Jul-26-2019, 01:51 PM
Last Post: paul18fr
  When dividing elements of matrix i would like the result 0 instead of inf? Koczkodan 4 216 Jul-22-2019, 11:40 AM
Last Post: Koczkodan
  Error installing numpy srm 3 296 Jul-08-2019, 06:26 PM
Last Post: srm
  AttributeError: module 'numpy' has no attribute 'array aapurdel 7 1,301 May-29-2019, 02:48 AM
Last Post: heiner55

Forum Jump:

Users browsing this thread: 1 Guest(s)