search for: trinomi

Displaying 10 results from an estimated 10 matches for "trinomi".

Did you mean: tricomi
2008 Mar 05
1
Question on "assign(paste.."
Hello, I'm having trouble in using "assign(paste ..." command . I could create several dataframes following trinomial distribution using it but it could not be used to check their row means of the created dataframe. For example, the following works: probTrt=matrix(0,4,3); probTrt; #malf, death, normal probTrt[1,]=c(0.064,0.119,0.817);#for Trt 1 probTrt[2,]=c(0.053,0.125,0.823);#for Trt 2 probTrt[3,]=c(0.111,0....
2004 Oct 17
3
how to draw a multivariate function
Hi, Rusers: Thanks for answering my last questions. I am frustrated in plotting a trinomial pmf function f(x,y | n, pa, pb) = factorial(n)/ (factorial(x) * factorial(y) * factorial (n-x-y))* pa^x * pb^y * ((1-pa-pb)^(n-x-y)) obviously it is a bivariate function of x and y. But I have put a lot of time on this. ********************************** x <- seq(0, n, len = n/2+1) # for n...
2011 Oct 17
1
simultaneously maximizing two independent log likelihood functions using mle2
...gain, my goal is to simultaneously estimate parameters from the same function for two years, such that I can test if the parameters from the two years are different. Perhaps an important difference from the above example is that I am using a multinomial distribution (dmnom) because my data are trinomially distributed. Any help would be greatly appreciated. Adam Zeilinger -- Adam Zeilinger Ph. D Candidate Conservation Biology Program University of Minnesota Saint Paul, MN www.linkedin.com/in/adamzeilinger
2012 Oct 05
2
problem with convergence in mle2/optim function
Hello R Help, I am trying solve an MLE convergence problem: I would like to estimate four parameters, p1, p2, mu1, mu2, which relate to the probabilities, P1, P2, P3, of a multinomial (trinomial) distribution. I am using the mle2() function and feeding it a time series dataset composed of four columns: time point, number of successes in category 1, number of successes in category 2, and number of success in category 3. The column headers are: t, n1, n2, and n3. The mle2() function...
2012 Sep 27
0
problems with mle2 convergence and with writing gradient function
Dear R help, I am trying solve an MLE convergence problem: I would like to estimate four parameters, p1, p2, mu1, mu2, which relate to the probabilities, P1, P2, P3, of a multinomial (trinomial) distribution. I am using the mle2() function and feeding it a time series dataset composed of four columns: time point, number of successes in category 1, number of successes in category 2, and number of success in category 3. The column headers are: t, n1, n2, and n3. The mle2() function...
2017 Nov 02
2
repeat a function
Hi Petr, Many thanks for your response. Basically I want to create a probability matrix to be used in a trinomial tree going forward. This is the reason why I thought to build the matrix around 0 would be much more efficient. I need to loop through because the probabilities will depend on my node and is not always the same per row (e.g. if N> jmax, jmax being defined in another function) I found a workaro...
2017 Nov 03
0
repeat a function
...> Sent: Thursday, November 2, 2017 5:54 PM > To: PIKAL Petr <petr.pikal at precheza.cz>; r-help at r-project.org > Subject: RE: [R] repeat a function > > Hi Petr, > > Many thanks for your response. > > Basically I want to create a probability matrix to be used in a trinomial tree > going forward. This is the reason why I thought to build the matrix around 0 > would be much more efficient. I need to loop through because the probabilities > will depend on my node and is not always the same per row (e.g. if N> jmax, > jmax being defined in another functio...
2004 Jun 04
5
How to Describe R to Finance People
> the main advantage it has over SPSS-like software is that you do not > need to explicitly create dummy variables. You only need to specify > your dependent variable and independent variables and R will fit it > (and create dummy variables automatically) for you. Does the audience know exactly what the creation of dummy variables in SPSS is and means? If not, they might consider
2017 Nov 02
0
repeat a function
Hi Eric I did not see any answer and frankly speaking I cannot provide you with canned help. AFAIK if a function is defined within another function (which is your case) it cannot be called directly so it is necessary to define it in global environment. > fff <- function(x) { + myf <- function(a) a+2 + myf(x)^2} > > fff(5) [1] 49 > myf(5) Error in myf(5) : could not find
2017 Nov 01
3
repeat a function
I want to populate the matrix prb through the function HWMProb <- function (a,j,dt) that encapsulates different functions (please see code below), using j= 0:2 for each j. It only populates prb if I specify each function independently in the global environment and then run the loop with the iF statement, as per below. for (j in 0:2) { if (j==0) { prb["0","1"] <-