search for: vect2

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

Did you mean: vect
2006 Jul 04
1
Problems when computing the 1rst derivative of mixtures of densities
...t distribution). To determine the maximum likelihood estimator I use the Newton-Rapdon Iteration. But when computing the first derivative I get a none linear function (with several asymptotes) which is completely absurd. This is my function to compute the first derivative: phy=function(teta,vect1,vect2){ return( sum(( vect2 - vect1) / (( 1 - teta) * vect1 + teta * vect2))) } note: vect1 and vect2 contains values of the two distributions computed from sample previously extracted. Beside, vect2 - vect1 is constant and ( 1 - teta) * vect1 + teta * vect2) is linear and always defined so I am...
2011 Mar 29
3
Reversing order of vector
Dear R helpers Suppose I have a vector as vect1 = as.character(c("ABC", "XYZ", "LMN", "DEF")) > vect1 [1] "ABC" "XYZ" "LMN" "DEF" I want to reverse the order of this vector as vect2 = c("DEF", "LMN", "XYZ", "ABC") Kindly guide Regards Vincy [[alternative HTML version deleted]]
2008 Nov 18
4
How do I generate multiple (similar) objects within R?
Hi, I wonder if anyone knows how to generate a list of objects, e.g. ten vectors with names: vect1, vect2, ... , vect10. My own idea was to use something like: for (i in 1:10) print(paste("vect", i,"<-NULL",sep="")) but the result is: "vect1<-NULL" ... "vect10<-NULL" and not vect1<-NULL ... vect10<-NULL as I would like. Does...
2011 Mar 15
2
Matching two vectors
...s Suppose I have a vector as vect_1 = c("AAA", "AA", "A", "BBB", "BB", "B", "CCC") vect_1_id = c(1:length(vect_1)) Through some process I obtain vect_2_id = c(2, 3, 7), then I need a new vector say vect_2 which will give me vect2 = ("AA", "A", "CCC")  i.e. I need the subset of vect_1 as per vect_2_id. Thanking in advance Regards Vincy [[alternative HTML version deleted]]
2009 Sep 01
3
data frame
HI, R user, I generate the vectors with the same length. I want to put each vector into each column of data frame. Why it doesnt work`? rm<-data.frame() for(a in 1:6){ rm[,a]<-getmeasure(p1,a,speech) } thanks a lot Tammy _________________________________________________________________ Share your memories online with anyone you want.