future 1.8.0: Preparing for a Shiny Future

April 11, 2018
By

(This article was first published on JottR on R, and kindly contributed to R-bloggers)

future 1.8.0 is available on CRAN.

This release lays the foundation for being able to capture outputs from futures, perform automated timing and memory benchmarking (profiling) on futures, and more. These features are not yet available out of the box, but thanks to this release we will be able to make some headway on many of the feature requests related to this – hopefully already by the next release.

For shiny users following Joe Cheng’s efforts on extending Shiny with asynchronous processing using futures, future 1.8.0 comes with some important updates/bug fixes that allow for consistent error handling regardless whether Shiny runs with or without futures and regardless of the future backend used. With previous versions of the future package, you would receive errors of different classes depending on which future backend was used.

The future_lapply() function was moved to the future.apply package back in January 2018. Please use that one instead, especially since the one in the future package is now formally deprecated (and produces a warning if used). In future.apply there is also a future_sapply() function and hopefully, in a not too far future, we’ll see additional futurized versions of other base R apply functions, e.g. future_vapply() and future_apply().

Finally, with this release, there was an bug fix related to nested futures (where you call future() within a future() – or use %<-% within another %<-%). When using non-standard evaluation (NSE) such as dplyr expressions in a nested future, you could get a false error that complained about not being able to identify a global variable when it actually was a column in a data.frame.

What’s next?

Help shape the future

If you find futures useful in your R-related work, please consider sharing your stories, e.g. by blogging, on Twitter, or on GitHub. It always exciting to hear about how people are using them or how they’d like to use. I know there are so many great ideas out there!

Happy futuring!

To leave a comment for the author, please follow the link and comment on their blog: JottR on R.

R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...



If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.

Search R-bloggers


Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)