for
loop produces different result as map
due to lazy evaluation
#3
Labels
for
loop produces different result as map
due to lazy evaluation
#3
R's lazy evaluation can lead to different results when translating
map
function calls tofor
loops. Below is one example that Claus Wilke provided on Twitter.Lets think about, whether there is someway to force evaluation programmatically to produce the same result as
map
and if not, this needs to be mentioned an a vignette together with other caveats and quirks ofas_loop()
.Created on 2022-04-05 by the reprex package (v0.3.0)
The text was updated successfully, but these errors were encountered: