[amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread brianw468
Thanks "GP", but I think your latest contribution muddies the waters a bit. My understanding of the original question is that varx would always be boolean - ie 1 or 0 (True or False)whereas your example treats it as an integer variable. The issue revolves around the real question - ie is the que

[amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread sidhartha70
Thanks for your input on this chaps. Certainly cleared some fog in my head. All sorted now. --- In amibroker@yahoogroups.com, "gp_sydney" <[EMAIL PROTECTED]> wrote: > > Brian, > > As you say, it depends on what the original intention was. There are > two ways to interpret a statement like: > >

Re: [amibroker] Re: Bad Data

2008-09-19 Thread Tomasz Janeczko
Yes it is a "feature" of many sources (eSignal, IQFeed included) that they adjust end-of-day data only without touching intraday historical. That results in situation when historical daily charts don't match historical intraday. That is exactly the case for EEM. Intraday data are NOT adjusted whi

[amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread sidhartha70
In answer to your question Brian, I ended up using a loop. Seeing the power of AFL, I often find myself resisting the use of loops, but then wrestling with the neccessary code to achieve my goals without using a loop. This seems to be a problem I hit quite consistently... which is a general uncerta

Re: [amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread Graham
Generally speaking, if your variable requires a previous value of that variable to determine current value then you need to use a loop Other areas that can require looping is items such as trail stops, where a subsequent Buy true condition can reset the trail price levels to that newer bar Of cou

Re: [amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread Tomasz Janeczko
Graham, I am endlessly surprised when people say they could not found the description when it sits under F1 key. Type AMA in the AFL editor and press F1 key. == You don't need to search at all. Just press F1. So AMA *IS* described to the level of every single bit i

Re: [amibroker] Re: Recursive Boolean Expressions... Possible?

2008-09-19 Thread Graham
I stand corrected. Last time I looked at AMA that wasn't there. Yes it was a long time ago. -- Cheers Graham Kav AFL Writing Service http://www.aflwriting.com 2008/9/19 Tomasz Janeczko <[EMAIL PROTECTED]>: > Graham, > > I am endlessly surprised when people say they could not found > the descri

[amibroker] Re: StrToDateNum

2008-09-19 Thread progster01
For anyone interested, I've expanded a bit on the this topic (Finding Price on Date, given Date as a String) here: http://codefortraders.com/phpBB3/viewtopic.php?f=38&t=211

[amibroker] no IB bacfill today

2008-09-19 Thread James
Getting the feed but can't get a 1 day backfill. Anyone else having this problem?   James

[amibroker] New file uploaded to amibroker

2008-09-19 Thread amibroker
Hello, This email message is a notification to let you know that a file has been uploaded to the Files area of the amibroker group. File: /100ticks.pdf Uploaded by : cvanhaesendonck <[EMAIL PROTECTED]> Description : Different tick count AB vs TS You can access this file at the

Re: [amibroker] New file uploaded to amibroker

2008-09-19 Thread Tomasz Janeczko
You are using Interactive Brokers, don't you? Did you read http://www.amibroker.com/ib.html Specifically THIS: IB TWS streaming data are NOT* tick-by-tick, but rather 0.2-0.3 second snapshots, read this for details: http://www.interactivebrokers.com/cgi-bin/discus/board-auth.pl?file=/2/

[amibroker] Different tick count between AB and TS: which one is correct?

2008-09-19 Thread Carl Vanhaes
Hello, I switched to AB few days ago for several reasons, but mostly due to the slowness of my old tradestation 2000. I am happy I did and can only see benefits using AB (5.10). So now, during the passage time between TS towards AB (you know...re- writing all studies in AFL, it takes some time...

[amibroker] printing with oval markings bug?

2008-09-19 Thread Keith Kee
Hi, When I use the ellipse or oval markers on the chart and print an area to the right and pass the markers, amibroker compresses the area I displayed on the right side of the page and leaves empty spaces with the oval markers on the left by themselves, is this a bug? When I remove the oval marker

[amibroker] Re: New file uploaded to amibroker

2008-09-19 Thread Carl Vanhaes
Tomasz, Thank you for responding to my file upload; please see my post just after: yes I had read that IB streamin gdata are not tick-by-tick but rather 0.2-0.3 seconds. But I thought this was only true when you do a backfill, not when you had the quotes normally streaming. If however it is tr

[amibroker] String Manipulations

2008-09-19 Thread Ken Close
I have tried various constructions to achieve the following, but the code gets complex and has no good way of detecting end of string. I would like to take a series of strings, H1, H2, H3, and create lists of the elements, as such H1="SPY,500,06/04/2008"; H2="DIA,100,09/02/2008"

Re: [amibroker] Different tick count between AB and TS: which one is correct?

2008-09-19 Thread Tomasz Janeczko
Hello, http://www.amibroker.com/ib.html IB TWS streaming data are NOT* tick-by-tick, but rather 0.2-0.3 second snapshots, read this for details: http://www.interactivebrokers.com/cgi-bin/discus/board-auth.pl?file=/2/37364.html You would need to use eSignal OR IQFeed which are tick-by-t

[amibroker] Re: String Manipulations

2008-09-19 Thread Mike
Would the following (untested) code do the job? global SymList = ""; global ShrList = ""; global DatList = ""; procedure addPosition(posString) { local sym = StrExtract(posString, 0); local shr = StrExtract(posString, 1); local dat = StrExtract(posString, 2); if (StrLen(SymList) > 0) {

Re: [amibroker] String Manipulations

2008-09-19 Thread Dennis Brown
Ken, This is quite easy by using the StrExtract( list, item) function. I am doing some similar things in the AFL I am writing for the AFL Glossary project. Typing this off the top of my head to give you the basic idea: For( i=1; i < totalSymbolCount; i++ ) { list = VarGetText( "

RE: [amibroker] no IB bacfill today

2008-09-19 Thread Jerry Gress
Hello, Backfill ok this morning before markets open. See message on 9/12 from Barry ref this! Jerry Gress Stockton, Ca. _ From: amibroker@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of James Sent: Friday, September 19, 2008 7:52 AM To: amibroker@yahoogroups.com Subject

Re: [amibroker] String Manipulations

2008-09-19 Thread Dennis Brown
Ken, I should point out that this only works for a single pass of AFL. Since you are likely wanting the variables of your trades to be more persistent, they would likely be in disk files or at least in static variables. So the code given below would at least be changed to StaticVarGetTe

RE: [amibroker] printing with oval markings bug?

2008-09-19 Thread Jerry Gress
Hello, On AB 5.09 (rt) vol charts using lots of ellipses, rectangles, arrows and text tool, scrolling back through rt and after market close = no problems here. What version are you using? Perhaps video card? Try on other puter! Interesting problem. Hope this helps. Jerry Gress Sto

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Louis P.
Hi Tony, Thanks for the tips. Basically, I'd need a loop and use it on each and every bar of the array to determine the LR, right? That will slow down my computer a lot, don't you think? Thanks, Louis 2008/9/16 Tony Grimes <[EMAIL PROTECTED]> > SelectedValue takes an array ( of numbers) an

[amibroker] scroll here function

2008-09-19 Thread Mohammed
Hi All, First Sorry if my explanation not clear, I'm not sure if this function there or not, For system studying I selected my entry point in the daily chart and I would like to see what is going in in the 4 hours frame, I have to scroll by mouse in the 4 hours time frame till I got my sele

Re: [amibroker] printing with oval markings bug?

2008-09-19 Thread Keith Kee
Hi, Using the latest beta version 5.17.1 professional. 1. draw oval maker over area, say 2 screen size ago. 2. move to current screen 3. print preview shows current screen compressed to the right Problem is not scrolling, it is when you want to print the right most screen - the print preview shows

RE: [amibroker] printing with oval markings bug?

2008-09-19 Thread Jerry Gress
Ah yes, and the price bars show in print preview on right side and indicator lines show across entire page. Well I've had that problem a very long time, anybody else? To print just use a screen capture program. Jerry Gress Stockton, Ca. Ps. Did not know the problem was connected t

Re: [amibroker] printing with oval markings bug?

2008-09-19 Thread Keith Kee
thanks, will this problem be fixed and if yes when? On Fri, Sep 19, 2008 at 12:18 PM, Jerry Gress < [EMAIL PROTECTED]> wrote: >Ah yes, and the price bars show in print preview on right side and > indicator lines show across entire page. > > > > Well I've had that problem a very long time, an

[amibroker] Re: TED spread

2008-09-19 Thread Tim
Is no one watching the TED spread? --- In amibroker@yahoogroups.com, "Tim" <[EMAIL PROTECTED]> wrote: > > Hello, > Is anyone charting the TED spread? How do I create this spread as it > isn't offered as a single symbol with DTN? Thank you for any and all help. > > Kindest regards, > > Tim >

Re: [amibroker] why would someone use IO

2008-09-19 Thread Keith McCombs
Does your "simple trading Practice" use any market indicators? If so, are the market indicators a function of any numeric parameters, like smoothing period for example? If so, have you ever wondered if maybe there better values for the parameters? If so, did you try backtesting different values

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Tony Grimes
Hi Louis, A loop will work, but how slow - it depends (Speed of your computer, number of bars loaded, how many loops your using etc...). Without seeing what your actually looking for (The end result), I think you could do it with one loop, with only one pass through the loop. The speed should be O

RE: [amibroker] Re: String Manipulations

2008-09-19 Thread Ken Close
Mike: Your code concept worked perfectly, with some minor changes. Included below in case anyone wants to play with this further. Many thanks. This opened up my code project, which I will share with the list once it is fine tuned. Ken global SymList ;//= ""; global ShrList ;//= ""; global DatList

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Louis P.
Hi Tony, Thank you a lot for your response. I'm still very weak with loops. Last time experimented with one, I had to reboot my computer! :) So do you know how such a loop could work? And if I run, let's say 2 minutes bar for one year, wouldn't that be really really long to deal with? I have

RE: [amibroker] String Manipulations

2008-09-19 Thread Ken Close
Dennis: I feel I have a lot to learn from dynamic variables here (asked once before), but right now I can not make this concept work. Code below is my modifcation of your concept and it does not crash but only prints the commas between the strings. List becomes H1 on the first pass through the lo

Re: [amibroker] String Manipulations

2008-09-19 Thread Dennis Brown
Hi Ken, The problem is that you defined H1 as a regular variable and the code is looking for a static variable named H1. Therefore, the static variables are empty. For your test here, just use VarGetText(... Or make your variables into static variables: StaticVarSetText("H1", "SPY,500,06/04/

[amibroker] sending IM to gmail chat

2008-09-19 Thread murthysuresh
here is a peice of code that will do it. i am not sure if there is a better way of triggering a windows executable than alertif. if so let me know. trigger=ParamTrigger( "Want to send email", "SEnd IM"); if(trigger){ _TRACE("sending alerts"); AlertIf(True, "exec c:\\youpath\\sendIM.rb"," sending

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Tony Grimes
Louis, If your looking for the slope & difference between HHV of 20 bars & the current close, all you should need is this: Pds=20; LastHighBar = HHVBars(High, Pds); LastHighVal = HHV(High, Pds); Slope = IIf(LastHighBar,(Close - LastHighVal) / LastHighBar,0); CloseDiff = Close - Ref(Close, -Last

[amibroker] Confusing Behaviour...!!!

2008-09-19 Thread sidhartha70
Hi, I'm trying to get some code to run as fast as possible. As such I've been studying the 'Display Chart Timing' option under preferences>misc. I've noticed some behaviour that I can't explain. I hope others may be able to. Firstly I notice that when my chart requires 10,000+ bars I start to no

RE: [amibroker] String Manipulations

2008-09-19 Thread Ken Close
Dennis: Yep. Worked. Added an if to get around "," at beginning of assembled lists, and it works fine. Many thanks, Ken -Original Message- From: amibroker@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Dennis Brown Sent: Friday, September 19, 2008 5:29 PM To: amibroker@yahoogr

Re: [amibroker] Confusing Behaviour...!!!

2008-09-19 Thread Tomasz Janeczko
Please read this: http://www.amibroker.com/kb/2008/07/03/quickafl/ Best regards, Tomasz Janeczko amibroker.com - Original Message - From: "sidhartha70" <[EMAIL PROTECTED]> To: Sent: Saturday, September 20, 2008 12:50 AM Subject: [amibroker] Confusing Behaviour...!!! > Hi, > > I'm try

[amibroker] Re: Confusing Behaviour...!!!

2008-09-19 Thread sidhartha70
Thanks TJ. I do know about Quick AFL and I have read that document throughly before. But I can't see how it applies in this case with these specific examples. And I definately can't see the difference between one being inside a function or not. Can you explain? TIA --- In amibroker@yahoogroups.

[amibroker] Re: String Manipulations

2008-09-19 Thread Mike
You would also need to add the comma handling, as was done in the sample that I gave. If you wanted to combine the two approaches, you could just have the loop call the addPosition procedure, else move the addPosition procedure logic into your loop. VarSetText("H1", "SPY,500,06/04/2008"); ...

Re: [amibroker] Re: Confusing Behaviour...!!!

2008-09-19 Thread Tomasz Janeczko
BarCount is DYNAMIC, it may change with every execution. You should not think about it as a constant. It can change with zoom factor, tooltip display (uses less), interpretation, selected bar, etc, etc. Also first execution after applying indicator always uses all bars, only subsequent runs use le

Re: [amibroker] Re: Data feed from TD AMERITRADE using AMERITRADE API (2 years intraday backfill !)

2008-09-19 Thread Tomasz Janeczko
It is not economically feasible for us to support more data sources, specifically closed-source ones, as it means only time/costs spent on development/maintenance/support but revenue goes not to us, but to data vendor. Data vendors however can take our freely available PUBLIC open API (without

[amibroker] Re: why would someone use IO

2008-09-19 Thread murthysuresh
still trying to get it into my head. thanks for your points. --- In amibroker@yahoogroups.com, Keith McCombs <[EMAIL PROTECTED]> wrote: > > Does your "simple trading Practice" use any market indicators? > If so, are the market indicators a function of any numeric parameters, > like smoothing per

[amibroker] Re: Confusing Behaviour...!!!

2008-09-19 Thread sidhartha70
Tj thanks. But I just want to get this 100% clear so I don't have to come back to this again. On exactly the same chart... same settings, same zoom etc... One line of code requires 5,000 previous bars within a function structure, and outside of a function structure it requires 500. Why? It makes

[amibroker] Re: How to coding Stochastic J%?

2008-09-19 Thread cstdc5588
Hello Tomasz, could you please teach me how to coding Stochastic J% of Indicator in AB? This is a commonly used formula.Is it possible to offer and download? Please see below the indicator formula: {N:9; M1:3; M2:3} RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100; K:SMA(RSV,M1,1); D:S

Re: [amibroker] Re: Confusing Behaviour...!!!

2008-09-19 Thread Tomasz Janeczko
As written here: http://www.amibroker.com/kb/2008/07/03/quickafl/ and illustrated here: http://www.amibroker.com/gifs/barindex_small.gif BarCount is in direct relation with bar requirements. BarCount is actually number of bars visible PLUS calculated requirements. > They require 5,000 bars each.

RE: [amibroker] Re: Confusing Behaviour...!!!

2008-09-19 Thread Fred Tonetti
The simple answer . An intelligent optimizer regardless of which one will greatly reduce optimization time as unlike an exhaustive search, run time is typically not related to the number of variable value combinations. As a simple example visualize a system made up of two indicators i.e. a

Re: [amibroker] no IB bacfill today

2008-09-19 Thread Ken H
Yes but it appears to have fixed itself. --- On Sat, 20/9/08, James <[EMAIL PROTECTED]> wrote: From: James <[EMAIL PROTECTED]> Subject: [amibroker] no IB bacfill today To: amibroker@yahoogroups.com Received: Saturday, 20 September, 2008, 12:52 AM Getting the feed but can't get a 1 day bac

[amibroker] Re: How to coding Stochastic J%?

2008-09-19 Thread Barry Scarborough
This is just a guess. If you can compare the results with the program it came from try this: N=9; M1=3; M2=3; RSV =(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100; K = MA(RSV,M1); D = MA(K,M2); J = 3*K-2*D; plot(J, "Stoch J", colorred); Barry --- In amibroker@yahoogroups.com, "cstdc5588" <[EMA

[amibroker] Backtest - Portfolio Equity

2008-09-19 Thread Ara Kaloustian
Trying to use feedback from portfolio equity to control position size. Portfolio level equity obtaines its value after backtest is complete. I tried to use add to composite to accumulate portfolio equity, but it gets reset with each new ewquity ... so value is same as individual equity. How wou

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Louis P.
Hi, I need the gradient of the slope, and for each bar. This is where it is difficult... Thanks, Louis 2008/9/19 Tony Grimes <[EMAIL PROTECTED]> > Louis, > > If your looking for the slope & difference between HHV of 20 bars & the > current close, all you should need is this: > > Pds=20; > >

[amibroker] Re: How to coding Stochastic J%?

2008-09-19 Thread cstdc5588
Hi Barry, It's work! Thanks a lot. Frank --- In amibroker@yahoogroups.com, "Barry Scarborough" <[EMAIL PROTECTED]> wrote: > > This is just a guess. If you can compare the results with the program > it came from try this: > > N=9; M1=3; M2=3; > > RSV =(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,

[amibroker] Re: why would someone use IO

2008-09-19 Thread onelkm
from personal experience, having run many many walkforward tests, most systems can be optimized (curve-fit) to appear to give good results using in sample data. But ... results using out of sample data are usually poor. So, you use IO to do walkforward testing and determine if your trading syst

Re: [amibroker] Re: What is wrong?

2008-09-19 Thread Tony Grimes
What do you mean be gradient of the slope? On Fri, Sep 19, 2008 at 9:36 PM, Louis P. <[EMAIL PROTECTED]> wrote: > Hi, > > I need the gradient of the slope, and for each bar. This is where it is > difficult... > > Thanks, > > Louis > > 2008/9/19 Tony Grimes <[EMAIL PROTECTED]> > >> Louis, >>

Re: [amibroker] String Manipulations

2008-09-19 Thread Dennis Brown
Thanks Mike for pointing out that += works with strings also. Oh, yea, the comma at the beginning. I would get around that by doing the following: for( i=1; i < totalSymbolCount; i++ ) { list = StaticVarGetText( "H" + NumToStr(i, 1.0, 0)); if(i==1){comma = "";} else{comma = ","

Re: [amibroker] Re: why would someone use IO

2008-09-19 Thread Keith McCombs
For another way of saying about the same thing, see Fred's comment at 7:41pm, 9/19/08, subject: "Re: Confusing Behaviour...!!!". I guess Fred was in a hurry and accidentally posted to the wrong subject. Thankfully, his grammar and spelling are much better than mine. -- Keith murthysuresh wro

[amibroker] Re: Blau's Ergodic

2008-09-19 Thread Tim
I hope everyone got my emails that wanted the Ergodic's. Good luck with them. I don't feel quite so bad about the help I have received now that I have been able to help as well. Thank you. Warmest regards, Tim

[amibroker] Re: String Manipulations

2008-09-19 Thread tuzo_wilson
You could also take the comma calculations outside of the loop which could save some cycles. i.e. just append an extra comma to the end of the list and strip it off after the loop is done: COMMA = ","; for( i=1; i < totalSymbolCount; i++ ) { list = StaticVarGetText( "H" + NumToStr(i, 1.0, 0)

[amibroker] Settings frustration

2008-09-19 Thread Keith McCombs
I'm forever having trouble with settings in AA, because I don't want the same settings for all my AFL formulas. Some of the settings can be overridden by "SetOption()". For example "|SetOption("MinShares", 1);" in AFL code will override "Min. shares:" in AA Settings. However, as far as I kno

Re: [amibroker] Settings frustration

2008-09-19 Thread Ara Kaloustian
RoundLotSize = 5; // Just as shown here not a setOption function - Original Message - From: Keith McCombs To: amibroker@yahoogroups.com Sent: Friday, September 19, 2008 10:14 PM Subject: [amibroker] Settings frustration I'm forever having trouble with settings in AA,

[amibroker] Sir I Want to Draw the ATP in Real time chat thru AFL

2008-09-19 Thread Manikandan MS
Dear Member, Pls Help to me how can i draw in avarage trader price ( ATP ) in in my realtime chart in 3 min or 1 min or 5 min Chart..pls help or send any sample of afl also..   Thank U Manikandan.MS Unlimited freedom, unlimited storage. Get it now, on http://help.yahoo.com/l/in/yahoo/mai