Menu
Brokers
MT4 Forex Brokers
MT5 Forex brokers
PayPal Brokers
Skrill Brokers
Oil Trading Brokers
Gold Trading Brokers
Web Browser Platform
Brokers with CFD Trading
ECN Brokers
Bitcoin FX Brokers
PAMM Forex Brokers
With Cent Accounts
With High Leverage
Cryptocurrency Brokers
Forums
All threads
New threads
New posts
Trending
Search forums
What's new
New threads
New posts
Latest activity
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Reply to thread
Forums
Trading Platforms
MetaTrader Expert Advisors
PSAR EA code problem
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
[QUOTE="Enivid, post: 202554, member: 1"] Your first variant (when using comparison of 0th and 1st bars) never works because the actual PSAR switch occurs [I]on the current bar[/I] when its high or low exceeds the PSAR value. However, because you are checking your trading condition only on new bar, that PSAR reversal is always detected only on the 1st bar, which means that bar 0 and 1 both have PSAR on the same side. You would notice this yourself if you ran this backtest in visual mode. You can either ditch the new bar check or work with bars 1 and 2 (instead of 0 and 1) to detect reversals. [/QUOTE]
Insert quotes…
Verification
Post reply
Top
Bottom
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.
Accept
Learn more…