created R codes and png files