nmatrix not working with nils