Hello, I am performing a panel model and I have an error. In fact, I would like to set up the pooling model and I have an error message. Any help>pool<plm(panel$lexportijt~ldistit+lpopit+lpopjt+lpibit+lpibjt+lpibcit+lpibcjt+langueij+histoireij+infrasij+frontiereij+simijt+enclaviit,data=panel,inde x=c("origine","annee")) Erreur dans parse(text = x) : fin d'entrée inattendu(e) dans "panel$lexportijt ~ ldistit + lpopit + lpopjt + lpibit + lpibjt + lpibcit + lpibcjt + langueij + histoireij + infrasij + frontiereij + simijt + enclaviit + + " Thanks in advance Guylaina Guylaina_nd@yahoo.fr [[alternative HTML version deleted]]
Le dimanche 16 juin 2013 ? 09:05 +0200, Guylaine NOUWOUE a ?crit :> Hello, > > I am performing a panel model and I have an error. In fact, I would like to > set up the pooling model and I have an error message. Any help > > >pool<plm(panel$lexportijt~ldistit+lpopit+lpopjt+lpibit+lpibjt+lpibcit+lpibc > jt+langueij+histoireij+infrasij+frontiereij+simijt+enclaviit,data=panel,inde > x=c("origine","annee")) > > Erreur dans parse(text = x) : > > fin d'entre inattendu(e) dans "panel$lexportijt ~ ldistit + lpopit + > lpopjt + lpibit + lpibjt + lpibcit + lpibcjt + langueij + histoireij + > infrasij + frontiereij + simijt + enclaviit + + "This is not a problem with log() at all... this is a mere syntax error. First, there is no need to repeat "panel$" since you specify a data argument. Second, I think you should add more spacing and line breaks to your code to make it readable. Finally, the real bug is that you typed "<" instead of "<-". I think you should read an introduction to the R language. This should do what you want : pool <- plm(lexportijt ~ ldistit + lpopit + lpopjt + lpibit + lpibjt + lpibcit + lpibcjt + langueij + histoireij + infrasij + frontiereij + simijt + enclaviit, data=panel, index=c("origine", "annee")) Regards
Dear Guylaine, this has nothing to do with either 'plm' or logs. The error message says it all: "fin d'entr?e inattendu(e)". Somehow, you're inputting '+' twice in the R console, so the formula is syntactically invalid. Moreover, you assign the forula through '<' instead of '<-' so that this becomes a logical operation instead of an assignment. May I suggest you break up the task to avoid confusion: first make a formula, like 'fm <- y ~ x1 + x2', check that it be a valid 'formula' object, then use it in 'plm(fm, data=mydata)' etc.. It is also best to use spacings, indentation, etc. to avoid messing things up. Best Wishes, Giovanni ######### original message ########## ------------------------------ Message: 42 Date: Sun, 16 Jun 2013 09:05:30 +0200 From: "Guylaine NOUWOUE" <guylaina_nd at yahoo.fr> To: <r-help at r-project.org> Subject: [R] Problems using log() in a plm() regression. Message-ID: <000001ce6a5f$e5b47790$b11d66b0$@fr> Content-Type: text/plain Hello, I am performing a panel model and I have an error. In fact, I would like to set up the pooling model and I have an error message. Any help>pool<plm(panel$lexportijt~ldistit+lpopit+lpopjt+lpibit+lpibjt+lpibcit+lpibcjt+langueij+histoireij+infrasij+frontiereij+simijt+enclaviit,data=panel,inde x=c("origine","annee")) Erreur dans parse(text = x) : fin d'entr?e inattendu(e) dans "panel$lexportijt ~ ldistit + lpopit + lpopjt + lpibit + lpibjt + lpibcit + lpibcjt + langueij + histoireij + infrasij + frontiereij + simijt + enclaviit + + " Thanks in advance Guylaina ########### end original message ######## ? Ai sensi del D.Lgs. 196/2003 si precisa che le informazi...{{dropped:12}}