Traderji.com - Discussion forum for Stocks Commodities & Forex

Beginner AFL Program writers Thread

Discuss Beginner AFL Program writers Thread at the AmiBroker within the Traderji.com - Discussion forum for Stocks Commodities & Forex; Dear Traders This Thread is dedicated to all new program writers of AFL who want ...


Go Back   Traderji.com - Discussion forum for Stocks Commodities & Forex > TOOLS & RESOURCES > Software > AmiBroker

Notices


Advertise Here

Reply
 
Thread Tools
Sponsored Links
  #1  
Old 17th February 2007, 11:10 PM
Member
 
Join Date: Jan 2006
Posts: 140
Blog Entries: 3
Thanks: 16
Thanked 9 Times in 6 Posts
riser3 is on a distinguished road
Reputation: 29
Default Beginner AFL Program writers Thread

Dear Traders

This Thread is dedicated to all new program writers of AFL who want their programs to be effective and sophisticated.
Way of Posting in this thread
1)
So please post your program using code bar so that experienced code writers can have a look rather than downloading (saving time)
2)
Please write the goal of that program to be achieved in simple language (to avoid repetetive replies and time waste)

Senior Code writers are requested to resolve the problems of code and help in making better afl's

Suggestions from other traders in this regard are welcome
Please reply if you tink this thread helps us

Regards
Brijwanth
Reply With Quote
  #2  
Old 17th February 2007, 11:25 PM
Member
 
Join Date: Jan 2006
Posts: 140
Blog Entries: 3
Thanks: 16
Thanked 9 Times in 6 Posts
riser3 is on a distinguished road
Reputation: 29
Default Re: Beginner AFL Program writers Thread

Here is my first one
experienced code writers please comment on corrections and suggestions

Code:
// Displays of todays Low is Lowest in 20 days 
i=0;
i=LLV(l,20)-low;
if (i=0)
printf ("Today is lowest in 20 days for %s",name()); 
addcolumn(Low, "Lowest");
buy=0;
sell=0;
Reason: To find if todays Low is Lowest in 20 days
Reply With Quote
  #3  
Old 18th February 2007, 10:27 AM
Member
 
Join Date: Jan 2007
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
roshmic is on a distinguished road
Reputation: 20
Default Re: Beginner AFL Program writers Thread

Is there a discussion forum for writing program codes in amibroker? Something that explains the very fundamental
Reply With Quote
  #4  
Old 18th February 2007, 01:13 PM
Member
 
Join Date: Jan 2006
Posts: 140
Blog Entries: 3
Thanks: 16
Thanked 9 Times in 6 Posts
riser3 is on a distinguished road
Reputation: 29
Default Re: Beginner AFL Program writers Thread

Try this.. I remember somewhere in this thread that example/ basic program read the description
http://www.amibroker.com/library/list.php
Reply With Quote
  #5  
Old 18th February 2007, 02:09 PM
Member
 
Join Date: May 2006
Location: Bangalore
Posts: 913
Thanks: 0
Thanked 16 Times in 2 Posts
bvpraveen is on a distinguished road
Reputation: 48
Default Re: Beginner AFL Program writers Thread

Quote:
Originally Posted by brijwanth View Post
Dear Traders

This Thread is dedicated to all new program writers of AFL who want their programs to be effective and sophisticated.
.....
Hello Brijwanth,

All the best for the new initiative. Hope this thread becomes one stop place to post all the doubts in AFLs.

It will be better if we go through the Amibroker User Guide for any quick reference and detailed explanation of AFL functions, first. If we have doubts in their functionality or codes, AFL known members can always help them.

Regards,
Praveen.
Reply With Quote
  #6  
Old 18th February 2007, 02:13 PM
Member
 
Join Date: May 2006
Location: Bangalore
Posts: 913
Thanks: 0
Thanked 16 Times in 2 Posts
bvpraveen is on a distinguished road
Reputation: 48
Default Re: Beginner AFL Program writers Thread

Quote:
Originally Posted by brijwanth View Post
Here is my first one
experienced code writers please comment on corrections and suggestions

Code:
// Displays of todays Low is Lowest in 20 days 
i=0;
i=LLV(l,20)-low;
if (i=0)
printf ("Today is lowest in 20 days for %s",name()); 
addcolumn(Low, "Lowest");
buy=0;
sell=0;
Reason: To find if todays Low is Lowest in 20 days
Hi,

I'm afraid there is some logical errors in this code.

1. LLV(l,20)-low : returns an array and not a single boolean value. Hence it can't be compared in a 'if' statement at one shot.

2. if(i=0) : A very common error. 'if' statement needs boolean value and hence the expression inside the 'if' statement should return boolean value. But if you see "i=0", we are just assigning the value zero(0) to i and we are not comparing i to zero. So the correct usage of 'if' should be
if (i == 0) // i shouldn't be an array

Let me know if I'm wrong or understood the actual requirement wrongly.

Praveen.
Reply With Quote
  #7  
Old 18th February 2007, 02:16 PM
Member
 
Join Date: May 2006
Location: Bangalore
Posts: 913
Thanks: 0
Thanked 16 Times in 2 Posts
bvpraveen is on a distinguished road
Reputation: 48
Default Re: Beginner AFL Program writers Thread

Modified code to check whether today's low is 20 day's low:

Code:
// Displays of todays Low is Lowest in 20 days 

i = (L == LLV(L, 20));
Filter = i;
AddColumn(Low, "Lowest");
Regards,
Praveen.
Reply With Quote
  #8  
Old 18th February 2007, 06:11 PM
Member
 
Join Date: Jan 2006
Posts: 140
Blog Entries: 3
Thanks: 16
Thanked 9 Times in 6 Posts
riser3 is on a distinguished road
Reputation: 29
Default Re: Beginner AFL Program writers Thread

Thanx Praveen for ur advice it was great hope that it will bring all code writers of traderji

pls. reply to this thread experienced code writers so that we will be able to identify the best in afl talent pool
Reply With Quote
  #9  
Old 18th February 2007, 06:31 PM
Member
 
Join Date: Jul 2006
Posts: 257
Thanks: 1
Thanked 0 Times in 0 Posts
rkgoyal_98 is on a distinguished road
Reputation: 18
Default Re: Beginner AFL Program writers Thread

Dear seniors,

I am novice at trading as well as use of AFLs. So I need help. I wnat to write and AFL where Buy signal can be generated when prices are at the lower extream of Bolinger Band ( 20 period with 2 deviation) and also 5period smoothed line cross 72 period CCI. Reverse for the sell signal i.e. when price will be on the upper extream and again 5 smooth cross over to the otherIf Some one can explain the various things used in the AFL it will be helpful.
Please also advise if any learning book/site for the AFL is available.
I need to begin from ABC.
Thanks

Rajeev
Reply With Quote
  #10  
Old 17th September 2008, 12:16 AM
Member
 
Join Date: Sep 2006
Posts: 69
Thanks: 4
Thanked 5 Times in 4 Posts
bamks is on a distinguished road
Reputation: 25
Default Re: Beginner AFL Program writers Thread

Quote:
Originally Posted by bvpraveen View Post
Modified code to check whether today's low is 20 day's low:

Code:
// Displays of todays Low is Lowest in 20 days 

i = (L == LLV(L, 20));
Filter = i;
AddColumn(Low, "Lowest");
Regards,
Praveen.
Thank you for the afl. the turtle traders went for stocks which made a 20 day high. Saw the afl today

Thanx
bamks
Reply With Quote
Sponsored Links

Reply

Bookmarks


Advertise Here


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads for: Beginner AFL Program writers Thread
Thread Thread Starter Forum Replies Last Post
TA Course for the Beginner karthikmarar Beginners Guide 5 6th June 2007 10:42 PM
Beginner Links radzman Trading Resources 3 15th August 2006 07:28 PM
beginner question iamme9182 Risk & Money Management 0 23rd August 2005 09:28 AM


All times are GMT +5.5. The time now is 04:12 AM.

Indemnity, Disclaimer & Disclosure Notice:
• By visiting Traderji.com you indicate your acceptance of our Forum Rules Disclaimer & Disclosure and indemnify Traderji.com, its associates and related parties of all claims howsoever resulting from the usage of the forum.
Disclaimer: Trading or investing in stocks & commodities is a high risk activity. Any action you choose to take in the markets is totally your own responsibility. Traderji.com will not be liable for any, direct or indirect, consequential or incidental damages or loss arising out of the use of this information.
Disclosure: The information in this forum is neither an offer to sell nor solicitation to buy any of the securities mentioned herein. The writers may or may not be trading in the securities mentioned.
• All names or products mentioned are trademarks or registered trademarks of their respective owners.
General Content Disclaimer Notice:
In light of our policy of encouraging candid, open exchanges of views and the rapid distribution of information originating from many sources, Traderji.com cannot determine the accuracy of information that may be uploaded to the forum. Opinions, advice and all other information expressed by participants in discussions are those of the author. You rely on such information at your own risk. You are urged to seek professional advice for specific, individual situations and not rely solely on advice or opinions given in the discussions. Since Traderji.com is an open and free discussion forum, any comments made by members of this forum in their posts reflect their own views and not of the owner or administrator of Traderji.com. Thus the owner/administrator indemnify themselves of all claims whatsoever and will not be liable or responsible for any members comments/views in this forum Traderji.com. If you find any objectionable or offensive posts made by members of this forum which you would like to bring to our notice for removal then please Contact Us.
 


Copyright © 2001 - 2008, Traderji.com All Rights Reserved.

Recommended Websites - www.TradersEdgeIndia.com - www.TradingPicks.com - www.MasterOfTrading.com