mlr-org / mlr3pipelines

Dataflow Programming for Machine Learning in R
https://mlr3pipelines.mlr-org.com/
GNU Lesser General Public License v3.0
140 stars 25 forks source link

Add field "man" + method "help()" #649

Closed mllg closed 2 years ago

mllg commented 2 years ago

In mlr3 you can now always call object$help() to open the associated help page. The respective man page is stored in field "man".

I guess this is easier for the user than to teach him our conventions of the help page name pattern. Would be great to have for all pipeops and pipelines.

mb706 commented 2 years ago

why not overload the ?-operator (is it not possible)? Also would $help() not just call help(class(self)[[1]]) or something like this, what does man do?

mllg commented 2 years ago

Sometimes we have multiple object and man pages for the same class, e.g. if they only differ by a hyperpar.

Merged by @be-marc .

mb706 commented 2 years ago

multiple man pages for the same class

example?

Shouldn't class(self)[[1]] then at least be the default instead of copy-pasting it in every initialize() call?

mllg commented 2 years ago

One example would be the MeasureSimple class in mlr3.

And yes you can pick a different default.

mb706 commented 2 years ago

Should the man slot get used anywhere besides in the class's own $help()?