1
Good Morning, I’m having a bug to run a code on my R.
Follow the code below.
library(car)
library(fBasics)
library(NbClust)
setwd("C:/Financas") # Salvar na pasta
Base = read.table("baseFin.txt", header=TRUE) #Importa o arquivo
head(Base)
tail(Base)
papel = Base$Papel
evebit = Base$EVEBIT
cresrec = Base$CresRec
lpa = Base$LPA
vpa = Base$VPA
margliq = Base$MargLiquida
ebitativo = Base$EBITAtivo
liqucorr = Base$LiquCorr
divbrpatr = Base$DivBrPatrim
The main purpose of these codes is to take the indicators in the database and do what is written in the code.
This is the database
That’s the mistake that shows up on my R
Error in scan(file = file, what = what, sep = sep, quote = quote, dec = dec,
:
linha 1 não tinha 14 elementos
In your first line, which you indicate as a
header = TRUE
, there is space between the words of the title of the same column. Try to put a character like_
between the words.– Willian Vieira
@Matheustostes, avoid sharing information as image. Take a look here on how to improve your next questions.
– Tomás Barcellos