You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This refers to indexing as in lambda.r#L14-L19 (multiple arrays, multiple axes, index as data.frame).
Idea:
This could be provided as a separate function (analogous to group)
The index could be filtered (e.g. to iterate 2 arrays together instead of every combination)
lambda could take an index instead of the along argument
Issues:
The index wouldn't know necessarily know which axis it was derived from
could be solved by adding along attribute to df
or wrapping the function call to subset indices (as below)
HPC calls like clustermq::Q_rows would not be able to call a function with the indexed object instead of the index of the object
instead of just creating the index we could also create a wrapped function call that does the subsetting (would no longer require along attr on df)
or lambda could do this if given an index (but how to do custom cmq calls then?)
wouldn't this be essentially exporting the wrapper function in lambda?
Proposed solution:
Provide indexing function that returns both the index and a function that wraps the call around the index (this way it could be processed by e.g. purrr::pmap, clustermq::Q_rows)
lambda/wrapper should work on lists of args instead of row number (so it can be used as a wrapping function and more generalizable for other tools like purrr)
This refers to indexing as in lambda.r#L14-L19 (multiple arrays, multiple axes, index as
data.frame
).Idea:
group
)lambda
could take an index instead of thealong
argumentIssues:
along
attribute to dfclustermq::Q_rows
would not be able to call a function with the indexed object instead of the index of the objectalong
attr on df)lambda
could do this if given an index (but how to do custom cmq calls then?)wrapper
function inlambda
?Proposed solution:
purrr::pmap
,clustermq::Q_rows
)lambda/wrapper
should work on lists of args instead of row number (so it can be used as a wrapping function and more generalizable for other tools likepurrr
)lambda/wrapper:simplify
shouldn't this all be handled by the sameconstruct
call?The text was updated successfully, but these errors were encountered: