montaBasico <- function()
{
basico = read.csv(".././dados/agregados/rj/Basico_RJ_RiodeJaneiro.csv", ";", header=TRUE, dec=",")
H_Idades = read.csv(".././dados/agregados/rj/hIdades_RiodeJaneiro.csv", ";", header=TRUE, dec=",")
M_Idades = read.csv(".././dados/agregados/rj/mIdades_RiodeJaneiro.csv", ";", header=TRUE, dec=",")
H_Idades = H_Idades[,c(1,3,106:107)]
colnames(H_Idades) = c("Cod_setor", "HResidentes", "HIdadeMedia", "HIdadeVar")
M_Idades = M_Idades[,c(1,3,106:107)]
colnames(M_Idades) = c("Cod_setor", "MResidentes", "MIdadeMedia", "MIdadeVar")
m <- merge(basico,H_Idades, by= "Cod_setor")
m <- merge(m,M_Idades, by= "Cod_setor")
colnames(m)[21] = "Domicilios"
colnames(m)[23] = "RendaMedia"
colnames(m)[24] = "RendaVar"
m <- merge(m, mapaSetores@data, by.x="Cod_setor" , by.y="CD_GEOCODI" )
return(m)
}
--
You received this message because you are subscribed to a topic in the Google Groups "Shiny - Web Framework for R" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/shiny-discuss/P5fXDZvIObg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to shiny-discus...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
read.table did the job :)Joao
--
You received this message because you are subscribed to the Google Groups "Shiny - Web Framework for R" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shiny-discus...@googlegroups.com.