[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Re: ABtool v0.0.5 beta - Bug #2 ?



PureBytes Links

Trading Reference Links

Uenal,

The columns are NOT defined in a loop, but of course rows are added 
and/or retieved in loops so that should not be an issue.  This code 
is really just what I'd call a simple test suite to see that I 
understand the functionality and that I can make it do what I want. 

I will check out the version you sent and let you know via direct 
mail what's going on.

Fred

--- In amibroker@xxxxxxxxxxxxxxx, uenal.mutlu@xxxx wrote:
> Fred,
> I unfortunately cannot reproduce this. I did some other 
modifications
> to the Table routines but am not sure if that also solves the 
problem you
> describe. The best would be, if you try the internal version which 
I've sent 
> to you via email. There is a new function which maybe will help us 
to
> pinpoint the problem. After defining your tables note the rowlength
> by calling the new function TableGetRowLen(th). And do the same also
> after filling up the tables.
> 
> If you get differing or very big numbers (it is the total length of 
each "line" (row) in bytes) 
> then  maybe you see the "rows" as going from left  to right whereas 
rows 
> are normally like lines on a sheet, ie.from top to bottom and cols 
are from left 
> to right;  much like on an excel sheet.
> Remember each number occupies 4 bytes, so you could calculate and 
verify
> the value you get.
> 
> BTW, the sorting on more than just one column is fnished too (though
> not much tested yet).
> 
> > With regards to your comment about the coding of this 
> > 
> >     for (j = 1; j < TableGetRowCount(th1); j++)
> 
> Yes, this is the correct and recommended form for reading the 
cells. 
> Please reread my answer. What I was saying was that one better 
should 
> not define the columns of a table within a loop. By "defining a 
table" I mean 
> calling the "TableColumnAdd()" function. But, it can be done, and 
depends
> on the needs. I'm guessing that you have a table consisting of 
thousands 
> of columns, is it? If so, then it would be right and would make 
sense to 
> automatically define such big nbr of columns within a loop.
> 
> Cheers,
> UM
> 
> ----- Original Message ----- 
> From: "Fred" <fctonetti@xxxx>
> To: <amibroker@xxxxxxxxxxxxxxx>
> Sent: Tuesday, May 06, 2003 4:22 PM
> Subject: [amibroker] Re: ABtool v0.0.5 beta - Bug #2 ?
> 
> 
> > Uenal,
> > 
> > I don't think I've violated any of the prinicples you laid out.
> > 
> > Basically this piece of AFL:
> > 
> > 1.  Defines the columns for Table #1
> > 2.  Loads the rows for Table #1 which contain Ticker, Date/Time, 
> > Close and other information for each stock in the WL for each day 
> > from a number of bars back up through the last bar for the last 
> > Ticker.
> > 3.  Sorts Table #1 on date
> > 
> > 4.  Defines the columns for Table #2
> > 5.  Loops though Table #1 selecting certain rows and saves the 
> > information from the cells in the rows into varaibles and then 
stores 
> > them in the next available row of Table #2 one cell at a time so 
that 
> > Table #2 has no more then N rows per per bar as opposed to having 
one 
> > row for every Symbol per bar.
> > 
> > Is this in some way not a valid thing to do ?
> > 
> > One other thing I happened to notice which I will make mention of 
for 
> > others trying to get used to table handling is that it appears 
that 
> > when doing a TableDataGet that the first row (row 0) contains the 
> > column headings as opposed to the first row of data.  This is not 
a 
> > bad thing per se but can cause rather bizarre things to happen if 
one 
> > attempts to treat it as one would other rows.
> > 
> > With regards to your comment about the coding of this 
> > 
> >     for (j = 1; j < TableGetRowCount(th1); j++)
> > 
> > versus this 
> > 
> >    m = TableGetRowCount(th1);
> >    for (j = 1; j < m; j++)
> > 
> > I'm surprised that you seem to be suggesting that the first 
> > methodology that should work doesn't and the second methodology 
that 
> > doesn't work should or did I read your comments incorrectly.  
This 
> > code was NOT used to add new rows to an existing table but 
instead to 
> > inspect the rows that exist in Table #1 (Task #5 above) after it 
was 
> > fully loaded.
> > 
> > Fred


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Make Money Online Auctions! Make $500.00 or We Will Give You Thirty Dollars for Trying!
http://us.click.yahoo.com/KXUxcA/fNtFAA/uetFAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/