print a weight matrix