Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integer input not accepted #27

Closed
jrfiedler opened this issue Oct 14, 2018 · 0 comments · Fixed by #30
Closed

Integer input not accepted #27

jrfiedler opened this issue Oct 14, 2018 · 0 comments · Fixed by #30

Comments

@jrfiedler
Copy link

The loess function doesn't accept integer input:

julia> using Loess

julia> x = [1, 2, 3, 4];

julia> y = [1.0, 2.0, 3.0, 4.0];

julia> model = loess(x, y, span = 0.33);
ERROR: MethodError: no method matching loess(::Array{Int64,1}, ::Array{Float64,1}; span=0.25)
Closest candidates are:
  loess(::AbstractArray{T<:AbstractFloat,2}, ::AbstractArray{T<:AbstractFloat,1}; normalize, span, degree) where T<:AbstractFloat at /home/jf/.julia/packages/Loess/TaYdb/src/Loess.jl:42
  loess(::AbstractArray{T<:AbstractFloat,1}, ::AbstractArray{T<:AbstractFloat,1}; normalize, span, degree) where T<:AbstractFloat at /home/jf/.julia/packages/Loess/TaYdb/src/Loess.jl:110
Stacktrace:
 [1] top-level scope at none:0

The error goes away if x is float.

ararslan added a commit that referenced this issue Jan 29, 2019
@ararslan ararslan mentioned this issue Jan 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant