search for: k_2

Displaying 5 results from an estimated 5 matches for "k_2".

Did you mean: k2
2011 Sep 22
1
Error in as.vector(data) optim() / fkf()
...ly. I imagine that it has something to do with "tyield" being a matrix. Any help on explaining what's going on and how to solve this is much appreciated. Thank you, Kristian library(FKF) #loading Fast Kalman Filter package library(Matrix) # matrix exponential package K_1 = 0.1156 K_2 = 0.17 sigma_1 = 0.1896 sigma_2 = 0.2156 lambda_1 = 0 lambda_2 = -0.5316 theta_1 = 0.1513 theta_2 = 0.2055 #test data tyield <- matrix(data = rnorm(200), nrow =2, ncol =100) # defining dimensions m <- 2 # m is the number of state variables n <- 100 # is the length of the observed sample...
2011 Nov 12
1
State space model
...matrix(abs(rnorm(400)), nrow=10, ncol=40) m <- 2 # m is the number of state variables n <- ncol(x) # is the length of the observed sample d <- nrow(x) # is the number of observed variables. h <- 1/52 ## creating state space representation of 2-factor CIR model CIR2ss <- function(K_1, K_2, sigma_1, sigma_2, lambda_1, lambda_2, theta_1, theta_2, delta_0, delta_1, delta_2) { ## defining auxilary parameters, phi_11 <- sqrt((K_1+lambda_1)^2+2*sigma_1^2*delta_1) phi_21 <- sqrt((K_2+lambda_2)^2+2*sigma_2^2*delta_2) phi_12 <- K_1+lambda_1+phi_11 phi_22...
2006 Jul 24
1
Referring on the value of a counter in a loop
...answer_1.txt") Now, I would like to loop over "class", replacing the occurences of "1" in the code above successively with the integers from 1 to 78, so that I get my 78 files. (equivalent to typing: k_1<-answer[class==1] write.table(k_1, "answer_1.txt") k_2<-answer[class==2] write.table(k_2, "answer_2.txt") etc.) I have tried for (i in 1:78) k_i<-answer[class==(i)] but this only generated the variable corresponding to the last value (78) of the counter i, and not the files in between. Thanks a lot for any help or pointers in the...
2000 May 03
0
Combinatorics for nonparametric tests
...t;h") all.perm_function(n){ p_matrix(1,ncol=1) for(i in 2:n){p_pp_cbind(p,i) v_c(1:i,1:(i-1)) for(j in 2:i){v_v[-1] p_rbind(p,pp[,v[1:i]])}} p} Until now I hesitated to dwell on writing functions to generate all n!/(k!(n-k)!) k-combinations of an n-element set or more generally all n!/(k_1!k_2!...n_k!) choices of placing n objects into k boxes where box j has n_j objects. Not intending to re-invent the wheel I turn to the R community to ask if someone has already written these functions. Any help is thankfully appreciated. --- D.Trenkler --- ***************************************...
2009 Jul 23
1
[PATCH server] changes required for fedora rawhide inclusion.
...cV$ss5lm%Gu6=bWAvQ1Yrr%5XR?bBArw}45v6+`9g6AOu?39 z1>DvZf;?Ad6i3Hk^(+M?gn-Q3fE1jMVkvjLuhcBQo}@Oigdou~?-0yB6t<?)Kg4a; z(M=`_8e!-X&(QMXsfeGxtUz!$tf4T3C1T6-)s*|P>S}9~X_>|S{i0{)9wd)(&0{O; z;!H#42$Sp%$K1P$CdF~;6J5(KqKmPy+@{go<P&$Ac{+ at e(~}wU?4rpT&WKG2JG=X( zrS*pDvy093VcQxxk_26DjG<{=t+?2;XRaSk8<>k80q>B^VX)gGFSc&8Y?7rVatYOj zg5t#CtFUhcgQ2k7W)yBrTGC}g^Z2WVE=ieAadtAVqM}FU7zyr&dC8S#=UFHBX0XW+ zcZGe2lDLF$=n62Y-xWr=HPVV4tBAO*h~sWzk*ymQi)u3`X}IANJYs&b(7WoSrI;>g zjn$IG=d23_teXfbdZ{5T>q}~_MS|dx?`Seb(I`#cLpbI6P2Tu9gsUOesG!NCo-f?e z^pcX?p&r4InV%t#Y...