search for: meanv

Displaying 2 results from an estimated 2 matches for "meanv".

Did you mean: means
2006 Apr 08
1
add lines to a plot with a loop without erase the last one
...m(length(s),0,sqrt(var)) for (j in 1:(length(s))) { data[j,i]<-((alpha*s[j]) / (s[j] + beta)) + (epsilon[j]*(s[j]/(s[j] + beta))) b<-data[,i] } #print(b) X<-b[-1]/s[-1] #print(X) #print(X) #print(length(b[-1])) #print(length(X)) meanX<-mean(X) #print(meanX) meanV<-mean(b) #print(meanV) betachap[i]<-((meanX*squareproduct(b[-1],b[-1]))- (meanV*squareproduct(X,b[-1])))/((meanV*squareproduct(X,X))- (meanX*squareproduct(X,b[-1]))) alphachap[i]<-meanV + betachap[i]*meanX varchap[i]<-((squareproduct(b[-1],b[-1])) + (2*betachap[i]*squareproduct(X,b[-1]...
2006 Aug 03
1
question about dll crashing R
...o , REAL( ans ) , &nrx ) ; UNPROTECT( 1 ) ; return( ans ) ; } I am also generating random multiavriate normals using the (not pretty) code * 1) Generate P independent standard normal deviates - Ei ~ N(0,1) 2) Using Cholesky decomposition find A s.t. trans(A)*A = COVM 3) trans(A)E + MEANV ~ N(MEANV,COVM) */ SEXP mvntest (SEXP mean, SEXP cov, SEXP temp) { int nrx , ncx , nry , ncy ,info,mode; SEXP xdims , ydims , ans; int i,j, one=1; info = 1; xdims = getAttrib (mean , R_DimSymbol ) ; ydims = getAttrib (cov , R_DimSymbol ) ; mode = REALSXP; nrx = INTEGER( xdims ) [ 0 ] ; ncx = I...