mlr-org / mlr3fda

Functional Data Analysis for mlr3
https://mlr3fda.mlr-org.com/
GNU Lesser General Public License v3.0
4 stars 2 forks source link

feat: added PipeOp for interpolation #48

Closed m-muecke closed 9 months ago

m-muecke commented 1 year ago

… data

m-muecke commented 1 year ago

I think we need a little more flexibility here. This will use as a grid all x values that are observed for at least one individiual, correct? I think there needs to be an argument that controls for which x values we evaluate the functions.

Yes it will flatten the values into a single grid, but that's exactly how it was before, the only change is that interpolation will interpolate the values in case of NAs. What else did you have in mind?

sebffischer commented 1 year ago

It should be possible to specify the common grid as otherwise we might get very large matrices with many NAs

sebffischer commented 1 year ago

A quick grep shows that the following is useful information:

https://github.com/tidyfun/tf/blob/4f72b00008e40516d252eb54c0b9cf2739678525/R/vctrs.R#L50-L55

m-muecke commented 1 year ago

It should be possible to specify the common grid as otherwise we might get very large matrices with many NAs

It will only have many NAs when interpolate is set to FALSE and the args are not on the curve. But sure the matrix will get quite large.

m-muecke commented 1 year ago

A quick grep shows that the following is useful information:

https://github.com/tidyfun/tf/blob/4f72b00008e40516d252eb54c0b9cf2739678525/R/vctrs.R#L50-L55

Would make sense having another argument for passing the relevant args and have it set to NULL as a default for leaving in all args across the tfd vector