You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I have entered EURUSD in R. Calculated the model and calculated the coefficient. How do I draw the chart and align it with the kotir?
?plot ?lines ?points
By the way, you just estimated the model. The prediction is done by the predict function.
?plot ?lines ?points
By the way, you have only estimated the model. The prediction is done by the predict function.
Thank you. It's difficult for me, though. I'll give it a try.
What you wrote will draw on the history?
?plot ?lines ?points
By the way, you have only estimated the model. The prediction is done by the predict function.
I've figured it out a little bit.
I am not interested in prediction.
I have a model that I consider as an indicator something like MA. How do I draw it on the history where the model is calculated?
How do you draw it on the story on which the model was calculated?
?plot ?lines
?plot ?lines
'x' is a list, but does not have components 'x' and 'y'
Sorry, but I must be outstandingly stupid.
Try this: plot(eur[1:256], t='l')
Try it this way: plot(eur[1:256], t='l')
No questions asked. I drew it. But it's a vector.
x<-ar(eur[1:256],method="mle")
Here x is not a vector. It has a formula inside it which can be used to do calculations like in the prediction, only on history
No questions asked. I drew it. But it's a vector.
x<-ar(eur[1:256],method="mle")
Here x is not a vector. It has a formula inside it which can be used to do calculations like in prefix, only on history
The command ?ar tells us that x is a list, not a formula. So does class(x).
The str(x) command shows the contents of the object.
The fitted(x) gives NULL, but x has a resid component (residuals for the original data) - model values can still be computed: (eur[1:256]-x$resid).
Plot(eur[1:256], t='l')
Add a line of model values: lines(eur[1:256]-x$resid, col='red')
The command ?ar tells us that x is a list, not a formula. So does class(x).
The command str(x) shows the contents of the object.
fitted(x) gives NULL, but x has a resid component (residuals for raw data) - model values can still be computed: (eur[1:256]-x$resid).
Plot(eur[1:256], t='l')
Add a line of model values: lines(eur[1:256]-x$resid, col='red')
Got it! thanks.
But somehow it's surprising that we, having a formula, indirectly calculated its value. The predicate is there, the result of the fit is not.
Some kind of weird fit.
> x<-ar.ols(eur[1:256], order.max = 20, demean = TRUE)
> x
call:
ar.ols(x = eur[1:256], order.max = 20, demean = TRUE)
Coefficients:
1 2 3
0.9425 0. 1967 -0.1647
Specified order.max = 20, but only three coefficients. I understand it this way:
eur = 0.9425 + 0.1967*eur(-1) + (-0.1647)*eur(-2)
Is there supposed to be 20 members?
Apart from that I changed different parameters ar always three coefficients and they are very slightly different.
Please comment on this.