r graphs

script for graphs in r
automatization fixes + first run