![]() |
|
| Discuss AmiBroker formula Language at the AmiBroker within the Traderji.com - Discussion forum for Stocks Commodities & Forex; Originally Posted by mishphar Yes Kalyan u r correct but I am completely new for ... |
|
|||||||
| Notices |
![]() |
|
|
Thread Tools |
| Sponsored Links |
|
#181
|
|||
|
|||
|
Quote:
x = MA(AdvIssues(),10)/MA(DecIssues(),10); BUY = x > 0.75 AND CROSS(RSI(8),30); SELL = CROSS(0.5,x) OR CROSS(65,RSI(8)); FILTER = BUY OR SELL; ADDCOLUMN(x, "Adv/Decl"); ADDCOLUMN(RSI(8), "RSI"); Since this is more relevant for trading Index you can expand the FILTER to the following FILTER = (BUY OR SELL) AND StrFind(StrToUpper(NAME()), "NIFTY"); (However not sure about the last part - never used it before) Regards, Kalyan. Last edited by kkseal; 26th December 2007 at 07:56 PM. Reason: change in last FILTER statement |
| Sponsored Links |
|
#182
|
|||
|
|||
|
thnx kalyan for the coding but the code doesn’t show any result neither any buy signal nor any sell but it's not a matter at list I know the procedure how to write the alf coding
thnx again |
|
#183
|
|||
|
|||
|
Quote:
As Kalyan tells, just concentrate on knowing the main coding part in AFL. Colours, arrows, filter, etc are simple and can be added later. You can look at this AFL skeleton code, which will help in the latter part mentioned above: http://www.traderji.com/82731-post93.html Praveen. |
|
#184
|
|||
|
|||
|
Mishphar,
There might be some issue with setting up the composites etc. I'll check it out and get back to you soon. Don't worry, it'll work. Regards, Kalyan. |
|
#185
|
|||
|
|||
|
Ok here we go. (The first 3 Steps invlve the necessary groundwork while the 4th step is the coding & execution)
STEP I : Seting IsIndex property for base Index In symbols pane Select NIFTY (or whatever symbol name you have for the NIFTY index) Goto Symbol->Information menu item and scroll down to Composites in the Information dialog box that appears. Set IsIndex property to 'yes'. STEP II : Seting base Index for Composites Open Categories window using Symbol -> Categories menu item. Select NSE (or whatever mkt name you have) in Markets tab In 'Base indexes for - Composites' combo enter NIFTY (or whatever symbol name you have for the NIFTY index) STEP III : Calculating Adv/Decl composites Choose "Symbol ->Calculate composites" menu item to open the Composites recalculation window Check Number of advancing/declining issues. In 'Apply to' Select 'All quotes'and 'This market'->Select NSE (or whatever mkt name you have). Click Calculate (this will take some time, you can however choose to use just the past 3/6/12 mths data. Enter the date range/no. of bars accordingly) STEP IV: Coding & Executing The Exploration code : Quote:
To base your exploration on the most recent quote you should choose "n last quotations" and "n=1" ------------- * If you include the IsIndex() flag and get no output for n=1, increase the value to 10,20,30. However this for testing only. MISCELLANY : You can include other tradable indices (like CNX IT, BANK NIFTY, CNX NIFTY Jr, CNX 100) in your Exploration by setting their IsIndex property to True as in Step I. If you're using the ASCII Importer you can Calculate composites automatically while importing data by checking the 'calculate Composites' option in the Import dialog. Check the EXREM function to remove excessive (consecutive buys or sells) signals. Regards, Kalyan. |
|
#186
|
|||
|
|||
|
Yes Kalyan u r a genius I can’t believe that u hv so depth knowledge about Amibroker ok its fine but from to-day I will call u as my GURU may GOD blessed u
Thnx mishphar |
|
#187
|
|||
|
|||
|
Hi,
I'm new to AMIBROKER. Recently I've found the metastock code for ELDER AUTO ENVELOPE. Can anyone plz convert it to AFL. Thanks Regards MS FORMULA EMA:=Input("Base EMA",1,100,22); Factor:=Input("Factor",1,50,27); avg:=Mov(C,EMA,E); csize:= Stdev(2*Max(Abs(H-avg) ,Abs(L-avg)) / avg,100)*Factor/10; {Use 100 days for stable channel size - default is 2.7 std} Csize:= ValueWhen(1, DayOfWeek()<Ref(DayOfWeek() ,-1) OR ( DayOfWeek()=Ref(DayOfWeek(),-1) AND DayOfMonth() <> Ref(DayOfMonth(),-1)) ,Ref(csize,-1)); { This pegs the Stdev to last bar of week and only changes once per week} csize:=LastValue(csize); {fix to constant using last value} channel:=csize*avg; avg+channel/2; avg-channel/2; avg; |
|
#188
|
|||
|
|||
|
Quote:
There's only one guru - KNOWLEDGE & only one genius - IT'S APPLICATION. (The rest is nothing more than disabling mental crutches) For more ideas on marketwide composite indicators see the Market Internals thread by Sunil Saranjame (he has done it all in Excel without the help of Ami - which makes him a greater guru )To see how you can make composite indicators even out of stuff like the RSI, check the ADDTOCOMPOSITE function in Ami. Regards, Kalyan. |
|
#189
|
|||
|
|||
|
And to see how you can free your mind from the 'sentinels' that strive to limit it, see 'The Matrix'
|
|
#190
|
|||
|
|||
|
HI
I am having esignal data feed with Amibroker 5 trail version. While stock charts are getting updated realtime, Futures/derivatives charts are not getting updated realtime. Two Charts of nifty spot and nity futures enclosed RMO Oscillator and 200 EMA are developed courtesy :=sSenior members of this Forum. Any members have faced similar problems and what is the solution. Thanks in advance SRJC |
| Sponsored Links |
|
|
![]() |
| Bookmarks |
| Thread Tools | |
|
|
Similar Threads for: AmiBroker formula Language
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| need help on formula | cmlee | MetaStock | 23 | 8th October 2007 07:55 PM |
| Metastock ,Metatrader & Amibroker indicator formula | saji oommen | MetaStock | 0 | 4th June 2006 06:35 PM |
| Metastock language help | Ropewalker | MetaStock | 4 | 1st November 2005 09:16 PM |
| TradeStation & MetaStock Formula Language | bikertrader | MetaStock | 4 | 10th December 2004 01:50 PM |
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.