[R] power in a specific frequency band
gpagnon at emory.edu
Sat Oct 16 01:55:40 CEST 2004
Dear R users
I have a really simple question (hoping for a really simple answer :-):
Having estimated the spectral density of a time series "x" (heart rate
x.pgram <- spectrum(x,method="pgram")
I would like to compute the power in a specific energy band.
Assuming that frequency(x)=4 (Hz), and that I am interested in the band
between f1 and f2, is the power in the band simply the following?
sum(x.pgram$spec[(x.pgram$freq > f1/frequency(x)) & (x.pgram$freq <=
If it is so, are the returned units the same units as the original time
series, but squared (if x is bpm, then the power is in bpm^2)?
I own a copy of Venables and Ripley (MASS 2003), but I was not able to
extract this information from the time series chapter....
thanks for any help
(please cc to my e-mail, if possible)
Dept. Psychiatry and Behavioral Sciences
1639 Pierce Drive, Suite 4000
Atlanta, GA, 30322
More information about the R-help