[R] problem in metro_hasting function‏

2015-12-10 Thread hms Dreams
Hello, I estimated three paramters using non informative prior(all paramters following uniform distribution) the output is: Error in optim(pars, li_func, control = list(fnscale = -1), hessian = TRUE, : non-finite finite-difference value [1] How can I solve it using uniform distribution

Re: [R] problem in metro_hasting function‏

2015-12-10 Thread hms Dreams
ople keep coming along > and sticking things into it." > -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) > > > On Thu, Dec 10, 2015 at 9:26 AM, hms Dreams <cute_loo...@hotmail.com> wrote: > > Hello, > > I estimated three para

[R] estimate reliability and hazard using MOM and Baysian methods

2015-11-02 Thread hms Dreams
Hi, I estimate 3 paramters using MOM and Bayesian methods How can I estimate the reliability(R) and hazard(h) functions?? Is it correct if I estimated R and h like MLE by substitute the estimators and put any value for x in the formula of R and h?? I need help please thank you noor

Re: [R] Metro_Hastings

2015-02-19 Thread hms Dreams
Any suggestions :( ??From: cute_loo...@hotmail.com To: r-help@r-project.org Subject: Metro_Hastings I wrote my code again Date: Sun, 15 Feb 2015 21:47:25 +0300 Hi again :) I wrote my code here: library(MHadaptive) baysianlog=function (param,data) { alpha=param[1]

[R] method of moments estimation

2015-02-16 Thread hms Dreams
Hi, I'm trying to use method of moments estimation to estimate 3 unkown paramters delta,k and alpha. so I had system of 3 non linear equations: 1) [delta^(1/alpha) *gamma (k-(1/alpha)) ]/gamma(k) = xbar 2) [delta^(2/alpha) *gamma (k-(2/alpha)) ]/gamma(k) = 1/n *sum (x^2) 3) [delta^(3/alpha)

[R] Metro_Hastings I wrote my code again

2015-02-15 Thread hms Dreams
Hi again :) I wrote my code here: library(MHadaptive)baysianlog=function (param,data) { alpha=param[1] gam=param[2] delta=param[3] x=data n =length(x)

[R] help please metro_hastings function

2015-02-14 Thread hms Dreams
Hi :)anybody can help me please I'm trying to use Metro_Hastings ( MHadaptive package)the proplem is: How can I know the covariance matrix( prop_sigma ) to enter it in Metro_Hastings: mcmc_r=Metro_Hastings(li_func=baysianlog, pars=c(1,1,1), prop_sigma

[R] my code in Metro_Hastings

2015-02-14 Thread hms Dreams
Hi again :) my code is in the attachment file the problem I think in the : mcmc_r=Metro_Hastings(li_func=baysianlog, pars=c(1,1,1),par_names=c('alpha','gamma','delta'),data=x ) because I did not write the prop_sigma because I don't know how can I calcalute the covariance matrix. somebody