#Instale o pacote quantmod
library(quantmod)
PBR<-getFinancials("PBR",src="google",auto.assign=FALSE)
write.csv(PBR$IS$A,"PBR_DRE_ANUAL.csv")
write.csv(PBR$BS$A,"PBR_BP_ANUAL.csv")
write.csv(PBR$CF$A,"PBR_FLUXOCAIXA_ANUAL.csv")
write.csv(PBR$IS$Q,"PBR_DRE_TRIMESTRE.csv")
write.csv(PBR$BS$Q,"PBR_BP_TRIMESTRE.csv")
write.csv(PBR$CF$Q,"PBR_FLUXOCAIXA_TRIMESTRAL.csv")
AAPL<-getFinancials("AAPL",src="google",auto.assign=FALSE)
write.csv(AAPL$IS$A,"AAPL_DRE_ANUAL.csv")
write.csv(AAPL$BS$A,"AAPL_BP_ANUAL.csv")
write.csv(AAPL$CF$A,"AAPL_FLUXOCAIXA_ANUAL.csv")
write.csv(AAPL$IS$Q,"AAPL_DRE_TRIMESTRE.csv")
write.csv(AAPL$BS$Q,"AAPL_BP_TRIMESTRE.csv")
write.csv(AAPL$CF$Q,"AAPL_FLUXOCAIXA_TRIMESTRAL.csv")
VALE<-getFinancials("VALE",src="google",auto.assign=FALSE)
write.csv(VALE$IS$A,"VALE_DRE_ANUAL.csv")
write.csv(VALE$BS$A,"VALE_BP_ANUAL.csv")
write.csv(VALE$CF$A,"VALE_FLUXOCAIXA_ANUAL.csv")
write.csv(VALE$IS$Q,"VALE_DRE_TRIMESTRE.csv")
write.csv(VALE$BS$Q,"VALE_BP_TRIMESTRE.csv")
write.csv(VALE$CF$Q,"VALE_FLUXOCAIXA_TRIMESTRAL.csv")
Nenhum comentário:
Postar um comentário