Fix when type of X axis is category