<div dir="ltr"><div><div>Me parece que a distribuição Tweedie seria interessante para os seus dados. Um caso particular da Tweedie é a compound Poisson que é uma distribuição continua mas com massa no ponto zero, exatamente como os seus dados se apresentam.<br></div>Não tenho certeza mas talvez vc tenha observações dependentes dentro de ANIMAL ou mesmo um efeito longitudinal no tempo seria interessante considerar isso também. O pacote tweedie faz inferencia por verossimilhança usando a função glm tradicional do R é só mudar a familia. O pacote cpglm é especifico para compound Poisson e permite a inclusão de efeitos aleatórios. Além disso, eu tenho funções que estimam o Tweedie iid por verossimilhança e Estimating Functions nesse link.<br><br><a href="http://www.leg.ufpr.br/doku.php/publications:papercompanions:tweedie">http://www.leg.ufpr.br/doku.php/publications:papercompanions:tweedie</a><br><br></div>Existe a possibilidade de incluir dependencia em modelos Tweedie especificados marginalmente.Se tiver interesse nesta possibilidade me manda um e-mail que te encaminho um paper que acabei de submeter com a metodologia de como fazer isso, usando covariance linear models. Vc parece apenas estar interessado na resposta NEFA, mas caso tenha mais que uma resposta existe tbm a possibilidade de fazer o modelo multivariado, incluindo efeito de ANIMAL e tbm TEMPO se for necessário.<br><div><br><a href="http://www.r-bloggers.com/a-note-on-tweedie/">http://www.r-bloggers.com/a-note-on-tweedie/</a><br><br><a href="http://cran.r-project.org/web/packages/tweedie/tweedie.pdf">http://cran.r-project.org/web/packages/tweedie/tweedie.pdf</a><br><br><a href="http://cran.r-project.org/web/packages/cplm/cplm.pdf">http://cran.r-project.org/web/packages/cplm/cplm.pdf</a><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">Em 10 de abril de 2015 22:34, Fernando Antonio de souza <span dir="ltr"><<a href="mailto:nandodesouza@gmail.com" target="_blank">nandodesouza@gmail.com</a>></span> escreveu:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Caros amigos<br><br></div>Tenho os seguintes dados abaixo. Desejo avaliar a resposta NEFA em função dos fatores TRATAMENTO E TEMPO. Acontece que a  variável NEFA possui muitos zeros, os quais são também respostas. Gostaria de sugestões de como posso analisar tal tipo de dado.<br><br></div>att<br><div><div><div><br>dados<-structure(list(ANIMAL = structure(c(13L, 13L, 13L, 13L, 13L, <br>13L, 13L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 3L, 3L, 3L, 3L, 3L, 3L, <br>3L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 5L, 5L, 5L, 5L, 5L, 5L, <br>5L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 12L, 12L, 12L, 12L, 12L, 12L, <br>12L, 16L, 16L, 16L, 16L, 16L, 16L, 16L, 8L, 8L, 8L, 8L, 8L, 8L, <br>8L, 20L, 20L, 20L, 20L, 20L, 20L, 20L, 15L, 15L, 15L, 15L, 15L, <br>15L, 15L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 7L, 7L, 7L, 7L, <br>7L, 7L, 7L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 18L, 18L, 18L, 18L, 18L, <br>18L, 18L, 19L, 19L, 19L, 19L, 19L, 19L, 19L, 11L, 11L, 11L, 11L, <br>11L, 11L, 11L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 17L, 17L, 17L, 17L, <br>17L, 17L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = c("20", "18", "3", <br>"2", "5", "6", "13", "9", "14", "4", "17", "7", "1", "12", "11", <br>"8", "19", "15", "16", "10"), class = c("ordered", "factor")), <br>    TRATAMENTO = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, <br>    1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, <br>    1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, <br>    2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, <br>    2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, <br>    2L, 2L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, <br>    3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, <br>    3L, 3L, 3L, 3L, 3L, 3L, 3L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, <br>    4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, <br>    4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L), .Label = c("0.146", <br>    "0.154", "0.182", "0.214"), class = "factor"), TEMPO = structure(c(1L, <br>    2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, <br>    3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, <br>    4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, <br>    5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, <br>    6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, <br>    7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, <br>    1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, <br>    2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 1L, 2L, <br>    3L, 4L, 5L, 6L, 7L, 1L, 2L, 3L, 4L, 5L, 6L, 1L, 2L, 3L, 4L, <br>    5L, 6L), .Label = c("0", "6", "12", "24", "36", "60", "84"<br>    ), class = "factor"), NEFA = c(0.28762, 0, 0, 0, 0.0344, <br>    0, 0, 0.12422, 0, 0, 0, 0.00382, 0, 0, 0.08313, 0, 0, 0, <br>    0.00192, 0, 0, 0.2064, 0, 0, 0, 0.02007, 0, 0, 0.16244, 0, <br>    0, 0, 0, 0, 0, 0.16626, 0, 0, 0, 0.08982, 0, 0, 0.23602, <br>    0.01242, 0, 0, 0, 0, 0, 0.5179, 0, 0, 0, 0, 0, 0, 0.18728, <br>    0, 0, 0, 0.0086, 0, 0, 0.71283, 0, 0, 0, 0.00764, 0, 0, 0.30386, <br>    0, 0, 0, 0.0086, 0, 0, 0.2943, 0, 0, 0, 0.01911, 0, 0, 0.17009, <br>    0.0258, 0, 0, 0, 0, 0, 0.20066, 0, 0, 0, 0, 0, 0, 0.5781, <br>    0, 0, 0, 0.01338, 0, 0, 0.5867, 0, 0, 0, 0.01624, 0, 0, 0.23315, <br>    0, 0, 0, 0, 0, 0, 0.06211, 0, 0, 0, 0, 0, 0, 0.54083, 0, <br>    0, 0, 0.01816, 0, 0.05638, 0.05829, 0, 0, 0.02484, 0)), .Names = c("ANIMAL", <br>"TRATAMENTO", "TEMPO", "NEFA"), class = c("nffGroupedData", "nfGroupedData", <br>"groupedData", "data.frame"), row.names = c(1L, 2L, 3L, 4L, 5L, <br>6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, <br>19L, 20L, 21L, 22L, 23L, 24L, 25L, 26L, 27L, 28L, 29L, 30L, 31L, <br>32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 41L, 42L, 43L, 44L, <br>45L, 46L, 47L, 48L, 49L, 50L, 51L, 52L, 53L, 54L, 55L, 56L, 57L, <br>58L, 59L, 60L, 61L, 62L, 63L, 64L, 65L, 66L, 67L, 68L, 69L, 70L, <br>71L, 72L, 73L, 74L, 75L, 76L, 77L, 78L, 79L, 80L, 81L, 82L, 83L, <br>84L, 85L, 86L, 87L, 88L, 89L, 90L, 91L, 92L, 93L, 94L, 95L, 96L, <br>97L, 98L, 99L, 100L, 101L, 102L, 103L, 104L, 105L, 106L, 107L, <br>108L, 109L, 110L, 111L, 112L, 113L, 114L, 115L, 116L, 117L, 118L, <br>119L, 120L, 121L, 122L, 123L, 124L, 125L, 126L, 127L, 128L, 129L, <br>130L, 131L, 132L, 134L, 135L, 136L, 137L, 138L, 139L), formula = NEFA ~ <br>    TEMPO | ANIMAL, FUN = function (x) <br>max(x, na.rm = TRUE), order.groups = TRUE, na.action = structure(c(133L, <br>140L), .Names = c("133", "140"), class = "omit"))<span class="HOEnZb"><font color="#888888"><br clear="all"><br>-- <br><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr">=======================================================================<br>Fernando Souza<br>Zootecnista, DSc. Produção Animal<br>celular: <a href="tel:%28%2B55%29%2082%208113-8781" value="+558281138781" target="_blank">(+55) 82 8113-8781</a><br><a href="mailto:e-mail%3Anandodesouza@gmail.com" target="_blank">e-mail:nandodesouza@gmail.com</a><br><a href="https://producaoanimalcomr.wordpress.com/" target="_blank">https://producaoanimalcomr.wordpress.com/</a><br>========================================================================<br></div></div></div></div></div></div>
</font></span></div></div></div></div>
<br>_______________________________________________<br>
R-br mailing list<br>
<a href="mailto:R-br@listas.c3sl.ufpr.br">R-br@listas.c3sl.ufpr.br</a><br>
<a href="https://listas.inf.ufpr.br/cgi-bin/mailman/listinfo/r-br" target="_blank">https://listas.inf.ufpr.br/cgi-bin/mailman/listinfo/r-br</a><br>
Leia o guia de postagem (<a href="http://www.leg.ufpr.br/r-br-guia" target="_blank">http://www.leg.ufpr.br/r-br-guia</a>) e forneça código mínimo reproduzível.<br></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Wagner Hugo Bonat<br>----------------------------------------------------------------------------------------------<br>Department of Mathematics and Computer Science (IMADA)<br>University of Southern Denmark (SDU) and<br>Laboratório de Estatística e Geoinformação (LEG)<br>Universidade Federal do Paraná (UFPR)<br><br></div></div></div></div></div>
</div>