variance:ro2
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| variance:ro2 [2026/03/10 23:20] – hkimscil | variance:ro2 [2026/03/10 23:29] (current) – removed hkimscil | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | < | + | |
| - | > rnorm2 <- function(n, | + | |
| - | > set.seed(1) | + | |
| - | > a <- rnorm2(100000000, | + | |
| - | > head(a) | + | |
| - | [,1] | + | |
| - | [1,] 93.73555 | + | |
| - | [2,] 101.83562 | + | |
| - | [3,] 91.64403 | + | |
| - | [4,] 115.95044 | + | |
| - | [5,] 103.29411 | + | |
| - | [6,] 91.79562 | + | |
| - | > tail(a, | + | |
| - | [,1] | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | [100000000, | + | |
| - | > m.a <- mean(a) | + | |
| - | > sse.a <- sum((a-m.a)^2) | + | |
| - | > n.a <- length(a) | + | |
| - | > df.a <- n.a - 1 | + | |
| - | > | + | |
| - | > sse.a / n.a | + | |
| - | [1] 100 | + | |
| - | > sse.a/ df.a | + | |
| - | [1] 100 | + | |
| - | > | + | |
| - | </ | + | |
variance/ro2.1773184821.txt.gz · Last modified: by hkimscil
