title: Fourier Transformation in R
body: <p>is there a simple solution to get a fourier transformation of a specific signal? I've tried it with GeneCycle but the outcome seems to be wrong.</p>
  
  <p>The signal: <a href="https://www.sendspace.com/file/bmwjvr" rel="nofollow noreferrer">https://www.sendspace.com/file/bmwjvr</a></p>
  
  <p>My code that I tried:</p>
  
  <pre><code>trajectory &lt;- testmatrix[,2]
  library(GeneCycle)
  f.data &lt;- GeneCycle::periodogram(trajectory)
  harmonics &lt;- 2:10
  plot(f.data$freq[harmonics]*length(trajectory), 
  f.data$spec[harmonics]/sum(f.data$spec), 
  xlab="Harmonics", ylab="Amplitute Density", type="h")
  </code></pre>