Rank: Member
Groups: Registered, Registered Users Joined: 8/30/2012(UTC) Posts: 11
|
I want to create Indicator that displays a straight line but only on one candlestick which Choose by mouse (drag-drop).
Formula is very simple and I can readily write that.
a := high - low;
{Four Straight Line about
2-3 time-spans long}
high + (a /2);
high;
low;
low - (a/2)
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
If you're going to use the mouse, a formula isn't need -- just drag a "Horizontal Line" study and put it where you want it.
|
|
|
|
Rank: Member
Groups: Registered, Registered Users Joined: 8/30/2012(UTC) Posts: 11
|
I want to create a pre-defined indicator so that I can define calculations once and let other ppl also use it as they would want. There are four values (four short straight lines) and the calculation I have mentioned earlier works. Only hitch is that it creates a line chart across entire chart. I want to restrict that to only one candle at a time.
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
It is not clear what you want. Or my slight hangover might have something to do with it...
samjohn wrote:There are four values (four short straight lines) and the calculation I have mentioned earlier works. Only hitch is that it creates a line chart across entire chart.
Suggest you "fake it", by drawing lines manually on a chart, then either use SAVE AS HTML or do a SHIFT-PRTSC, paste into PAINT and save to JPG or PNG & post it (see IMGUR, below).
samjohn wrote:I want to restrict that to only one candle at a time.
Did you consider using an Expert Advisor -- the SYMBOL and/or HIGHLIGHT can mark a single bar.
samjohn wrote:{Four Straight Line about 2-3 time-spans long}
Kindly define the term, "time-span".
|
|
|
|
Rank: Member
Groups: Registered, Registered Users Joined: 8/30/2012(UTC) Posts: 11
|
jjstein wrote:It is not clear what you want. Or my slight hangover might have something to do with it...
Ok, let me spell it out!!!
Ok. In one of the TA books that I got, I read that whenever a certain candle pattern appears, you do the following
first, you compute height of one of the candle (Chosen Candle). This is very easy formula: height := (h-l);
second you halve height. Again easy! half := height / 2;
Next, draw four straight horizontal lines starting from that chosen candle as follows. length of the line is
not entirely important. Ideally, it should span across few candles).
Lines are to be drawn on
high + half
high
low
low - half
jjstein wrote:
Suggest you "fake it", by drawing lines manually on a chart, then either use SAVE AS HTML or do a SHIFT-PRTSC ...
I only want it for a short-while (3-4 days) at a time and do not need to post images. This technique is valid however
lines need to be only for a day or so and I want to pre-feed this calculation somewhere from where I can drag and drop
onto different candles as they appear.
jjstein wrote:
Did you consider using an Expert Advisor -- the SYMBOL and/or HIGHLIGHT can mark a single bar.
Highlight remains confined to the body of candle. One line will be little above candle. One line will be little below.
Remaining two will be on the candle edges. EA does colors nicely but I cannot show any computed values. Commentary
is where I have placed it for now, but ideally it should be drawn on chart.
Putting this calculations in indicator is useless because it creates a spaghetti across the price chart. :-)
jjstein wrote:
Kindly define the term, "time-span".
time-span is generic term by which I meant bars. It means all values such as hourly, daily, weekly .... etc.
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 5/13/2005(UTC) Posts: 715 Location: Midwest, USA
Was thanked: 1 time(s) in 1 post(s)
|
Given your twin requirements:
samjohn wrote:I want to create Indicator that displays a straight line but only on one candlestick which Choose by mouse (drag-drop).
samjohn wrote:
Putting this calculations in indicator is useless because it creates a spaghetti across the price chart.
I don't think this can be done in MetaStock.
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 10/29/2004(UTC) Posts: 1,394 Location: Glastonbury, CT
Was thanked: 2 time(s) in 2 post(s)
|
You cannot use the mouse to set the date for your indicator!
You need to create an input for the date then use valuewhen to get the value.
Also if you subsitute MP() in place of Height/2
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
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.