Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 6/22/2005 Posts: 87
|
Hi.
I have a Blocks chart that Bruce had created a regression channel for me well over a year ago. This channel is very important to me. I am now using Stockfinder and transfering my charts to another computer.
Bruce had created two different indicators. One without a value pointer and one with. I don't have the chart with the value pointer anymore for some reason. This allowed me to move the channel around to past price history.
I have shared the chart as "Regression_channel" and asking if I could have the value pointer added again to the channel? I added a value pointer but couldn't attach it. So I did try.
On this same note, since Blocks and Stockfinder have come a long way is their a simpler way to have this channel now?
Thank you in advance!
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
The Linear Regression Scan topic has RealCode Indicators for TeleChart style Linear Regression Channels and Moving Linear Regressions (with options to use Standard Deviation or TeleChart's LR calculations for Width). They are more efficient, but they are not designed so the end of the Linear Regression Channels adjusts to a Date Pointer or the right edge of the visible portion of the Chart.
If you right-click on your Linear Regression Channels and select Block Diagram, you will see a Max Date Line Limiter Block. One of the inputs is the Date input and is currently connected to the Bar Chart End Date. If you left-click and drag on this input (holding down the left mouse button until you have dragged it for a bit and then letting up), it should bring up a context sensitive menu. From this menu, select Link From Another Tool and then choose your Date Pointer.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 6/22/2005 Posts: 87
|
Thank you Bruce.
I am checking out the TC LR indicator you created right now. I really like the TC channel. In my first attempts of discovery of this indicator, it doesn't look like I can move it back on older price history. Is this indeed possible?
Thank you for the instructions on adding the date pointer back to the original channel. If I have any trouble achieving my goal I will come back with questions.
Thank you! (You all support your product very well)
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
I've created some Linear Regression Channels that are based on a Trimmed Price instead of the standard Price History that adjusts the end of the Linear Regression Channels to the right edge of the visible portion of the Chart.
It is not possible to save it as an Indicator in the current version of StockFinder, but you should be able to Copy and Paste the Pane from one Chart to another Chart.
You can adjust the Trimmed Price Block Diagram in the same fashion as the you did earlier for the Linear Regression Channels you had before (replace the Bar Chart End Date Block with a Date Pointer Block).
You should be able to Open the attached Chart directly into a running copy of StockFinder.Attachments: TC_LR_Channel_Visible_Chart.sfChart - 62 KB, downloaded 1,184 time(s).
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 6/22/2005 Posts: 87
|
Thank you again Bruce.
I really like how this operates. I like how I can back it up like I did with Telecharts.
Really helped me out!
|
|
Registered User Joined: 8/31/2006 Posts: 8
|
Dear, Bruce.
I am still very new to SF and still learning how to program it
I would appreciate if you would write a RealCode program to do the following:
The weights given to the importance of each bullet below are enclosed in the bracket. They should sum to 100.
- Last hour close above 21 period simple moving average (Weight=10)
- New 3 day high (Weight=15)
- Last price above 21 day simple moving average (Weight=20)
- New 3 week high (Weight=25)
- New 3 month high (Weight =30)
Thanks in advance
Sincerely
Sam Biragbara
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
QUOTE (sambro) Last hour close above 21 period simple moving average (Weight=10)
Is the 21-Period Simple Moving Average also being calculated on 1-Hour Bars?
QUOTE (sambro) New 3 day high (Weight=15)
Does the current hour need to be forming a new 3-Day High or just the current Day? Are these Calendar Days where you are comparing the current Date to the previous 2-Dates or are they rolling 6.5-Trading Hour Periods where you are comparing the last 6.5-Trading Hours to the previous 13-Trading Hours?
QUOTE (sambro) Last price above 21 day simple moving average (Weight=20)
Is this on a 1-Day Time Frame?
QUOTE (sambro) New 3 week high (Weight=25)
Does the current hour need to be forming a new 3-Week High or just the current Week? Are these Calendar Weeks where you are comparing the current Monday through Friday to the previous 2-Calendar Weeks or are they rolling 32.5-Trading Hour Periods where you are comparing the last 32.5-Trading Hours to the previous 65-Trading Hours?
QUOTE (sambro) New 3 month high (Weight =30)
Does the current hour need to be forming a new 3-Month High or just the current Month? Are these Calendar Months where you are comparing the current 1st through 31st period to the previous 2-Calendar Months or are they rolling 136.5-Trading Hour Periods where you are comparing the last 32.5-Trading Hours to the previous 273-Trading Hours?
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 8/31/2006 Posts: 8
|
Hi Bruce
The answer to your questions are marked in red
Last hour close above 21 period simple moving average (Weight=10)
Is the 21-Period Simple Moving Average also being calculated on 1-Hour Bars? (YES)
QUOTE (sambro)
New 3 day high (Weight=15)
Does the current hour need to be forming a new 3-Day High or just the current Day? Are these Calendar Days where you are comparing the current Date to the previous 2-Dates or are they rolling 6.5-Trading Hour Periods where you are comparing the last 6.5-Trading Hours to the previous 13-Trading Hours?
Just the highest high in three calender days such as price.maxhigh(3)
QUOTE (sambro)
Last price above 21 day simple moving average (Weight=20)
Is this on a 1-Day Time Frame? (yes)
QUOTE (sambro)
New 3 week high (Weight=25)
Does the current hour need to be forming a new 3-Week High or just the current Week? Are these Calendar Weeks where you are comparing the current Monday through Friday to the previous 2-Calendar Weeks or are they rolling 32.5-Trading Hour Periods where you are comparing the last 32.5-Trading Hours to the previous 65-Trading Hours?
Just the highest highest high in three calender weeks
QUOTE (sambro)
New 3 month high (Weight =30)
Does the current hour need to be forming a new 3-Month High or just the current Month? Are these Calendar Months where you are comparing the current 1st through 31st period to the previous 2-Calendar Months or are they rolling 136.5-Trading Hour Periods where you are comparing the last 32.5-Trading Hours to the previous 273-Trading Hours?
Just the highest highest high in three calender months
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
sambro,
Please try the following RealCode Indicator on a 1-Hour Chart:
Static Highs(2,2) As Single
Static AvgC21(1) As Single
Static Count(2) As Integer
Static Days(19) As Single
If isFirstBar Then
AvgC21(0) = 0
AvgC21(1) = 0
For i As Integer = 0 To 2
Count(i) = 0
For j As Integer = 0 To 2
Highs(i, j) = Single.NaN
Next
Next
For i As Integer = 0 To 19
Days(i) = 0
Next
Else If Price.DateValue.Day <> Price.DateValue(1).Day Then
Count(0) += 1
AvgC21(1) += Price.Last(1) - Days(Count(0) Mod 20)
Days(Count(0) Mod 20) = Price.Last(1)
Highs(0, 2) = System.Math.Max(Highs(0, 0), Highs(0, 1))
Highs(0, 1) = Highs(0, 0)
Highs(0, 0) = Price.High
If Price.DateValue.DayOfWeek < Price.DateValue(1).DayOfWeek Then
Count(1) += 1
Highs(1, 2) = System.Math.Max(Highs(1, 0), Highs(1, 1))
Highs(1, 1) = Highs(1, 0)
Highs(1, 0) = Price.High
End If
If Price.DateValue.Month <> Price.DateValue(1).Month Then
Count(2) += 1
Highs(2, 2) = System.Math.Max(Highs(2, 0), Highs(2, 1))
Highs(2, 1) = Highs(1, 0)
Highs(2, 0) = Price.High
End If
End If
If CurrentIndex >= 21 Then
AvgC21(0) += Price.Last - Price.Last(21)
Else
AvgC21(0) += Price.Last
End If
Highs(0, 0) = System.Math.Max(Highs(0, 0), Price.High)
Highs(1, 0) = System.Math.Max(Highs(1, 0), Price.High)
Highs(2, 0) = System.Math.Max(Highs(2, 0), Price.High)
If Count(2) >= 3 Then
Dim Weight As Integer = 0
If Price.Last > AvgC21(0) / 21 Then
Weight += 10
End If
If Highs(0, 0) > Highs(0, 2) Then
Weight += 15
End If
If Price.Last > AvgC21(1) / 20 Then
Weight += 20
End If
If Highs(1, 0) > Highs(1, 2) Then
Weight += 25
End If
If Highs(2, 0) > Highs(2, 2) Then
Weight += 30
End If
Plot = Weight
Else
Plot = Single.NaN
End If
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Guest-1 |