Need help for building a history file .

MPTM's new home
juniorlcq93
Trader
Posts: 18
Joined: Sun Dec 22, 2013 9:13 am

Need help for building a history file .

Post by juniorlcq93 »

milanese » Sun Apr 27, 2014 10:48 pm wrote:
juniorlcq93 » Sun Apr 27, 2014 1:12 pm wrote:
so can I say tick volume is actually my Total Volume ??
Spread = difference from bid and ask price ?? Means it is not 0 Integer then ??? I had to use MarketInfo to get bid and ask price minus ?
for spread you can use this:

Code: Select all

 spread=MarketInfo(Symbol(),MODE_SPREAD);
Cheers :)

Tommaso

What about the real volume ???? I checked and it says iVolume returns tick volume value from the specific bars ...
User avatar
milanese
TechAdmin
Posts: 3293
Joined: Wed Jan 09, 2013 9:02 am
Location: btr rdx, r8 +

Need help for building a history file .

Post by milanese »

juniorlcq93 » Sun Apr 27, 2014 3:38 pm wrote:
What about the real volume ???? I checked and it says iVolume returns tick volume value from the specific bars ...
Empty4 counts only ticks, there are no real volume data, it is always a tick count..

Cheers :)

Tommaso
Global Prime is the official SHF broker :yahoo:
Searching for Servers and Workstations with individual configuration?
Just PM
:smile: Click here to go to the BoardKnowledgeBase
NOTE: Cookies and JavaScript are required for the using the board, with full functionality
juniorlcq93
Trader
Posts: 18
Joined: Sun Dec 22, 2013 9:13 am

Need help for building a history file .

Post by juniorlcq93 »

So can I leave real volume as 0 then ???


Also about the MODE_SPREAD , I make TotalSpread as an Integer type , then below the 2nd for loop its TotalSpread += MarketInfo ( List[y] , MODE_SPREAD ) ;

And below I use FileWriteInteger ( Data , TotalSpread , INT_VALUE ) .

There's an error in the TotalSpread += ( possible loss of data due to type of conversion ) .


I read about MODE_SPREAD it seems to give back the value of spread in terms of points , which would be a Double type . When I tried making it into a double type then everything goes wrong , my chart will look like this .


Screen Shot 04-27-14 at 11.57 PM.PNG
You do not have the required permissions to view the files attached to this post.
User avatar
milanese
TechAdmin
Posts: 3293
Joined: Wed Jan 09, 2013 9:02 am
Location: btr rdx, r8 +

Need help for building a history file .

Post by milanese »

juniorlcq93 » Sun Apr 27, 2014 3:58 pm wrote:So can I leave real volume as 0 then ???

Also about the MODE_SPREAD , I make TotalSpread as an Integer type , then below the 2nd for loop its TotalSpread += MarketInfo ( List[y] , MODE_SPREAD ) ;

And below I use FileWriteInteger ( Data , TotalSpread , INT_VALUE ) .

There's an error in the TotalSpread += ( possible loss of data due to type of conversion ) .

I read about MODE_SPREAD it seems to give back the value of spread in terms of points , which would be a Double type . When I tried making it into a double type then everything goes wrong , my chart will look like this .
it is integer as points are always integer.. pips could be double

Cheers :)

Tommaso
Global Prime is the official SHF broker :yahoo:
Searching for Servers and Workstations with individual configuration?
Just PM
:smile: Click here to go to the BoardKnowledgeBase
NOTE: Cookies and JavaScript are required for the using the board, with full functionality
juniorlcq93
Trader
Posts: 18
Joined: Sun Dec 22, 2013 9:13 am

Need help for building a history file .

Post by juniorlcq93 »

milanese » Mon Apr 28, 2014 12:05 am wrote:
juniorlcq93 » Sun Apr 27, 2014 3:58 pm wrote:So can I leave real volume as 0 then ???

Also about the MODE_SPREAD , I make TotalSpread as an Integer type , then below the 2nd for loop its TotalSpread += MarketInfo ( List[y] , MODE_SPREAD ) ;

And below I use FileWriteInteger ( Data , TotalSpread , INT_VALUE ) .

There's an error in the TotalSpread += ( possible loss of data due to type of conversion ) .

I read about MODE_SPREAD it seems to give back the value of spread in terms of points , which would be a Double type . When I tried making it into a double type then everything goes wrong , my chart will look like this .
it is integer as points are always integer.. pips could be double

Cheers :)

Tommaso





Okay I get it now , points are 1/10 of a pip . I shall test the EA tomorrow and see whether the offline charts will move like a online chart a not . Is it possible to convert this into an indicator ?? ( So I just need 1 open chart and can create my offline charts ) . I don't think so I need to use the OnCalculate() as I already use the OnTimer() , I tried putting the ex4 into Indicators folder but it keeps on remove itself .
Screen Shot 04-28-14 at 12.27 AM.PNG
You do not have the required permissions to view the files attached to this post.
Last edited by juniorlcq93 on Mon Apr 28, 2014 1:27 am, edited 1 time in total.
User avatar
milanese
TechAdmin
Posts: 3293
Joined: Wed Jan 09, 2013 9:02 am
Location: btr rdx, r8 +

Need help for building a history file .

Post by milanese »

juniorlcq93 » Sun Apr 27, 2014 4:07 pm wrote:
Okay I get it now , points are 1/10 of a pip . I shall test the EA tomorrow and see whether the offline charts will move like a online chart a not . Is it possible to convert this into an indicator ?? ( So I just need 1 open chart and can create my offline charts ) . I don't think so I need to use the OnCalculate() as I already use the OnTimer() , I tried putting the ex4 into Indicators folder but it keeps on remove itself .
you should rewrite it as indicator with OnCalculate() ecc, with the same code you use for the EA it can't work..

Cheers :)

Tommaso
Global Prime is the official SHF broker :yahoo:
Searching for Servers and Workstations with individual configuration?
Just PM
:smile: Click here to go to the BoardKnowledgeBase
NOTE: Cookies and JavaScript are required for the using the board, with full functionality
Post Reply

Return to “Utilities Indicators and Scripts”