Skip to content
Prev 6193 / 15274 Next

Existing packages for personal finance and OFX importation

On 06/05/2010 09:04 AM, S?bastien Durand wrote:
Assuming we're talking about:

http://www.ofx.net/

as identified by Dirk, this is an XML format.

RSiteSearch("OFX")

returns zero hits.

... so the first thing to try would be to use the XML package by Duncan to see 
if you can parse the DTD and and parse the files into R.

Then there will likely be some work in figuring out what you want the data 
structures to look like just for handling the input data. I would recommend 
documenting and packaging the OFX parser as a separate R package, it feels like 
a standalone package.
Packages like blotter can do this, though you'd also need to identify the 
instruments that you are having transactions on.  For 'personal finance' I 
assume that this would include things like cash (various currency balances), 
stocks, bonds, mutual funds, etc.  All of these should be easy enough to model 
in FinancialInstrument so the transactions will then make sense and add up in 
blotter.
There's not enough information on these two for me to understand what you want 
to do.  There are various methods for handling portfolio rebalancing and 
optimization in R already, and of course plenty of plotting methods.  If we're 
still talking about transactions and portfolios, blotter can handle a lot of this.
layered account/portfolio structure is handled by blotter.
Parts of it, see above.
I think the OFX part is the part not covered, but if you're lucky, Duncan's XML 
package will do most of the heavy lifting of parsing the files per the DTD and 
getting them into R.  Your work would be in sorting that into R objects for 
further manipulation, and then passing the transactions on to the blotter.