Merge branch 'master' of github.com:hadley/r4ds
This commit is contained in:
commit
8f087e8ce3
|
@ -118,7 +118,7 @@ measure_distance <- function(mod, data) {
|
||||||
measure_distance(c(7, 1.5), sim1)
|
measure_distance(c(7, 1.5), sim1)
|
||||||
```
|
```
|
||||||
|
|
||||||
Now we can use purrrr to compute the distance for all the models defined above. We need a helper function because our distance function expects the model as a numeric vector of length 2.
|
Now we can use purrr to compute the distance for all the models defined above. We need a helper function because our distance function expects the model as a numeric vector of length 2.
|
||||||
|
|
||||||
```{r}
|
```{r}
|
||||||
sim1_dist <- function(a1, a2) {
|
sim1_dist <- function(a1, a2) {
|
||||||
|
|
Loading…
Reference in New Issue