added plot function to propagate