File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,10 @@ function loess(
44
44
degree:: Integer = 2 ,
45
45
cell:: AbstractFloat = 0.2
46
46
) where T<: AbstractFloat
47
+
48
+ Base. require_one_based_indexing (xs)
49
+ Base. require_one_based_indexing (ys)
50
+
47
51
if size (xs, 1 ) != size (ys, 1 )
48
52
throw (DimensionMismatch (" Predictor and response arrays must of the same length" ))
49
53
end
@@ -180,15 +184,15 @@ function predict(model::LoessModel, zs::AbstractVector)
180
184
throw (ArgumentError (" Multivariate blending not yet implemented" ))
181
185
end
182
186
183
- predict .( Ref ( model), zs)
187
+ return [ predict ( model, z) for z in zs]
184
188
end
185
189
186
190
function predict (model:: LoessModel , zs:: AbstractMatrix )
187
191
if size (model. xs, 2 ) > 1
188
192
throw (ArgumentError (" Multivariate blending not yet implemented" ))
189
193
end
190
194
191
- return [ predict (model, z) for z in vec (zs)]
195
+ return predict (model, vec (zs))
192
196
end
193
197
194
198
"""
You can’t perform that action at this time.
0 commit comments