I'm an undergrad at university particapting in a research credit with a professor, so this is pretty much an independent project for me.
I am converting a matlab script into a python (3.4) script for easier use on the rest of my project. The 'find' function is employed in the script, like so:
keyindx = find(summags>=cumthresh,1)
Keyindx would contain the location of the first value inside summag above cumthresh
So, as an example:
summags = [ 1 4 8 16 19]
cumthresh = 5
then keyindx would return with an index of 2, whose element corresponds to 8.
My question is, I am trying to find a similar function in python (I am also using numpy and can use whatever library I need) that will work the same way. I mean, coming from a background in C I know how to get everything I need, but I figure there's a better way to do this then just write some C style code.
So, any hints about where to look in the python docs and about finding useful functions in general?