From 43978e440569b27383adb0f52ca0a652f44c1272 Mon Sep 17 00:00:00 2001 From: Kirill Sevastyanenko Date: Thu, 17 Dec 2015 11:29:47 -0500 Subject: [PATCH] Update lists.Rmd typo --- lists.Rmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lists.Rmd b/lists.Rmd index 8350760..4a5a722 100644 --- a/lists.Rmd +++ b/lists.Rmd @@ -541,7 +541,7 @@ You'll see an example of this in the next section, as `transpose()` is particula It's called transpose by analogy to matrices. When you subset a transposed matrix, you switch indices: `x[i, j]` is the same as `t(x)[j, i]`. It's the same idea when transposing a list, but the subsetting looks a little different: `x[[i]][[j]]` is equivalent to `transpose(x)[[j]][[i]]`. Similarly, a transpose is its own inverse so `transpose(transpose(x))` is equal to `x`. -Tranpose is also useful when working with JSON apis. Many JSON APIs represent data frames in a row-based format, rather than R's column-based format. `transpose()` makes it easy to switch between the two: +Transpose is also useful when working with JSON apis. Many JSON APIs represent data frames in a row-based format, rather than R's column-based format. `transpose()` makes it easy to switch between the two: ```{r} df <- dplyr::data_frame(x = 1:3, y = c("a", "b", "c"))