title: renaming a bunch of variables in dplyr
body: <p>After a left_join I have variables <code>var1.x var2.x</code> ... and <code>var1.y var2.y</code> . I would like to rename them to <code>var1_tot var2_tot</code> and <code>var1_part var2_part</code>. I can do this but combining <code>names</code> and string replacement functions. Can this be done as part pf a <code>dplyr</code> chain by using <code>dplyr</code>'s <code>rename</code> function and <code>ends_with</code>?</p>