  In order to protect brokers from customer defaults in a volatile market, an
active margin system is proposed for the transactions of margin lending in
China. The probability of negative return under the condition that collaterals
are liquidated in a falling market is used to measure the risk associated with
margin loans, and a recursive algorithm is proposed to calculate this
probability under a Markov chain model. The optimal maintenance margin ratio
can be given under the constraint of the proposed risk measurement for a
specified amount of initial margin. An example of such a margin system is
constructed and applied to $26,800$ margin loans of 134 stocks traded on the
Shanghai Stock Exchange. The empirical results indicate that the proposed
method is an operational method for brokers to set margin system with a clearly
specified target of risk control.
