Description Usage Arguments Value Examples
Constructor for Gaussian Mixture Data
1 |
sample |
A data frame with 3 variables: |
dictionary |
A data frame with 3 variables: |
An object of class gmd
, which is effectively a list
with 2 components: sample
and dictionary
, as described by the
input arguments.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | N <- 100
M <- 4
w <- matrix(runif(N * M), N, M)
w <- w / rowSums(w)
s <- tidyr::crossing(
observation = paste0("O", 1:N),
component = paste0("C", 1:M)
) %>%
dplyr::mutate(mixing = as.numeric(t(w)))
d <- tibble::tibble(
component = paste0("C", 1:M),
mean = numeric(M),
precision = 1:M
)
x <- gmd(s, d)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.