[R-br] Erro: estouro da pilha de contexto (O que fazer?)
Alexandre Loures
alexandre.loures em ymail.com
Sexta Abril 25 20:17:23 BRT 2014
Boa noite!
Estou usando a rotina abaixo para construir uma dummy para as fronteiras
dos estados brasileiros. Porém, quando tendo rodar o R reporta o
seguinte erro:
Erro: estouro da pilha de contexto na linha 18
O que devo fazer?
mydata$contiguity<-ifelse((origin=="ac") & (destination=="am"),1,
ifelse((origin=="am") & (destination=="ro"),1,ifelse((origin=="am") &
(destination=="rr"),1,ifelse((origin=="am") &
(destination=="pa"),1,ifelse((origin=="am") & (destination=="mt"),1,
ifelse((origin=="ro") & (destination=="mt"),1,ifelse((origin=="ro") &
(destination=="am"),1,
ifelse((origin=="rr") & (destination=="am"),1,ifelse((origin=="rr") &
(destination=="pa"),1,
ifelse((origin=="pa") & (destination=="mt"),1,ifelse((origin=="pa") &
(destination=="am"),1,ifelse((origin=="pa") &
(destination=="am"),1,ifelse((origin=="pa") & (destination=="rr"),1,
ifelse((origin=="pa") & (destination=="ap"),1,ifelse((origin=="pa") &
(destination=="ma"),1,ifelse((origin=="pa") &
(destination=="to"),1,ifelse((origin=="pa") & (destination=="mt"),1,
ifelse((origin=="ap") & (destination=="pa"),1,
ifelse((origin=="ma") & (destination=="pa"),1,ifelse((origin=="ma") &
(destination=="to"),1,ifelse((origin=="ma") & (destination=="pi"),1,
ifelse((origin=="pi") & (destination=="ma"),1,ifelse((origin=="pi") &
(destination=="to"),1,ifelse((origin=="pi") &
(destination=="pe"),1,ifelse((origin=="pi") & (destination=="ce"),1,
ifelse((origin=="ce") & (destination=="pi"),1,ifelse((origin=="ce") &
(destination=="pe"),1,ifelse((origin=="ce") &
(destination=="pb"),1,ifelse((origin=="ce") & (destination=="rn"),1,
ifelse((origin=="rn") & (destination=="ce"),1,ifelse((origin=="rn") &
(destination=="pb"),1,
ifelse((origin=="pb") & (destination=="rn"),1,ifelse((origin=="pb") &
(destination=="ce"),1,ifelse((origin=="pb") & (destination=="pe"),1,
ifelse((origin=="pe") & (destination=="pb"),1,ifelse((origin=="pe") &
(destination=="ce"),1,ifelse((origin=="pe") &
(destination=="pi"),1,ifelse((origin=="pe") & (destination=="ba"),1,
ifelse((origin=="pe") & (destination=="al"),1,
ifelse((origin=="al") & (destination=="pe"),1,ifelse((origin=="al") &
(destination=="ba"),1,ifelse((origin=="al") & (destination=="se"),1,
ifelse((origin=="se") & (destination=="al"),1,ifelse((origin=="se") &
(destination=="ba"),1,
ifelse((origin=="ba") & (destination=="se"),1,ifelse((origin=="ba") &
(destination=="al"),1,ifelse((origin=="ba") &
(destination=="pe"),1,ifelse((origin=="ba") & (destination=="pi"),1,
ifelse((origin=="ba") & (destination=="to"),1,ifelse((origin=="ba") &
(destination=="go"),1,ifelse((origin=="ba") &
(destination=="mg"),1,ifelse((origin=="ba") & (destination=="es"),1,
ifelse((origin=="to") & (destination=="pa"),1,ifelse((origin=="to") &
(destination=="mt"),1,ifelse((origin=="to") &
(destination=="go"),1,ifelse((origin=="to") & (destination=="ba"),1,
ifelse((origin=="to") & (destination=="pi"),1,ifelse((origin=="to") &
(destination=="ma"),1,
ifelse((origin=="mt") & (destination=="ro"),1,ifelse((origin=="mt") &
(destination=="am"),1,ifelse((origin=="mt") &
(destination=="pa"),1,ifelse((origin=="mt") & (destination=="to"),1,
ifelse((origin=="mt") & (destination=="go"),1,ifelse((origin=="mt") &
(destination=="ms"),1,
ifelse((origin=="ms") & (destination=="mt"),1,ifelse((origin=="ms") &
(destination=="go"),1,ifelse((origin=="ms") &
(destination=="mg"),1,ifelse((origin=="ms") & (destination=="sp"),1,
ifelse((origin=="ms") & (destination=="pr"),1,
ifelse((origin=="go") & (destination=="mg"),1,ifelse((origin=="go") &
(destination=="ba"),1,ifelse((origin=="go") &
(destination=="to"),1,ifelse((origin=="go") & (destination=="mt"),1,
ifelse((origin=="go") & (destination=="ms"),1,ifelse((origin=="go") &
(destination=="df"),1,
ifelse((origin=="mg") & (destination=="sp"),1,ifelse((origin=="mg") &
(destination=="rj"),1,ifelse((origin=="mg") &
(destination=="es"),1,ifelse((origin=="mg") & (destination=="ba"),1,
ifelse((origin=="mg") & (destination=="go"),1,ifelse((origin=="mg") &
(destination=="ms"),1,
ifelse((origin=="sp") & (destination=="rj"),1,ifelse((origin=="sp") &
(destination=="mg"),1,ifelse((origin=="sp") &
(destination=="ms"),1,ifelse((origin=="sp") & (destination=="pr"),1,
ifelse((origin=="rj") & (destination=="mg"),1,ifelse((origin=="rj") &
(destination=="mg"),1,ifelse((origin=="rj") & (destination=="es"),1,
ifelse((origin=="es") & (destination=="ba"),1,ifelse((origin=="es") &
(destination=="mg"),1,ifelse((origin=="es") & (destination=="rj"),1,
ifelse((origin=="pr") & (destination=="sp"),1,ifelse((origin=="pr") &
(destintaion=="sc"),1,ifelse((origin=="pr") & (destination=="ms"),1,
ifelse((origin=="sc") & (destination=="pr"),1,ifelse((origin=="sc") &
(destination=="rs"),1,
ifelse((origin=="rs") & (destination=="sc"),1,
ifelse((origin=="df") &
(destination=="go"),1,0))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
--
*Alexandre Rodrigues Loures*
-------------- Próxima Parte ----------
Um anexo em HTML foi limpo...
URL: <http://listas.inf.ufpr.br/pipermail/r-br/attachments/20140425/e6d4e11f/attachment.html>
Mais detalhes sobre a lista de discussão R-br