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

RE: [amibroker] AFL - fgets()


  • To: <amibroker@xxxxxxxxxxxxxxx>
  • Subject: RE: [amibroker] Code to specify a specific parameter for a specific ticker for a specific period of time?
  • From: "Ken Close" <closeks@xxxxxxxx>
  • Date: Mon, 5 Jan 2004 09:22:05 -0800
  • Title: Message

PureBytes Links

Trading Reference Links










nope.  It was your code, and it had
some similar characteristics to something you and I did a long time ago with
j-script and the CASE statement.

 

Assuming you wanted to &#8220;process&#8221;
100 tickers using the code you settled on below (instead of the two shown in
the example), my question was how would you do that.

 

Ken

 

-----Original Message-----
From: dingo
[mailto:dingo@xxxxxxxxxxxx] 
Sent: Monday, January 05, 2004
11:20 AM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of
time?

 



it can vary - got a sample of whatcher
talkin' 'bout?





 





d





<span
>-----Original Message-----
From: Ken Close
[mailto:closeks@xxxxxxxx] 
Sent: Monday, January 05, 2004
7:34 AM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of
time?

Dale:  How many tickers do you have
to process at one time?  Have you tried to put them into an overall
outside loop themselves or just repeat the code below x number of times, one
for each ticker?

 

Ken

 

-----Original Message-----
From: dingo
[mailto:dingo@xxxxxxxxxxxx] 
Sent: Monday, January 05, 2004
12:56 AM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of time?

 



Thought I'd wrap up this post with what I
finally decided on.





 





Dave - you were right the multiplications
are too processor intenstive and the iif's take care of that.





 





Thanks to both you and Graham!





 





Q103 = (DateNum() >= 1030101 AND
DateNum() <= 1030331);
Q203 = (DateNum() >= 1030401 AND DateNum() <= 1030630);
Q303 = (DateNum() >= 1030701 AND DateNum() <= 1030930);
Q403 = (DateNum() >= 1031001 AND DateNum() <= 1031231);





 





if(Name()=="ADBE")
    {
    Slevel = IIf(Q103, 1, IIf(Q203, 2,  IIf(Q303, 3, 
IIf(Q403, 4, 9999))));
    }





 





if(Name()=="ALO")
    {
    Slevel = IIf(Q103, 11, IIf(Q203, 12,  IIf(Q303,
13,  IIf(Q403, 14, 9999))));
    }





 





AddColumn(SLevel
,      "SLevel
",      1.0);
Filter = 1;





d





<span
>-----Original Message-----
From: Graham [mailto:gkavanagh@xxxxxxxxxxxxx]

Sent: Sunday, January 04, 2004
8:03 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of
time?



Sorry dingo, maybe I could make it a bit more complicated
and use some looping statements using a few fors, whiles, wends, ifs and
buts ;-)





 





 





Cheers,
Graham
http://groups.msn.com/asxsharetrading
http://groups.msn.com/fmsaustralia




<span
>-----Original Message-----
From: dingo
[mailto:dingo@xxxxxxxxxxxx] 
Sent: Monday, 5 January 2004 8:38
AM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of
time?



Thanks Graham BUT that's waay to
simple!  Could you make it much more complicated for me as that's the way
I like to do things?  8-)





 





d





<span
>-----Original Message-----
From: Graham
[mailto:gkavanagh@xxxxxxxxxxxxx] 
Sent: Sunday, January 04, 2004
7:31 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code to
specify a specific parameter for a specific ticker for a specific period of
time?

<font size=2
face="Courier New">You could just use this ,
just check the bracket numbers for closure<font size=2
face="Courier New">

Slevel = (Name()=="ADBE") * ( (
(DateNum() >= 1030401 AND DateNum() <=
1030630) * 34 ) + ( (DateNum() >= 1030701 AND
DateNum() <= 1030930) * 2 ) );

Cheers,
Graham
http://groups.msn.com/asxsharetrading
http://groups.msn.com/fmsaustralia


-----Original Message-----
From: dingo [mailto:dingo@xxxxxxxxxxxx] 
Sent: Monday, 5 January 2004 8:23 AM
To: _amibroker_yahoo
Subject: [amibroker] Code to specify a specific parameter
for a specific
ticker for a specific period of time?


As the subject says "Code to specify a
specific parameter for a specific
ticker for a specific period of time?".

I'm in a brain fog and could use some help. Here's
what I've coded so
far:

Slevel will be used as the cross line for an
oscillator.

if(Name()=="ADBE")
    {
    if (DateNum() >= 1030401 AND
DateNum() <= 1030630)
        {
        Slevel
= 34;
        }
    if (DateNum() >= 1030701 AND
DateNum() <= 1030930)
        {
        Slevel
= 2;
        }
    }

Filter = 1;

AddColumn(SLevel, "SLevel ", 1.0);


But I'm getting a syntax error:

Error 3.
Condition in IF, WHILE, FOR statements
has to be Numeric or Boolean type.
You can not use array here,
please use [] (array subscript operator)
to access array elements

How can I make this work?

d


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


------------------------ Yahoo! Groups Sponsor
---------------------~--> Buy
Ink Cartridges or Refill Kits for your HP, Epson,
Canon or Lexmark Printer
at MyInks.com. Free s/h on orders $50 or more to
the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
<a
href="">http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Yahoo! Groups Links

To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/

To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx

Your use of Yahoo! Groups is subject to:  <a
href="">http://docs.yahoo.com/info/terms/ 



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


<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to
     the Yahoo! Terms of Service.
     

 



<font size=3
face="Times New Roman">

Send
BUG REPORTS to bugs@xxxxxxxxxxxxx<font size=2
face="Courier New">
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to:
amiquote@xxxxxxxxxxxxxxx 
(Web page: <a
href="">http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: <a
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html


<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to
     the Yahoo! Terms of Service.
     

 



<font size=3
face="Times New Roman">

Send
BUG REPORTS to bugs@xxxxxxxxxxxxx<font size=2
face="Courier New">
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to:
amiquote@xxxxxxxxxxxxxxx 
(Web page: <a
href="">http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: <a
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html




<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to
     the Yahoo! Terms of Service.
     

 



<font size=3
face="Times New Roman">

Send
BUG REPORTS to bugs@xxxxxxxxxxxxx<font size=2
face="Courier New">
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to:
amiquote@xxxxxxxxxxxxxxx 
(Web page: <a
href="">http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: <a
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html


<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to the
     Yahoo! Terms of Service. 

<font size=3
face="Times New Roman">


Send
BUG REPORTS to bugs@xxxxxxxxxxxxx<font size=2
face="Courier New">
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx

(Web page: <a
href="">http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: <a
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html




<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to
     the Yahoo! Terms of Service.
     

 





Send
BUG REPORTS to bugs@xxxxxxxxxxxxx<font size=2
face="Courier New">
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to:
amiquote@xxxxxxxxxxxxxxx 
(Web page: <a
href="">http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: <a
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html








<font size=2
face="Courier New">





<span
>Yahoo! Groups Links


 To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/
       
 To unsubscribe from this group, send an
     email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx
       
 Your use of Yahoo! Groups is subject to
     the Yahoo! Terms of Service.
     







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








Yahoo! Groups Sponsor


  ADVERTISEMENT 









Yahoo! Groups Links
To visit your group on the web, go to:http://groups.yahoo.com/group/amibroker/ 
To unsubscribe from this group, send an email to:amibroker-unsubscribe@xxxxxxxxxxxxxxx 
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.