This is the updation of Manual Trade Control for NEST/NOW. This afl have new features like it will have all the trades in its memory. This AFL is not a strategy for trading. It can be used only for integrating the Amibroker to pass orders to NEST/NOW Trading Terminal through NEST PLUS API.
[wp_ad_camp_5]
AFL Code Written Buy : Ranjith K R
AFL Creator Email ID : [email protected]
Features
2. You Can Enter your Client ID in the Parameters
3. You can select the Buy/Sell Price from Ask price, Bid price or LTP.
4. Option for Enabling Actual Trading (If Disabled, No Signals will go to NOW/NEST, But chart will generate signals.) This can be used for testing.
5. Selecting the Buy/Sell as Intraday or Delivery.
6. Selecting Order Type as Limit/ market
7. Short/Cover is included. You can add strategy and manual trade also is possible.
8. It saves all Buy/Sell & Short/Cover trades in memory and plotted until its cleared.
9. Option for selecting type of trade. ie Long,Short or Together. Long trade will only starts with a buy signal and Short Trade will Only start with Short Signal. Sell and Cover signals will only appear after buy and short signals.
10. Separate display for Buy, Sell, Short and Cover Traders for clarity.
11. KeyBoard Shortcut for Buttons.
Buy → Numpad 7
Sell → Numpad 8
Short → Numpad 4
Cover → Numpad 5
Clear → Numpad 0
Amibroker AFL Code
https://gist.github.com/bcceee7e23c8d2e67748
You have to replace the existing buy/sell strategy with your buy/sell strategy. Strictly do not use the buy/sell strategy in this afl for real trading.. Replace the following coding in the above AFL with your own Trading System
https://gist.github.com/179bc05fe0bd151f2b37
Requirements
1. For Buy/Sell Price selection, use Aux1 and Aux2 for importing the Ask Bid Prices.
2. Symbol in the Amibroker should be the same as present in the NEST/NOW.
3. Active Nest Plus API Subscription is required (Contact your broker for NEST PLUS API subscription)
4. NEST/NOW trader should be opened and logged in. Also logged in to the NEST PLUS with a valid API subscription.
Usage
1. Copy The Afl to Custom Afl folder of amibroker.
2. OPEN AFL IN FORMULA EDITED AND DELETE STRATEGY PORTION OF CODE AND TYPE PASTE YOUR BUY/SELL STRATEGY IN THAT PLACE AND SAVE THE AFL.
2. Drag and drop the afl to an intraday chart blank chart.
3. Enable Controls and Strategy and Autotrade options.
4. Select type of trades you want (Long/Short)
5. Select Buy Price, Sell Price, Product Type and Order Type
6. Enter Client ID and LotQty.
Press Buy/Sell/Short/Cover buttons for manual trading.
Strategy based signals will come automatically.
Note: Only Buy and Short will happen first. You cannot do a Sell or Cover in first. Only Two BUY or SELL or SHORT or COVER one after another are not possible.
Note: Don’t use this afl for backtesting your strategy. BackTest your strategy separately and paste it in this afl.
[Suggest Features For Improvement. This Afl is tested with amibroker 5.7 and 5.9 veraions] [NEST, NOW, Amibroker are registered products of the Respective Companies]
Hi,
Can this afl be modded for Cover Orders ?
Thanks a lot for sharing it.
Sir, please let me know if it is possible. Or please point me to any document which provides codes. The document on Omnesys site only provides for Normal Orders.
Thanks
To my knowledge for Retail Traders only Limit Orders are supported in Nest/Now. And only a dealers using dealers terminal can do Market Orders, Order Modification which is restricted as of now in common retail traders terminals due to Exchange and SEBI compliance.
Thank You..
sir i am using now terminal only. i dont have nest or nest plus. is it working now terminal? pls reply.
You need to take Nest API Subscription from Omnesys costs 250/- per month. Check with your broker.
Dear Rajandran,
which AFL code do you use to get the buy/signal indicators in http://www.marketcalls.in/livecharts?
This is because non-repainting super trend indicator or even nonsupertrend ver2 shows three trades where as live chart shows only 1.
Please confirm.
thanks,Tarak
Can I use this automation code in Zerodha Trader terminal?
dear,
how to use AUX1 and AUX2 fields from AFL?
if you make a video about it, it’s really helpful….
Here is a interesting tutorial on how to use Aux1 and Aux2 parameters in Amibroker
thank you Raj, for your quick reply
How can I download this afl
kindly let me know how to download the afl
dea rajendran i want know about robotrading by kbl data server ammibroker is it tru.
I dont have any idea about that. If they are providing full autotrading to retail traders without NSE approval then probably it could be a illegal product.
dear raj,
how to write in afl, BUY at signal price AT CL basis of Candle stick of 5 Min with order type “lIMIT” , becoz my order will be generated on the base of particular signal of an indicator, i m not going with order type MARKET, due to slippage factor, my holding will be basically more than 30 mins to 2 hrs.
plz advise………………
i have a strategy which works fine on 2 min candlestick closing price.
if the price is moved above the 0.8% of opening price of the first 2 min candle stick then buy and target being 1.6% of the opening price of the first candle stick. If it reaches then exit else continue.
StopLoss being Opening price.
ex : opening price of 1st candle stick is 100 at 9:16 and at 9:18 or whenever the price reaches 100.8 i will buy and selling it when the price reaches to 101.6
StopLoss is being if price moves below 100
1. How can you coded this?
2. how to check the status of the trade executed ?
Dear Mr. Rajandran,
I’m having a very little knowledge on AmiBroker and Chart Analysis. But i’d like to go for Semi-automated AlgoTrading with Amibroker. So, Can you help me with a most effective and accurate Buy/Sell signal generating AFL which will work on AlgoTrading with Amibroker. And what is the role of NEST Plus in Algo, what does it do??
If you want to share/discuss anything in private feel free to drop a mail at your convenience on the above mentioned email-id.
If I try to use this afl alog with sort of supertrend, its not working, I mean it is not generating signals..
The code is Buy = trend==1; where trend is derived as from supertrend indicator.Pls help…
Hi,
Anyone got this working for NFO kindly post the modified code. Keep getting error ‘COM object variable is not initialized or has invalid type(valid COM object handle is required)’. Using Trial ami 5.9, and GDFl datafeed , Tried reinstallation of ami, as suggested by someone else in the forum with no luck. Strangely the GDFL plugin works fine.
Thanks in advance
IS this settings working in Nestnow terminal, I mean have anyone tested this with some live AFL. I just need confirmation so as I may subscribe to nestnow API and test also
Yes, new updated auto afl is working perfectly.
Dear sir,
Could you please combine this afl with your supertrend3?
What is the updated AFL ??? Can u post here ??
Does anyone recently got NEST Plus activated for NSE Now Terminal? I am trading using NSE NOW terminal from Zerodha and not able to get NEST Plus activation.
Do you suggest any alternate API?
I think Nest Plus is now stopped by Thomson Reuters. No more in use.
Dear Rajandran,
What is the available alternative now for Nest Plus ?
Regards…
Most of the Brokers Providing Nest API. Try the videos here https://www.youtube.com/watch?v=lpJbuI0EVvY&list=PLZ3arkE9XOWftb1lnmE2wUfceCpfXfdPm
Dear Team,
I didn’t understand below mentioned lines…can you please explain me same in easy language. so i can understand.
Note: Only Buy and Short will happen first. You cannot do a Sell or Cover in first. Only Two BUY or SELL or SHORT or COVER one after another are not possible.
how to set trading time
eg.from 9.30am to 3.00 pm
here can u provide those code so that i can set trading time also