Download software Tutorial videos
Subscription & data-feed pricing Class schedule


New account application Trading resources
Margin rates Stock & option commissions

Attention: Discussion forums are read-only for extended maintenance until further notice.
Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

Close price with SinceTrue as reference Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
geolinas
Posted : Saturday, November 10, 2018 7:35:25 AM
Registered User
Joined: 5/28/2014
Posts: 26

Hi. I want to make a formula something like this. C(SinceTrue(c>avgc10)). 

I get error when I run this. How can do this in a different way?  Thanks in advance. 

StockGuy
Posted : Saturday, November 10, 2018 9:44:44 AM

Administration

Joined: 9/30/2004
Posts: 9,187

That's not a valid formula.  I see you're trying to find the price of the bar when the condition was last true, but that's not possible.

Bruce_L
Posted : Thursday, November 15, 2018 10:06:02 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The only way to do this currently is to check each bar using something like nested IIF() functions.

IIF(C > AVGC10, C, IIF(C1 > AVGC10.1, C1, IIF(C2 > AVGC10.2, C2, 1 / 0)))

That only checks for 3 bars, but you could extend it to as many bars as you want (limited by the data available in the time frame in which it is being used).



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
geolinas
Posted : Saturday, November 17, 2018 5:12:05 PM
Registered User
Joined: 5/28/2014
Posts: 26

Thanks Bruce! Cool answer!

Bruce_L
Posted : Monday, November 19, 2018 8:16:02 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

You're welcome.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Users browsing this topic
Guest-1

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.