[R] How to draw frequency domain plot with xts time series data
Joshua Ulrich
josh.m.ulrich at gmail.com
Tue Dec 18 17:44:44 CET 2012
Cross-posted on Stackoverflow:
http://stackoverflow.com/q/13935782/271616
--
Joshua Ulrich | about.me/joshuaulrich
FOSS Trading | www.fosstrading.com
On Tue, Dec 18, 2012 at 7:59 AM, 박상규 <birdfire94 at naver.com> wrote:
> Hello,
>
>
> I'd like to convert the below time-series data with fft or wavelet related function and plot it.
> Could you let me know
> 1. How to convert xts data frame format to list format ?
> 2. How to plot fft or wavelet diagram ?
>
>
> Here is the data :
>
>
>
> > class(zc)
> [1] "xts" "zoo"
>
>
> > str(zc)
> An ‘xts’ object from (10/15/12 09:00:00) to (10/15/12 15:15:00) containing:
> Data: num [1:366, 1] 252 253 253 253 253 ...
> - attr(*, "dimnames")=List of 2
> ..$ : NULL
> ..$ : chr "Close"
> Indexed by objects of class: [chron,dates,times] TZ:
> xts Attributes:
> List of 2
> $ tclass: chr [1:3] "chron" "dates" "times"
> $ tzone : chr ""
>
>
>
> head(zc)
>
> > head(zc)
> Close
> (10/15/12 09:00:00) 252.40
> (10/15/12 09:01:00) 253.10
> (10/15/12 09:02:00) 253.15
> (10/15/12 09:03:00) 253.30
> (10/15/12 09:04:00) 253.25
> (10/15/12 09:05:00) 253.45
>
>
> Thanks in advance,
> SK Park
>
>
>
>
> [[alternative HTML version deleted]]
>
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
More information about the R-help
mailing list