Working with financial data in R