Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Aug 26, 2015
  1. @trevnorris

    Release 1.4.1

    trevnorris authored
  2. @akrawitz @trevnorris

    Fix cdf()sreturn values

    akrawitz authored trevnorris committed
    Fix cdf()s to return 0 below support and 1 above support
    
    Fixes for multiple distributions (centralF, chisquare, gamma, invgamma,
    kumaraswamy, lognormal, pareto, triangular) so that cdf()s return proper
    values outside of support.
    
    Also added testing for these cdf()s. If test already existed, just added
    ones outside support, otherwise added multiple tests inside and outside
    support.
    
    PR-URL: #157
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Aug 25, 2015
  1. @trevnorris

    Release 1.4.0

    trevnorris authored
  2. @akrawitz @trevnorris

    Add new test cases for chisquare.pdf()

    akrawitz authored trevnorris committed
    Add test cases for chisquare.pdf() when x=0 and df <= 2. Used R's
    dchisq() for reference.
    
    PR-URL: #154
    Reivewed-by: Trevor Norris <trev.norris@gmail.com>
  3. @akrawitz @trevnorris

    Fix chisquare.pdf() when x = 0

    akrawitz authored trevnorris committed
    The previous fix did not return the correct values for the pdf when x =
    0. This commit corrects that. When dof < 2 then the pdf should return
    Infinity, when dof > 2 then the pdf should return 0, and when dof = 2
    then the pdf should return 0.5. You can confirm these with dchisq() in
    R.
    
    PR-URL: #154
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  4. @akrawitz @trevnorris

    Adding new tests for centralF.pdf

    akrawitz authored trevnorris committed
    Adding tests for edge cases where x = 0 and df1 <= 2.
    
    PR-URL: #153
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  5. @akrawitz @trevnorris

    Fix centralF returning NaN

    akrawitz authored trevnorris committed
    When x = 0 and df1 <= 2, the pdf was still returning NaN. There were a
    couple of checks in the code that appeared to be intended to deal with
    this situation, but they weren't conditional on x = 0, when they should,
    and they were conditional on the value of df2, when they shouldn't. This
    fixes those problems.
    
    PR-URL: #153
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  6. @akrawitz @trevnorris

    Fix kumaraswamy.pdf and add tests

    akrawitz authored trevnorris committed
    Add special cases for the two instances where the 'log' form of the PDF
    fails (when x = 0 and alpha = 1, and when x = 1, and beta = 1).
    Also added extensive tests for the kumaraswamy.pdf() based on dkumar()
    in R package VGAM. Note that there are a few cases where the R function
    incorrectly returns NaN. You can confirm the correct values in these
    cases by doing the math using the function for the PDF here:
    https://en.wikipedia.org/wiki/Kumaraswamy_distribution
    
    PR-URL: #155
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
  7. @jamescgibson @trevnorris

    Add documentation for Kumaraswamy Inverse

    jamescgibson authored trevnorris committed
  8. @akrawitz @trevnorris

    Add quantile function for Kumaraswamy distribution

    akrawitz authored trevnorris committed
    The Kumaraswamy distribution didn't have a qunatile function defined
    yet, so I have added one. The math is based on the equation provided in
    the documentation for the R function quakur here:
    http://www.cran.r-project.org/web/packages/lmomco/lmomco.pdf
    
    Add tests for kumaraswamy.inv()
    
    Add tests using R's qkumar() in package VGAM as a reference.
    
    PR-URL: #152
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
  9. @akrawitz @trevnorris

    Add median function for beta distribution

    akrawitz authored trevnorris committed
    The median function was not yet implemented for the beta distribution.
    This adds one using a straightforward implementation based on the
    already existing quantile function.
    
    Adding testing for beta.median and fixing testing for beta.mode
    
    Adding tests for beta.median, comparing it to qbeta() in R. Also fixing
    the tests for beta.mode which had a significant digits problem and a
    typo.
    
    PR-URL: #151
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
  10. @jamescgibson @trevnorris

    Add documentation for pareto.inv

    jamescgibson authored trevnorris committed
  11. @akrawitz @trevnorris

    Add quantile function for Pareto distribution

    akrawitz authored trevnorris committed
    The Pareto distribution did not have a quantile function (inverse
    cumulative distribution function) defined. The math for this function is
    based on the formula qf defined here:
    http://www.distributome.org/js/DistributomeDBSearch.xml.php?s=pareto
    
    Adding testing for pareto.inv()
    
    Testing pareto.inv() against values from qpareto() in R package VGAM.
    
    PR-URL: #150
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
  12. @skawian @trevnorris

    calculating percentile

    skawian authored trevnorris committed
    PR-URL: #160
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
  13. @smarden1 @trevnorris

    Add difference of proportions test and docs

    smarden1 authored trevnorris committed
    PR-URL: #158
    Reviewed-By: James Gibson <james.cameron.gibson@gmail.com>
Commits on Jul 20, 2015
  1. @akrawitz @trevnorris

    Update tests for triangular.pdf

    akrawitz authored trevnorris committed
    Updating and adding tests for triangular.pdf(). One of the previous
    tests was:
    assert.epsilon(tol, jStat.triangular.pdf(1.0, 1.0, 2.0, 1.0), 1.0);
    This test was failing, however the test is incorrect. A comment in the
    test code claimed that this test was based on R's dtriangle(x, a, b, c)
    from package 'triangle', however this is not consistent with the current
    return value for the R code:
    > dtriangle(1, 1, 2, 1)
    [1] NaN
    Warning message:
    In dTest(c(x, a, b, c)) :
    values required to be  a <= c <= b (at least one strict inequality)
    
    To further confuse matters, dtriangle() clearly has a bug in it, given
    that NaN is not the correct value for this case, and the provided
    warning is not even consistent with the passed parameters!
    
    So I am now using R's dtriang() from package mc2d as my reference, as it
    appears to be a better implementation of the triangular distribution.
    
    I have added the reference R code into the comment in the test file,
    since if we are going to refer to R functions for tests, we might as
    well make it easy for someone to confirm.
    
    Furthermore, I have added more tests, in an attempt to get basic
    coverage of the various segments of the triangular distribution for each
    of the basic forms it can take.
    
    PR-URL: #148
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  2. @akrawitz @trevnorris

    Return NaN instead of undef if params are illegal

    akrawitz authored trevnorris committed
    According to the definition of the triangular distribution: a <= c <= b
    and a < b. When the parameters passed in to the pdf violate these
    conditions, the appropriate return value to indicate that the result is
    mathematically undefined is NaN.
    
    PR-URL: #148
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  3. @akrawitz @trevnorris

    Fix for triangular.pdf issue

    akrawitz authored trevnorris committed
    Fix the PDF for the triangular distribution, so that it returns the
    proper value for an x that is less than, equal to, or greater than the
    parameter c.
    
    Fix: #101
    PR-URL: #148
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Jul 7, 2015
  1. @trevnorris

    Release 1.3.0

    trevnorris authored
  2. @trevnorris

    Rename MIT-LICENSE.txt to LICENSE

    Adam Mackler authored trevnorris committed
    This is to enable deployment of this project's bower package as a
    WebJar. See http://www.webjars.org/documentation
    
    PR-URL: #146
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Jun 22, 2015
  1. @jamescgibson @trevnorris

    Update documentation and add test for mode(true)

    jamescgibson authored trevnorris committed
    The documentation previously specified that jStat(<two dimensional
    array>).mode(true) returned 'the mode of the array', i.e. the most
    common row. However, inspection of the .mode() function shows that
    .mode(true) instead treats the two-dimensional array as one dimensional.
    
    I believe this is a reasonable method option; as far as I can tell there
    is no commonly accepted definition for 'the mode of an array'. If there
    is strong demand for 'finding the most common data point in my two
    dimensional data', it would be better to define it explicitly.
    
    Add a test to verify this behavior and update the documentation to
    reflect this.
    
    Fixes: #50
    PR-URL: #144
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Jun 16, 2015
  1. @fbukevin @trevnorris

    Add row-based vector summation.

    fbukevin authored trevnorris committed
    Also remove redundant variable 'tmp' in sum function.
    
    PR-URL: #140
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  2. @yujiosaka @trevnorris

    support all parameters in ztest as documented

    yujiosaka authored trevnorris committed
    PR-URL: #141
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on May 5, 2015
  1. @trevnorris

    Release 1.2.1

    trevnorris authored
  2. @arturaugusto @trevnorris

    Use betafn instead of gammafn on studentt pdf

    arturaugusto authored trevnorris committed
    PR-URL: #139
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  3. @jamescgibson @trevnorris

    Tests for the student t distribution

    jamescgibson authored trevnorris committed
    PR-URL: #138
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Apr 29, 2015
  1. @trevnorris

    Update dist/

    trevnorris authored
  2. @trevnorris

    Merge branch '1.1'

    trevnorris authored
    Conflicts:
    	package.json
  3. @kbroman @trevnorris

    Add non-central-t distribution and tests

    kbroman authored trevnorris committed
    The code does have convergence issues when the non-centrality parameter
    is large. (It can give inaccurate results.)
    
    Fixes: #131
    PR-URL: #135
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
  4. @trevnorris

    Now working on 1.1.5

    trevnorris authored
  5. @jamescgibson @trevnorris

    Fix incorrect formula for beta distribution

    jamescgibson authored trevnorris committed
    The formula for the mode of the beta distribution was incorrect.
    Corrected using Wolfram Alpha as test reference.
    
    Fixes: #133
    PR-URL: #134
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Commits on Apr 28, 2015
  1. @jamescgibson

    Merge pull request #136 from jamescgibson/readme_thing

    jamescgibson authored
    Add a note that dist/*.js need not be in PR
  2. @jamescgibson
Commits on Apr 23, 2015
  1. @trevnorris

    Merge branch '1.1'

    trevnorris authored
    Conflicts:
    	package.json
  2. @mryellow @trevnorris

    Note issues including jStat in RequireJS

    mryellow authored trevnorris committed
    Fixes: #54
    PR-URL: #132
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
Something went wrong with that request. Please try again.