Error: Could not find function


#1

Hello,

I'm trying to input a time series model into R, but I keep getting this error: Error: could not find function "X" when I try to run

x(t) <- .5x_(t-1)+E_(t)-.5E_(t-1)

Or sometimes I get the Unexpected Input error if I try to do the parentheses in a different way.

I've had to input a time series model before and it worked fine, but it's not wanting to this time.

If anyone can help, I would really appreciate it.


#2

can you give more of your code? Maybe even give a reproducible example?

x(t) <- syntax is not something I would expect just glancing at the very small piece you gave.

for example:

> x(t) <- 'bob'
Error in x(t) <- "bob" : could not find function "x<-"
> 

#3

That's the only portion of the code so far. I need it to recognize the model as a function so I can find the acf and pacf