Iterating over the lines of a data.frame with purrr

I sometimes have a function which takes some parameters and returns a data.frame as a result. Then I have a data.frame where each row of it is a set of parameters. So I like to apply the function to each row of the parameter-data.frame and rbind the resulting data.frames.

There are several ways to do it. Let’s have a look:

A New Animation of the Spreading of SARS-CoV-2 in Germany

Update 2020-11-28: I’ve updated the resulting image with data until Nov 27, 2020.

In August I published first an animation of the spreading of SARS-CoV-2 in Germany.

Some days ago I found a similar visualization for Austria by Matthias Schnetzer. But he uses a different scale. His worst colour is for 150 incidents per 100,000 residents during the last 7 days. (I used 50 as last value of the scale.)

He also provides a link to his code He uses a little different way for plotting. So I thought I should update my animation using his way.