Scripts: CustomStopOut: your own margin call and stop-out levels, worst position closed first

CustomStopOut: your own margin call and stop-out levels, worst position closed first:

A script that sets your own margin call and stop-out levels above the broker's. It alerts when the margin level falls below your margin call level and, below your stop-out level, closes positions one at a time, the worst net result first, until the level is back up, the way a broker stop-out works.

CustomStopOut: your own margin call and stop-out levels, worst position closed first

Author: George Ciprian Mandache