Fix broken example post move-around

This commit is contained in:
hadley
2016-01-22 10:03:10 -06:00
parent 986ea61453
commit 5e8d952313

View File

@@ -192,6 +192,7 @@ results
If you do this a lot, you should probably make a function for it: If you do this a lot, you should probably make a function for it:
```{r} ```{r}
df <- data.frame(x = 1:10, y = rnorm(100))
col_medians <- function(df) { col_medians <- function(df) {
out <- vector("numeric", ncol(df)) out <- vector("numeric", ncol(df))
for (i in 1:ncol(df)) { for (i in 1:ncol(df)) {