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
Obviously this example is a bit silly since I can just run the map and assign to self$bar afterwards.
But my real case is more complicated and multiple fields are modified and so on, and if there is a simple fix to this that would be nice, to avoid a re-write.
I am using Mirai elsewhere with success, by passing data via .args and/or ..., but have not been able to get this case working.
The text was updated successfully, but these errors were encountered:
You should think of the mirai call needing to be self-sufficient. The components are sent to a different R process. You won't have access to anything outside of the call unless you specifically pass it in.
It's good practice to keep the daemons() call separate, as you (or another user) may want to vary that each time, it shouldn't be baked into the function.
If you want async, you return a mirai_map object as above. You can collect it later e.g. using a flatmap which gives the same as the sync variant. If you just want parallel, you'd collect it inside the function before assigning to self$bar.
Hi @shikokuchuo, as requested, here's an attempt at a reprex regarding my issue mentioned over at nanonext.
It is very simplified, but roughly shows my problem:
Running the
iterate_sync
method gives:Whereas
iterate_async
:Obviously this example is a bit silly since I can just run the map and assign to
self$bar
afterwards.But my real case is more complicated and multiple fields are modified and so on, and if there is a simple fix to this that would be nice, to avoid a re-write.
I am using Mirai elsewhere with success, by passing data via
.args
and/or...
, but have not been able to get this case working.The text was updated successfully, but these errors were encountered: