<div dir="ltr"><p class="gmail-MsoNoSpacing">Prezad@s<span></span></p>
<p class="gmail-MsoNoSpacing">Alguma ideia de solução na seguinte dificuldade: <span></span></p>
<p class="gmail-MsoNoSpacing"><i> </i></p>
<p class="gmail-MsoNoSpacing"><i><span lang="EN-US">library(survival)<span></span></span></i></p>
<p class="gmail-MsoNoSpacing"><i><span lang="EN-US">fit <- survreg(Surv(futime, fustat) ~ rx +
age, data = ovarian, dist = "weibull")<span></span></span></i></p>
<p class="MsoNormal"><span lang="EN-US"> </span></p>
<p class="MsoNormal" style="margin-bottom:0.0001pt;background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-size:10pt;font-family:"lucida console";color:rgb(197,6,11)">Error in coxph.wtest(t(x) %*% (wt * x), c((wt * eta
+ weights * deriv$dg) %*% : object
'Ccoxph_wtest' not found</span><span lang="EN-US" style="font-size:10pt;font-family:"lucida console";color:black"><span></span></span></p>
<p class="MsoNormal"><span lang="EN-US"> </span></p>
<p class="gmail-MsoNoSpacing"><i><span lang="EN-US">fit <- survreg(Surv(futime, fustat) ~ 1,
data = ovarian, dist =
"weibull")<span></span></span></i></p>
<p class="MsoNormal">summary(fit)<span></span></p>
<pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black"><span> </span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Call:<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">survreg(formula = Surv(futime, fustat) ~ 1, data = ovarian, dist = "weibull")<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black"> Value Std. Error z p<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">(Intercept) 7.111 0.293 24.292 2.36e-130<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Log(scale) -0.103 0.254 -0.405 6.86e-01<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black"><span> </span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Scale= 0.902 <span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black"><span> </span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Weibull distribution<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Loglik(model)= -98 Loglik(intercept only)= -98<span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span lang="EN-US" style="font-family:"lucida console";color:black">Number of Newton-Raphson Iterations: 5 <span></span></span></pre><pre style="background-image:initial;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;word-break:break-all"><span style="font-family:"lucida console";color:black">n= 26 <span></span></span></pre>
<p class="MsoNormal"><span> </span></p>
<p class="MsoNormal">Ou seja, a função só funciona no ajuste do modelo sem variáveis
explanatórias. Observação: o pacote survival tem a função <span style="font-size:10pt;line-height:115%;font-family:"lucida console"">coxph.wtest(.).<span></span></span></p>
<p class="MsoNormal">Desde já agradeço<span></span></p><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><br></div><div dir="ltr"><br></div><div dir="ltr">Gilênio Borges Fernandes<div>Professor Associado IV (Aposentado)</div><div>Professor Adjunto A (Substituto)<br>Universidade Federal da Bahia<br>Instituto de Matemática e Estatística<br>Departamento de Estatística<br>Av. Adhemar de Barros, s/n – Ondina.<br>40.170-110 - Salvador - BA, Brasil<br>Tel.: (071)3283-6340/6341/6337 Fax: (071)3283-6336</div><div>Skype: gilenio.fernandes<br>Lattes: <a href="http://lattes.cnpq.br/6764860618464860" target="_blank">http://lattes.cnpq.br/6764860618464860</a><br></div></div></div></div></div></div></div></div></div></div></div></div>
</div>