basic R script for summary stats