Skip to content

mad() is broken -- should promote integers to floats before calling mad!() #197

Closed
@dcarrera

Description

@dcarrera

The mad function should promote integers to floats before calling mad!

julia> mad([1,2,3,4])
ERROR: InexactError()
 in mad! at /home/daniel/.julia/v0.4/StatsBase/src/scalarstats.jl:184
 in mad! at /home/daniel/.julia/v0.4/StatsBase/src/scalarstats.jl:183
 in mad at /home/daniel/.julia/v0.4/StatsBase/src/scalarstats.jl:179

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions