[R] GMM with covariance moment condicion

2010-07-02 Thread peterko
hello I have covariance stacionary proces, and i want to estimate some parameter of this proces via gmm. My problem is with write g -function. 0 order autocovariance is not problem 1 and higher order autocavariance are problem, because add order from 0 mean that I loose one observacion if I

[R] counting across leves of factors

2010-06-09 Thread peterko
I have dataframe with 17factors variables (for example every factor have 3levels) I have maybe 5000 observation. And i need to do table where is in every raw 1 of possible combination of this factors and the numbur how many time is this combination in my dataset. I wrote one code, but this is

[R] help with tapply or other apply

2010-05-02 Thread peterko
Hi, my data looks this: id forma program kod obor rocnik 1 10001 kombinovaná Matematika M1101 matematika 1 2 10002 prezenční Informatika N1801 teoretická informatika 1 3 10002 prezenční Informatika

Re: [R] help with tapply or other apply

2010-05-02 Thread peterko
Thank you Jim, it works very well. I do not need do it using tapply, but i think that it is the way. And Patrick thank you too -- View this message in context: http://r.789695.n4.nabble.com/help-with-tapply-or-other-apply-tp2122683p2122728.html Sent from the R help mailing list archive at

Re: [R] arg min ???

2009-11-26 Thread Peterko
Petr David Winsemius wrote: On Nov 25, 2009, at 9:15 AM, Peterko wrote: Is there function what aproximate vector of parameters some function to minimum ? tet={tet1,tet2} i have they starting value and i want to find the tet what minimalizing some function

[R] arg min ???

2009-11-25 Thread Peterko
Is there function what aproximate vector of parameters some function to minimum ? tet={tet1,tet2} i have they starting value and i want to find the tet what minimalizing some function of tet ? thanks -- View this message in context:

Re: [R] arg min ???

2009-11-25 Thread Peterko
vector (x_1,x_2...,x_n)` David Winsemius wrote: On Nov 25, 2009, at 9:15 AM, Peterko wrote: Is there function what aproximate vector of parameters some function to minimum ? tet={tet1,tet2} i have they starting value and i want to find the tet what minimalizing some function

[R] R. A. Fisher Test for value of periodorgam

2009-04-03 Thread Peterko
Is there in some pacakage this test? i mean that input will be only the value of periodogram, and the function will say that are significant. or is there only the way to calcule Fishers statistics W =Vi/V1 + · · · + Vm, for i =1 m and test it step by step ? thanks -- View this message in

[R] rounding problem

2009-02-27 Thread Peterko
hi i am creating some variables from same data, but somewhere is different rouding. look: P = abs(fft(d.zlato)/480)^2 hladane= sort(P,decreasing=T)[1:10]/480 pozicia=c(0,0,0,0,0) for (j in 1:5){ for (i in 2:239){ if (P[i]/480==hladane[2*j-1]){pozicia[j]=i-1}}} period=479/pozicia

Re: [R] rounding problem

2009-02-27 Thread Peterko
all.equal is what i need, many thanks to help me baptiste auguie-2 wrote: Hi, you probably want to use ?all.equal instead of == I couldn't run your example, though Hope this helps, baptiste On 27 Feb 2009, at 10:32, Peterko wrote: hi i am creating some variables from same

[R] bigest part of vector

2009-02-24 Thread Peterko
Hi, may be simle question, but a do not find it anywhere. Is there same function like max() ,but giving more results. max() give 1number-maximum I need funcion what give p bigest number. many thanks -- View this message in context:

Re: [R] Fourier Row and spectral analysis

2009-02-23 Thread Peterko
*pi*f1*t) s1-sin(2*pi*f1*t) . . . s5-sin(2*pi*f5*t) and now a can do lm(y~mean+c1+s1+c2+s2+...+s5) . Dieter Menne wrote: Peterko lanikpeter at gmail.com writes: Hello, i need to find in time serie, k=1,2,3...(how if possible) most domain frequencies and than smooth original serie

Re: [R] Fourier Row and spectral analysis

2009-02-23 Thread Peterko
Dieter Menne wrote: Peterko lanikpeter at gmail.com writes: Original serie have 225 observing, but program use only 224. the most domain frequencies are f1=1/224 f2=1/122 f3=1/74,66 f4=1/56 f5=1/24,88 When i know these frequencies a can do, new variable ,nubmers of variavle is 2

[R] Fourier Row and spectral analysis

2009-02-22 Thread Peterko
Hello, i need to find in time serie, k=1,2,3...(how if possible) most domain frequencies and than smooth original serie by Fourier row y=mean + a1*Cos(2*pi/freq*t)+b1*Sin(2*pi/freq*t)+a2.. numbers a1,b1 ... i will have from simple regresion, i need only to find k msot domain frequensies a