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 |

Adjustable Time Frame Indicator Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
SUBBUMEENA
Posted : Saturday, March 28, 2009 7:19:03 PM
Registered User
Joined: 9/3/2008
Posts: 12
Hi Bruce,

Can you pl help me create the following realcode indicators

I am looking to plot indicator1 and indicator2 using 1hr timeframe on a 5min chart

1) Indicator1

Variables - Period
Variables - TimeFrame

Plot = Price.Close(Period)


2) Indicator2

Variables - Period
Variables - TimeFrame

Plot = (Price.MaxHigh(Period) + Price.MinLow(Period)) / 2

I was able to create these indicators in realcode and change the time period using the
block diagram. But I am not able to save the time period settings. I have to edit
them whenever I close and open SF. I am looking for an indicator like the one you
created for the following forum request

http://www.worden.com/training/default.aspx?g=posts&t=38818  - TSV with Adjustable Time Frame.sfInd

Thanks
Subbu
Bruce_L
Posted : Monday, March 30, 2009 2:00:42 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
I've attached a Price Indictaor with a Time Frame Block connected to the Price Block. You should be able to Open an attached Indicator directly into a running copy of StockFinder (and save it from within StockFinder if desired).

You should be able to Drag and Drop the Block Diagram into the RealCode Editor to create something like the first line of the following RealCode Rule:

'# PHwT = indicator.PriceHistorywTimeFrame
'# Period = UserInput.Integer = 0
Plot = PHwT.Value(Period)

You should be able to reproduce your other Indicator using this method as well:

'# PHwT = indicator.PriceHistorywTimeFrame
'# Period = UserInput.Integer = 1
Plot = (PHwT.MaxHigh(Period) + PHwT.MinLow(Period)) / 2

It should be noted that the lowest granualarity that will be Plotted for the Indicator will be the Time Frame of the Chart. It generally works best if the Time Frame of the Price History with Time Frame Indicator is longer than the Time Frame of the Chart as a result. A Bar Offset (such as is used in the first RealCode Indicator) when the Price History with Time Frame is shorter than the Time Frame of the Chart used in a RealCode Indicator is somewhat odd.

Attachments:
Price History w Time Frame.sfInd - 4 KB, downloaded 663 time(s).



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
SUBBUMEENA
Posted : Monday, March 30, 2009 8:28:12 PM
Registered User
Joined: 9/3/2008
Posts: 12
Bruce,

Works perfectly well, thank you so much and appreciate all your help.

Subbu
Bruce_L
Posted : Tuesday, March 31, 2009 8:22:05 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.