0.9.0 • Published 9 years ago

kleinberg-burst v0.9.0

Weekly downloads
1
License
MIT
Repository
github
Last release
9 years ago

node-kleinberg-burst

Example

var burst = require('kleinberg-burst');
var offsets = [1, 2, 3, 10, 11, 12, 13 14, 20, 25, 30];
burst(offsets)

Methods

var burst = require('kleinberg-burst')

var levels = burst(offsets, opts);

offset is an array of occurrence time offsets. The function returns an array whose elements are the burst levels at the time of each occurrence.

Options

opts.s = 2 - the base of the exponent used to determine event frequencies in a given state

opts.gamma = 1 - a coefficient modifies the cost of a transition to a higher state

Install

$ npm i kleinberg-burst

See Also

License

MIT