Welcome to the Traders Laboratory Forums.
Trading Indicators Post your custom trading indicators. If you download, remember to click INSTALL.

Reply
Bar Numbering Details »»
Bar Numbering
Platform: EasyLanguage, by Tams Tams is offline
Developer Last Online: May 2012 Show Printable Version Email this Page

Platform: MultiCharts Rating: (1 votes - 5.00 average)
Released: 05-13-2009 Last Update: Never Installs: 4
Re-useable Code Translations Is in Beta Stage  
No support by the author.

Bar Numbering

This indicator is for MultiCharts only.

description: prints the bar number on the screen,
with the option to bold, frame or reverse at specific intervals.

you may apply the numbers to a subchart, or the main chart.

if you want the bar numbers on the main chart:
-- right click on the price scale to select this indicator,
-- drag the price scale to position the numbers


Download Now

File Type: txt Bar_numbering.txt (1.3 KB, 80 views)
File Type: pla Bar_Numbering_(MultiCharts).pla (4.2 KB, 61 views)

Screenshots

Bar Numbering-bar_numbering.gif  

Show Your Support

  • If you like to thanks you by the author -> Click Thanks to the Author
  • This modification may not be copied, reproduced or published elsewhere without the author's permission.
The Following 2 Users Say Thank You to Tams For This Useful Post:
aaa (05-13-2009), TIKITRADER (12-14-2009)

Comments
Old 05-14-2009, 11:48 AM   #10
zdo

Join Date: Nov 2007
Location: boonies
Posts: 1,349
Ignore this user

Thanks: 317
Thanked 355 Times in 256 Posts
Blog Entries: 104

Re: Bar Numbering

Tams,
re "you can paste it in TS and see what's holding it up."
Thanks. Will do... just have been pressed for time lately...
zdo is offline  
Reply With Quote
Old 05-30-2009, 01:30 PM   #11
aaa

aaa's Avatar

Join Date: Jun 2008
Location: Switzerland
Posts: 443
Ignore this user

Thanks: 240
Thanked 283 Times in 136 Posts

Re: Bar Numbering

-------------------------------

Last edited by aaa; 05-30-2009 at 01:37 PM.
aaa is offline  
Reply With Quote
Old 05-30-2009, 01:37 PM   #12
aaa

aaa's Avatar

Join Date: Jun 2008
Location: Switzerland
Posts: 443
Ignore this user

Thanks: 240
Thanked 283 Times in 136 Posts

Re: Bar Numbering

I've started to adapt this indicator to compute the numbers of bars from a fixed time and date to the LastBarOnChart

inputs:
BeginTime ( 0800 ),
BeginDate ( 1090527 );

variables:
bar_num ( 0 ),
LengthBeginTime( 0 );

if Time > BeginTime then
begin
if bar_num = 0 then
bar_num = 1 ;
end
else
bar_num = 0 ;

if bar_num > 0 then
begin
bar_num = bar_num + 1 ;
end;

LengthBeginTime = bar_num ;

Now I have a problem to set BeginDate ( 1090527 )

How to go back in a specified date before ?

Is it possible ?

Any suggestion is welcomed.
aaa is offline  
Reply With Quote
Old 05-30-2009, 09:33 PM   #13

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,774
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Bar Numbering

Date

Returns a numerical value indicating the closing date of a bar.

The date is indicated in the YYYMMdd format,
where YYY is the number of years since 1900,
MM is the month,
and dd is the day of the month.


Usage

Date


Examples

Date will return a value of 1071030 for October 30th, 2007

Date will return a value of 990402 for April 2th, 1999
Tams is offline  
Reply With Quote
Old 05-30-2009, 09:37 PM   #14

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,774
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Bar Numbering

e.g.


input:
start.date(1090527);

if date > start.date then
begin

code
code
...
Tams is offline  
Reply With Quote
Old 05-31-2009, 05:31 AM   #15
aaa

aaa's Avatar

Join Date: Jun 2008
Location: Switzerland
Posts: 443
Ignore this user

Thanks: 240
Thanked 283 Times in 136 Posts

Re: Bar Numbering

Grrr... always forgotten to join a graph....

How to compute the numbers of bars from a fixed time and date to the LastBarOnChart ?

I've started from your code and here is the result

Is it the right way ?

Code:
Input:	
start.date(	1090526),
start_time(	1500	), 
color(		black	), 
text.size(	8	);
 
var:	
bar_num(	0), 
id_txt(	0);

if Time > start_time and date > start.date then 
begin
	if bar_num = 0 then bar_num = 1;
end
else bar_num = 0;

if bar_num > 0 then 
begin
	id_txt = text_new_self( d, time[1], 0, text(bar_num:0:0) );
		text_setcolor(id_txt, color     );
		text_setsize( id_txt, text.size );
	bar_num = bar_num + 1;
end;
Attached Thumbnails
Bar Numbering-snap1.jpg  
aaa is offline  
Reply With Quote
Old 06-06-2009, 04:18 AM   #16
aaa

aaa's Avatar

Join Date: Jun 2008
Location: Switzerland
Posts: 443
Ignore this user

Thanks: 240
Thanked 283 Times in 136 Posts

Re: Bar Numbering

In navigator/studies/functions/BarNumber

BarNumber = BarNumber[1] + 1 ;

I'm wondering if it is possible to count bars from a date before

May be a trick is a solution ?
aaa is offline  
Reply With Quote
Old 06-06-2009, 08:40 AM   #17

Tams's Avatar

Join Date: Sep 2008
Location: Geelong
Posts: 3,774
Ignore this user

Thanks: 2,084
Thanked 1,474 Times in 912 Posts

Re: Bar Numbering

Quote:
Originally Posted by aaa »
In navigator/studies/functions/BarNumber
BarNumber = BarNumber[1] + 1 ;
I'm wondering if it is possible to count bars from a date before
May be a trick is a solution ?

you can make the indicator to start counting anytime you want.

right now the trigger is time/date based:

if Time > start_time and date > start.date then begin


you can change it to:

if marketposition <> 0 then begin
Tams is offline  
Reply With Quote

Reply

Tags
bar number, easylanguage, multicharts, text

Thread Tools
Help Others By Rating This Thread
Help Others By Rating This Thread:


All times are GMT -4. The time now is 04:28 PM.
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
CS to VB integration by DeskLancer
©2006-2011 Traders Laboratory, All Rights Reserved.