This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Project Description

Find positive spike-like peaks from 1-D array.

example

from peakdetect_delta import peakdetect, peakdetect_simpleedge

# peak are represented as a tuple ((pvalue, pidx), (sidx, eidx))
#   pvalue: value at pidx
#   pidx: index of the peak
#   sidx: index where y[sidx+1] - y[sidx] > rdelta
#   eidx: index where y[eidx] - y[eidx-1] < fdelta
#   so, y[sidx:eidx] takes the detected peak

# examples of peakdetect_simpleedge
# case 1.1
s = [0, 0, 1.5, 2, 0, 0]
assert peakdetect_simpleedge(s, rdelta=1, fdelta=-1) == [((2, 3), (1, 5))]

# case 1.2
s = [0, 2, 0, -2, 0, -2]
assert peakdetect_simpleedge(s, rdelta=1, fdelta=1) == [((2, 1), (0, 3)),
                                                        ((0, 4), (3, 6))]

# example of peakdetect
s= [0, 3, 0, 2, 0, 0, -1, 1, -2, -1]
# same as peakdetect_simpleedge
assert peakdetect(s, rdelta=1, fdelta=-1, minimumspace=-1)
           == [((3, 1), (0, 3)), ((2, 3), (2, 5)), ((1, 7), (6, 9))]
# first 2 peaks are merged
assert peakdetect(s, rdelta=1, fdelta=-1, minimumspace=0)
           == [((3, 1), (0, 5)), ((1, 7), (6, 9))]
peakdetect(s, rdelta=1, fdelta=-1, minimumspace=2)
           == [((3, 1), (0, 9))]
Release History

Release History

0.1.0

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting