R studio for accounting?


Hi I’m new to R and have been researching whether or not RStudio (and R more generally) are good tools to run a private company’s accounting and financial reporting and modeling functions. I haven’t had much luck thus far finding tutorials or packages that support these tasks. Any help/thoughts/suggestions would be greatly appreciated!



Hi Ryan,

I can’t speak to accounting in particular, but I do know there are a number of packages focused on time series analysis and forecasting. And in general, R is a great choice for custom reporting and modeling. The CRAN Task View on time series analysis may be a good place to start:


There have also been some recent threads here which might be relevant to the modeling questions:


Ryan, can you give any specific examples of what you want to get out of the accounting reporting and modeling? I imagine that R can handle it, and can imagine a number of workflows like:

Database -> R (modeling + general data munging) -> R Shiny (reporting / dashboard)

The tidyverse is a great platform for the type of data manipulation that you might do in Excel, i.e. adding multiple columns onto your data.frame that depended on other previous columns, then summarizing that data somehow. Shiny then gives you the tools to show off the results in a nice and potentially interactive way.


RStudio is excellent for analysis, including financial analysis, where you have a highly trained researcher tackling a not well defined problem - but a poor fit for general bookkeeping, where you want to follow a set of simple input tasks (following hard coded arcane rules).

Other tools are better suited for that. If you absolutely need to avoid a special bookkeeping software do consider *gasp* MS Excel. At least you will find help online, as the finance people are some of the most die hard Excel fans.


Thanks so much for your feedback Matt, Davis and Jindra, it is much appreciated. I did find a package called Finstr (https://github.com/bergant/finstr). Do you recommend any specific ways to evaluate the quality / usefulness of a given package other than just getting into it?

Davis - I think you’ve generally answered my question in terms of what I’m looking to do. I’m exploring the tidyverse now. Thanks again!


Hi Ryan I'm actually looking at doing something similar at the firm I work at. I remember using Finstr in college, mainly for optimizing portfolios, I didn't know it had tax-planning capabilities. Have you found it helpful at all for planning?