Statistics for Banking regulation: a Bayesian network approach to risk management