Skip to content
Prev 4709 / 15274 Next

Array to xts/zoo

Hi,

I have an array which holds the cumulative profit of a trading strategy over
time. I use raw data of class xts/zoo by using quantmod's
getSymbols("^DJI").

My question: How do I transform my array to a zoo/xts class, by also using
the date formatting in the raw data? The array shows the corresponding
profit/loss for each day of data downloaded. Both my array and the raw data
from getSymbols have the same number of elements.

Thanks in advance.
Eduard