matrix plot fix