File: hanning.window.Rd

package info (click to toggle)
r-cran-e1071 1.7-3-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,184 kB
  • sloc: cpp: 2,770; ansic: 1,022; sh: 4; makefile: 2
file content (38 lines) | stat: -rwxr-xr-x 787 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
\name{hanning.window}

\title{Computes the Coefficients of a Hanning Window.}

\usage{hanning.window(n)}

\alias{hanning.window}


\arguments{
\item{n}{The length of the window.}
}

\description{The filter coefficients \eqn{w_i}{w(i)} of a Hanning
window of length 
\code{n} are computed according to the formula
\deqn{w_i = 0.5 - 0.5 \cos\frac{2\pi i}{n-1}}{
w(i) = 0.5 - 0.5*cos(2*pi*i/(n-1))}
}

\value{A vector containing the filter coefficients.}

\references{For a definition of the Hanning window, see for example\cr
Alan V. Oppenheim and Roland W. Schafer: "Discrete-Time Signal
Processing", Prentice-Hall, 1989.}

\author{Andreas Weingessel}

\seealso{stft, hamming.window}

\examples{hanning.window(10)

x<-rnorm(500)
y<-stft(x, wtype="hanning.window")
plot(y)
}

\keyword{ts}