Skip to content

Commit 3fcd75e

Browse files
add addsamplestobackground and n_knots to maxnetbinaryclassifier
1 parent a25a082 commit 3fcd75e

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/mlj_interface.jl

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ mutable struct MaxnetBinaryClassifier <: MMI.Probabilistic
22
features::Union{String, Vector{<:AbstractFeatureClass}}
33
regularization_multiplier::Float64
44
regularization_function
5+
addsamplestobackground::Bool
6+
n_knots::Integer
57
weight_factor::Float64
68
link::GLM.Link
79
clamp::Bool
@@ -11,14 +13,14 @@ end
1113
function MaxnetBinaryClassifier(;
1214
features="",
1315
regularization_multiplier = 1.0, regularization_function = default_regularization,
14-
weight_factor = 100.,
16+
addsamplestobackground = true, n_knots = 50, weight_factor = 100.,
1517
link = CloglogLink(), clamp = false,
1618
kw...
1719
)
1820

1921
MaxnetBinaryClassifier(
2022
features, regularization_multiplier, regularization_function,
21-
weight_factor, link, clamp, kw
23+
addsamplestobackground, n_knots, weight_factor, link, clamp, kw
2224
)
2325
end
2426

@@ -29,8 +31,8 @@ end
2931
3032
Use `MaxnetBinaryClassifier()` to create an instance with default parameters, or use keyword arguments to specify parameters.
3133
32-
All keywords are passed to `maxnet` when calling `fit!` on a machine of this model type.
33-
See the documentation of [`maxnet`](@ref) for the parameters and their defaults.
34+
The keywords `link`, and `clamp` are passed to [`Maxnet.predict`](@ref), while all other keywords are passed to [`maxnet`](@ref).
35+
See the documentation of these functions for the meaning of these parameters and their defaults.
3436
3537
# Example
3638
```jldoctest

0 commit comments

Comments
 (0)