1 | # Change Log
|
2 |
|
3 | All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
4 |
|
5 | <a name="7.0.0"></a>
|
6 | # [7.0.0](https://github.com/simple-statistics/simple-statistics/compare/v6.1.1...v7.0.0) (2018-12-30)
|
7 |
|
8 |
|
9 | ### Bug Fixes
|
10 |
|
11 | * change umd name from simpleStatistics to ss ([59b42c0](https://github.com/simple-statistics/simple-statistics/commit/59b42c0))
|
12 | * Fix flipped umd:main package entry ([c9fe55b](https://github.com/simple-statistics/simple-statistics/commit/c9fe55b))
|
13 |
|
14 |
|
15 | ### Chores
|
16 |
|
17 | * Refactor from functions to classes, use Number.isInteger ([d974a1a](https://github.com/simple-statistics/simple-statistics/commit/d974a1a)), closes [#296](https://github.com/simple-statistics/simple-statistics/issues/296)
|
18 |
|
19 |
|
20 | ### BREAKING CHANGES
|
21 |
|
22 | * IE11 support is dropped.
|
23 |
|
24 |
|
25 |
|
26 | <a name="6.1.1"></a>
|
27 | ## [6.1.1](https://github.com/simple-statistics/simple-statistics/compare/v6.1.0...v6.1.1) (2018-09-24)
|
28 |
|
29 |
|
30 | ### Bug Fixes
|
31 |
|
32 | * **permutationTest:** Add TypeScript definition for permutationTest ([e7fa9db](https://github.com/simple-statistics/simple-statistics/commit/e7fa9db)), closes [#298](https://github.com/simple-statistics/simple-statistics/issues/298)
|
33 | * array quantile on certain kinds of input ([#334](https://github.com/simple-statistics/simple-statistics/issues/334)) ([e9d007e](https://github.com/simple-statistics/simple-statistics/commit/e9d007e))
|
34 |
|
35 |
|
36 |
|
37 | <a name="6.1.0"></a>
|
38 | # [6.1.0](https://github.com/simple-statistics/simple-statistics/compare/v6.0.1...v6.1.0) (2018-06-23)
|
39 |
|
40 |
|
41 | ### Features
|
42 |
|
43 | * gammaln ([9d03631](https://github.com/simple-statistics/simple-statistics/commit/9d03631))
|
44 |
|
45 |
|
46 |
|
47 | <a name="6.0.1"></a>
|
48 | ## [6.0.1](https://github.com/simple-statistics/simple-statistics/compare/v6.0.0...v6.0.1) (2018-05-11)
|
49 |
|
50 |
|
51 |
|
52 | <a name="6.0.0"></a>
|
53 | # [6.0.0](https://github.com/simple-statistics/simple-statistics/compare/v5.4.0...v6.0.0) (2018-04-30)
|
54 |
|
55 |
|
56 | ### Bug Fixes
|
57 |
|
58 | * Polyfill Number.isInteger function before committing to dropping IE11 ([#297](https://github.com/simple-statistics/simple-statistics/issues/297)) ([01cc37e](https://github.com/simple-statistics/simple-statistics/commit/01cc37e)), closes [#296](https://github.com/simple-statistics/simple-statistics/issues/296)
|
59 |
|
60 |
|
61 | ### build
|
62 |
|
63 | * **package.json:** Remove bower and component.json compatibility ([#294](https://github.com/simple-statistics/simple-statistics/issues/294)) ([0593cb8](https://github.com/simple-statistics/simple-statistics/commit/0593cb8)), closes [#293](https://github.com/simple-statistics/simple-statistics/issues/293)
|
64 |
|
65 |
|
66 | ### Features
|
67 |
|
68 | * Gamma Function ([39c8ecd](https://github.com/simple-statistics/simple-statistics/commit/39c8ecd))
|
69 |
|
70 |
|
71 | ### BREAKING CHANGES
|
72 |
|
73 | * **package.json:** simple-statistics is no longer supported as a component module or a bower module.
|
74 | All other forms of support - script tag, unpkg, npm - continue.
|
75 |
|
76 |
|
77 |
|
78 | <a name="5.4.0"></a>
|
79 | # [5.4.0](https://github.com/simple-statistics/simple-statistics/compare/v5.3.1...v5.4.0) (2018-04-21)
|
80 |
|
81 |
|
82 | ### Features
|
83 |
|
84 | * Permutation test ([1be011e](https://github.com/simple-statistics/simple-statistics/commit/1be011e))
|
85 |
|
86 |
|
87 |
|
88 | <a name="5.3.1"></a>
|
89 | ## [5.3.1](https://github.com/simple-statistics/simple-statistics/compare/v5.3.0...v5.3.1) (2018-03-23)
|
90 |
|
91 |
|
92 | ### Bug Fixes
|
93 |
|
94 | * Someone simple-statistics dependend on itself... ([12acd40](https://github.com/simple-statistics/simple-statistics/commit/12acd40))
|
95 |
|
96 |
|
97 |
|
98 | <a name="5.3.0"></a>
|
99 | # [5.3.0](https://github.com/simple-statistics/simple-statistics/compare/v5.2.1...v5.3.0) (2018-03-23)
|
100 |
|
101 |
|
102 | ### Features
|
103 |
|
104 | * adding extent ([80bcc99](https://github.com/simple-statistics/simple-statistics/commit/80bcc99))
|
105 | * adding extentSorted ([053399f](https://github.com/simple-statistics/simple-statistics/commit/053399f))
|
106 | * adding quantileRankSorted ([#285](https://github.com/simple-statistics/simple-statistics/issues/285)) ([84248ea](https://github.com/simple-statistics/simple-statistics/commit/84248ea))
|
107 |
|
108 |
|
109 |
|
110 | <a name="5.2.1"></a>
|
111 | ## [5.2.1](https://github.com/simple-statistics/simple-statistics/compare/v5.2.0...v5.2.1) (2017-12-20)
|
112 |
|
113 |
|
114 |
|
115 | <a name="5.2.0"></a>
|
116 | # [5.2.0](https://github.com/simple-statistics/simple-statistics/compare/v5.1.0...v5.2.0) (2017-11-29)
|
117 |
|
118 |
|
119 | ### Features
|
120 |
|
121 | * **package:** Add unpkg field to package.json to support unpkg default entry point ([#267](https://github.com/simple-statistics/simple-statistics/issues/267)) ([c1afd51](https://github.com/simple-statistics/simple-statistics/commit/c1afd51))
|
122 |
|
123 |
|
124 |
|
125 | <a name="5.1.0"></a>
|
126 | # [5.1.0](https://github.com/simple-statistics/simple-statistics/compare/v5.0.0...v5.1.0) (2017-10-23)
|
127 |
|
128 |
|
129 | ### Features
|
130 |
|
131 | * Add TypeScript definition ([688538b](https://github.com/simple-statistics/simple-statistics/commit/688538b))
|
132 |
|
133 |
|
134 |
|
135 | <a name="5.0.1"></a>
|
136 | ## [5.0.1](https://github.com/simple-statistics/simple-statistics/compare/v5.0.0...v5.0.1) (2017-10-15)
|
137 |
|
138 |
|
139 | ### Bug Fixes
|
140 |
|
141 | * Add index.js to package.json ([b744bfa](https://github.com/simple-statistics/simple-statistics/commit/b744bfa)), closes [#253](https://github.com/simple-statistics/simple-statistics/issues/253)
|
142 |
|
143 |
|
144 |
|
145 | <a name="5.0.0"></a>
|
146 | # [5.0.0](https://github.com/simple-statistics/simple-statistics/compare/v4.1.1...v5.0.0) (2017-09-26)
|
147 |
|
148 |
|
149 | ### Features
|
150 |
|
151 | * Expose ES6 modules ([a775ef6](https://github.com/simple-statistics/simple-statistics/commit/a775ef6)), closes [#210](https://github.com/simple-statistics/simple-statistics/issues/210)
|
152 | * kernel density estimation ([#245](https://github.com/simple-statistics/simple-statistics/issues/245)) ([8637af1](https://github.com/simple-statistics/simple-statistics/commit/8637af1)), closes [#244](https://github.com/simple-statistics/simple-statistics/issues/244)
|
153 |
|
154 |
|
155 | ### BREAKING CHANGES
|
156 |
|
157 | * simple-statistics now uses ES6 modules internally, and exposes a entry point for other modules to use it as an ES6 module.
|
158 |
|
159 | This means:
|
160 |
|
161 | - If you use Rollup or another library that supports the `jsnext:main` or `module` fields of package.json, you'll likely automatically start using this feature. When you use simple-statistics as an ES6 module, `import {min} from "simple-statistics"` and other imports of only a few of its methods will automatically do 'tree-shaking' and only pull in the parts you use (if your bundling tool supports tree-shaking)
|
162 | - Sub-requiring parts of simple-statistics, like `require('simple-statistics/min')` is **deprecated** and will not work. Its components are now written with ES6 syntax.
|
163 |
|
164 |
|
165 |
|
166 | <a name="4.1.1"></a>
|
167 | ## [4.1.1](https://github.com/simple-statistics/simple-statistics/compare/v4.1.0...v4.1.1) (2017-08-05)
|
168 |
|
169 |
|
170 | ### Bug Fixes
|
171 |
|
172 | * expose BayesianClassifier & PerceptronModel instead of bayesian and perceptron ([1d03671](https://github.com/simple-statistics/simple-statistics/commit/1d03671))
|
173 |
|
174 |
|
175 |
|
176 | <a name="4.1.0"></a>
|
177 | # [4.1.0](https://github.com/simple-statistics/simple-statistics/compare/v4.0.0...v4.1.0) (2017-04-27)
|
178 |
|
179 |
|
180 | ### Features
|
181 |
|
182 | * sampleKurtosis ([1d9eec2](https://github.com/simple-statistics/simple-statistics/commit/1d9eec2))
|
183 |
|
184 |
|
185 |
|
186 | <a name="4.0.0"></a>
|
187 | # [4.0.0](https://github.com/simple-statistics/simple-statistics/compare/v3.0.0...v4.0.0) (2017-04-25)
|
188 |
|
189 |
|
190 | ### Bug Fixes
|
191 |
|
192 | * Remove mixin method ([#215](https://github.com/simple-statistics/simple-statistics/issues/215)) ([85036e2](https://github.com/simple-statistics/simple-statistics/commit/85036e2)), closes [#211](https://github.com/simple-statistics/simple-statistics/issues/211)
|
193 |
|
194 |
|
195 | ### Performance Improvements
|
196 |
|
197 | * **binomialDistribution:** avoid expensive factorial calculations ([#205](https://github.com/simple-statistics/simple-statistics/issues/205)) ([525f9c0](https://github.com/simple-statistics/simple-statistics/commit/525f9c0))
|
198 | * **core:** Improve performance of min, max, sumNthPowerDeviations, variance, sampleVariance ([#195](https://github.com/simple-statistics/simple-statistics/issues/195)) ([9d2569a](https://github.com/simple-statistics/simple-statistics/commit/9d2569a))
|
199 | * **distributions:** return array instead of object ([#209](https://github.com/simple-statistics/simple-statistics/issues/209)) ([6c5df5f](https://github.com/simple-statistics/simple-statistics/commit/6c5df5f))
|
200 | * **poissonDistribution:** avoid expensive factorial calculation ([#206](https://github.com/simple-statistics/simple-statistics/issues/206)) ([b34aceb](https://github.com/simple-statistics/simple-statistics/commit/b34aceb))
|
201 | * **poissonDistribution:** use Math.exp instead of Math.pow ([#208](https://github.com/simple-statistics/simple-statistics/issues/208)) ([6491dfa](https://github.com/simple-statistics/simple-statistics/commit/6491dfa))
|
202 | * **sampleSkewness:** Improve sampleSkewness performance ([#197](https://github.com/simple-statistics/simple-statistics/issues/197)) ([03d37eb](https://github.com/simple-statistics/simple-statistics/commit/03d37eb))
|
203 | * **sum:** Switch from Kahan to Kahan-Babuska algorithm ([1b42d7f](https://github.com/simple-statistics/simple-statistics/commit/1b42d7f))
|
204 |
|
205 |
|
206 | ### BREAKING CHANGES
|
207 |
|
208 | * Removes .mixin(). Instead use simple-statistics in a functional style.
|
209 | * **distributions:** The return value of bernoulliDistribution, binomialDistribution, and poissonDistribution is no longer an Object with number keys, it is now an Array of numbers.
|
210 |
|
211 |
|
212 |
|
213 | <a name="3.0.0"></a>
|
214 | # [3.0.0](https://github.com/simple-statistics/simple-statistics/compare/v2.5.0...v3.0.0) (2017-04-06)
|
215 |
|
216 | **Breaking change**: before this release, simple-statistics would return `NaN`
|
217 | when provided with invalid input. After 3.0.0, simple-statistics will throw
|
218 | exceptions when provided with invalid input. If you previously used `isNaN` to
|
219 | test for these error cases, switch to using `try` and `catch`, or make sure
|
220 | that valid input is given to simple-statistics.
|
221 |
|
222 | ### Features
|
223 |
|
224 | * **mean:** combineMeans, a method for combining calculated means ([d9e3ebc](https://github.com/simple-statistics/simple-statistics/commit/d9e3ebc))
|
225 | * **mean:** subtractFromMean, a method to remove a value from the mean ([afe76e9](https://github.com/simple-statistics/simple-statistics/commit/afe76e9))
|
226 | * **variance:** combineVariances, a method for combining pre-calculated variances of two dataset ([68133f7](https://github.com/simple-statistics/simple-statistics/commit/68133f7))
|
227 |
|
228 |
|
229 |
|
230 | <a name="2.5.0"></a>
|
231 | # [2.5.0](https://github.com/simple-statistics/simple-statistics/compare/v2.4.0...v2.5.0) (2017-02-24)
|
232 |
|
233 |
|
234 | ### Features
|
235 |
|
236 | * **mean:** addToMean, a method to update an mean with a new element ([b6637b4](https://github.com/simple-statistics/simple-statistics/commit/b6637b4))
|
237 |
|
238 |
|
239 |
|
240 | <a name="2.4.0"></a>
|
241 | # [2.4.0](https://github.com/simple-statistics/simple-statistics/compare/v2.3.0...v2.4.0) (2017-02-22)
|
242 |
|
243 |
|
244 | ### Bug Fixes
|
245 |
|
246 | * **build:** Ignore conventional-changelog-core for Flow ([4874868](https://github.com/simple-statistics/simple-statistics/commit/4874868))
|
247 |
|
248 | ### Features
|
249 |
|
250 | * **mode:** Implement modeFast, an indexed mode implementation (#183) ([59b7191](https://github.com/simple-statistics/simple-statistics/commit/59b7191))
|
251 |
|
252 |
|
253 |
|
254 | <a name="2.3.0"></a>
|
255 | # [2.3.0](https://github.com/simple-statistics/simple-statistics/compare/v2.2.0...v2.3.0) (2017-02-17)
|
256 |
|
257 |
|
258 | ### Features
|
259 |
|
260 | * **core:** sampleWithReplacement (#174) ([a8d05d1](https://github.com/simple-statistics/simple-statistics/commit/a8d05d1))
|
261 |
|
262 |
|
263 |
|
264 | # CHANGELOG
|
265 |
|
266 | ## 2.2.0
|
267 |
|
268 | * Improved [Ckmeans](https://github.com/simple-statistics/simple-statistics/pull/163) algorithm
|
269 | from the [updated R project](https://cran.r-project.org/web/packages/Ckmeans.1d.dp/NEWS)
|
270 | that dramatically increases performance.
|
271 | * Adds `permutationHeap` method for computing all permutations of an array.
|
272 | * Adds `combinations` for combinations without replacement
|
273 | * Adds `combinationsReplacement` for combinations with replacement
|
274 |
|
275 | ## 2.1.0
|
276 |
|
277 | * Adds `bisect` method that implements the [bisection method](https://en.wikipedia.org/wiki/Bisection_method)
|
278 | for root-finding. Thanks [Jamie Neubert Pedersen](https://github.com/eikooc)
|
279 | for the contribution!
|
280 |
|
281 | ## 2.0.0
|
282 |
|
283 | New features:
|
284 |
|
285 | * `product`: returns the product of a series of numbers
|
286 | * `medianSorted`: exposes the internal method of `median`
|
287 | that only operates on sorted arrays and works in constant time
|
288 | * `modeSorted`: exposes the internal method of `mode` and works
|
289 | in linear time.
|
290 |
|
291 | Specifications:
|
292 |
|
293 | * Adds [Flow](http://flowtype.org/) annotations to all methods, allowing
|
294 | up-front typechecking if you use Flow in your application.
|
295 |
|
296 | Changes:
|
297 |
|
298 | * Invalid input now uniformly produces the value `NaN` instead
|
299 | of previously a mix of `null` and `undefined`.
|
300 | * The method `sortedUniqueCount` is now called `uniqueCountSorted` to
|
301 | match the other sorted methods, `medianSorted` and `modeSorted`
|
302 |
|
303 | Fixes:
|
304 |
|
305 | * `equalIntervalBreaks` was not exported by `index.js`, and now is.
|
306 |
|
307 | ## 1.0.1
|
308 |
|
309 | Fixes:
|
310 |
|
311 | * Fixes to ckmeans algorithm (thanks to @llimllib) (#125)
|
312 |
|
313 | Housekeeping:
|
314 |
|
315 | * Add keywords to package. Fixes #120
|
316 | * Standardize indentation, add example for epsilon
|
317 | * Browser testing with Sauce Labs
|
318 |
|
319 | Bundle size optimizations:
|
320 |
|
321 | * Add external sourcemaps for minified and unminified standalone bundles
|
322 | * Use bundle-collapser for smaller bundles
|
323 | * Indicate numericSort as an internal method.
|
324 |
|
325 | ## 1.0.0
|
326 |
|
327 | ### Breaking Changes
|
328 |
|
329 | * Removed the .m() and .b() shortcuts from the linear regression
|
330 | class. Use `.mb().b` and `.mb().m` instead.
|
331 | * linearRegression is now a function, and linearRegressionLine is a separate
|
332 | function.
|
333 |
|
334 | **UPGRADING**
|
335 |
|
336 | #### Linear Regression
|
337 |
|
338 | Before:
|
339 |
|
340 | ```js
|
341 | var l = ss.linear_regression().data([[0, 0], [1, 1]]);
|
342 | l.line()(0); // 0
|
343 | ```
|
344 |
|
345 | After:
|
346 |
|
347 | ```js
|
348 | var line = ss.linearRegressionLine(ss.linearRegression([[0, 0], [1, 1]]));
|
349 | line(0); // 0
|
350 | ```
|
351 |
|
352 | #### Jenks -> ckmeans
|
353 |
|
354 | The implementation of Jenks natural breaks was removed: an implementation
|
355 | of Ckmeans, an improvement on its technique, is added. Ckmeans should
|
356 | work better for nearly all Jenks usecases.
|
357 |
|
358 | Before:
|
359 |
|
360 | ```js
|
361 | ss.jenks([1, 2, 4, 5, 7, 9, 10, 20], 3) //= [1, 7, 20, 20]
|
362 | ```
|
363 |
|
364 | After:
|
365 |
|
366 | ```js
|
367 | ss.ckmeans([1, 2, 4, 5, 7, 9, 10, 20], 3))
|
368 |
|
369 | [ [ 1,
|
370 | 2,
|
371 | 4,
|
372 | 5,
|
373 | 7,
|
374 | 9 ],
|
375 | [ 10 ],
|
376 | [ 20 ] ]
|
377 | ```
|
378 |
|
379 | Instead of class breaks, ckmeans returns clustered data. Class breaks
|
380 | can be derived by taking the first value from each cluster:
|
381 |
|
382 | ```js
|
383 | var breaks = ss.ckmeans([1, 2, 4, 5, 7, 9, 10, 20], 3)).map(function(cluster) {
|
384 | return cluster[0];
|
385 | });
|
386 | ```
|
387 |
|
388 | * `BayesModel` is now a class
|
389 | * `PerceptronModel` is now a class, and the `weights` and `bias` members
|
390 | are accessable as properties rather than methods.
|
391 | * All multi-word method names are now camelCase rather than underscore_cased:
|
392 | this means that a method like `ss.r_squared` is now accessible as `ss.rSquared`
|
393 |
|
394 | ### New Features
|
395 |
|
396 | * Ckmeans replaces Jenks
|
397 | * `sortedUniqueCount` provides an extremely fast method for counting
|
398 | unique values of sorted arrays.
|
399 | * `sumNthPowerDeviations` is now exposed, providing a simple way to calculate
|
400 | the fundamental aspect of measures like variance and skewness.
|
401 |
|
402 | ### Non-Breaking Changes
|
403 |
|
404 | * JSDoc documentation throughout
|
405 | * Each function is now its own file, and simple-statistics
|
406 | is assembled with CommonJS-style require() statements. simple-statistics can
|
407 | still be used in a browser with browserify.
|
408 | * The standard normal table is now calculated using the cumulative distribution
|
409 | function, rather than hardcoded.
|
410 |
|
411 | ## 0.9.2
|
412 |
|
413 | * Improved test coverage
|
414 | * Switched linting from JSHint to [eslint](http://eslint.org/) and fixed
|
415 | style issues this uncovered.
|
416 |
|
417 | ## 0.9.1
|
418 |
|
419 | * Fixes `.jenks` corner cases.
|
420 |
|
421 | ## 0.9.0
|
422 |
|
423 | * Adds `.sample` for simple random sampling
|
424 | * Adds `.shuffle` and `.shuffleInPlace` for random permutations
|
425 | * Adds `.chunk` for splitting arrays into chunked subsets
|
426 |
|
427 | ## 0.8.1
|
428 |
|
429 | * fixes a bug in `mode` that favored the last new number
|
430 |
|
431 | ## 0.8.0
|
432 |
|
433 | * `mixin` can now take an array in order to mixin functions into a single array
|
434 | instance rather than the global Array prototype.
|
435 |
|
436 | ## 0.7.0
|
437 |
|
438 | * Adds `simple_statistics.harmonicMean` thanks to [jseppi](https://github.com/jseppi)
|
439 |
|
440 | ## 0.6.0
|
441 |
|
442 | * Adds `simple_statistics.quantileSorted` thanks to [rluta](http://github.com/rluta)
|
443 | * `simple_statistics.quantile` now accepts a sorted list of quantiles as a second argument
|
444 | * Improved test coverage
|
445 |
|
446 | ## 0.5.0
|
447 |
|
448 | * Adds `simple_statistics.cumulativeStdNormalProbability` by [doronlinder](https://github.com/doronlinder)
|
449 | * Adds `simple_statistics.zScore` by doronlinder
|
450 | * Adds `simple_statistics.standardNormalTable`
|
451 |
|
452 | ## 0.4.0
|
453 |
|
454 | * Adds `simple_statistics.median_absolute_deviation()` by siculars
|
455 | * Adds `simple_statistics.iqr()` by siculars
|
456 | * Adds `simple_statistics.skewness()` by Doron Linder
|
457 | * Lower-level accessors for linear regression allow users to do the line
|
458 | equation themselves
|
459 |
|
460 | ## 0.3.0
|
461 |
|
462 | * Adds `simple_statistics.jenks()`
|
463 | * Adds `simple_statistics.jenksMatrices()`
|
464 | * Improves test coverage and validation
|
465 |
|
466 | ## 0.2.0
|
467 |
|
468 | * Adds `simple_statistics.quantile()`
|
469 | * Adds `simple_statistics.mixin()`
|
470 | * Adds `simple_statistics.geometricMean()`
|
471 | * Adds `simple_statistics.sampleVariance()`
|
472 | * Adds `simple_statistics.sampleCovariance()`
|
473 |
|
474 | ## 0.1.0
|
475 |
|
476 | * Adds `simple_statistics.tTest()`
|
477 | * Adds `simple_statistics.min()`
|
478 | * Adds `simple_statistics.max()`
|