splitting analyze.r into seperate files per plot function