Thanks Michael and Josh, Then there is only one problem remaining and that is retrieving the currency data from oanda. Using the same syntax as the examples from the website i get this error: getSymbols("XPT/USD",src="oanda") Error in (grep("PRE", fr)[1]):(grep("PRE", fr)[2]) : NA/NaN argument Kind regards