Updated plotting functions