License is needed before posting. Was: Update initial capital based on the profit and loss

Hi All,

I am planning to set initial trading amount 30000 .
Based on the buy and sell signal it will execute the quantity automatically from my initial capital .

Example ; Sbin- LTP =300 = 30000/300 = 100 qty will trigger automatically.

If 1st trade given 5000 profit means , next trade should consider my updated capital and trade should execute for 30000+5000=35000 and vice versa for loss.

Example : 2nd trade - SBIN -LTP -310 = 35000/310= New updated quantity should automatically will be trigger.

How can i implement this . Please provide concern .

Thanks,
Saminathan M

Please someone help on this.

https://www.amibroker.com/guide/afl/setpositionsize.html

It’s all built in if you use the function above.

Hi Sir,

This is possible to use this inbuilt function for algo trading system .

How can i get this afl sir .
Could you please guide on this .
I need this to automate for live trading .Please provide your concern.

Thanks,
Sami

Please read the documentation for the SetPositionSize() function, paying particular attention to the spsPercentOfEquity method.

Also, make sure to verify your AmiBroker license or you will not be allowed to post on the forum.

@saminathan - Your user account isn't marked with License verified badge. Did you purchase AmiBroker license?

Only users with License verified badge are allowed to post on this forum.

So before posting, make sure you verify your license as explained here.

2 Likes

Thread closed until original poster proves registration status.