Skip to content

Commit

Permalink
as.array
Browse files Browse the repository at this point in the history
  • Loading branch information
helske committed Sep 15, 2024
1 parent 4e87c52 commit 548e9c5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions R/fit_mnhmm.R
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ fit_mnhmm <- function(model, inits, init_sd, restarts, threads, verbose, penaliz
X_o = model$X_emission,
X_d = model$X_cluster,
obs = obs,
ids = seq_len(model$n_sequences),
ids = as.array(seq_len(model$n_sequences)),
N_sample = model$n_sequences
),
as_vector = FALSE,
Expand Down Expand Up @@ -128,7 +128,7 @@ fit_mnhmm <- function(model, inits, init_sd, restarts, threads, verbose, penaliz
X_o = model$X_emission,
X_d = model$X_cluster,
obs = obs,
ids = seq_len(model$n_sequences),
ids = as.array(seq_len(model$n_sequences)),
N_sample = model$n_sequences
),
as_vector = FALSE,
Expand Down
4 changes: 2 additions & 2 deletions R/fit_mnhmm2.R
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ fit_mnhmm2 <- function(model, inits, init_sd, restarts, threads, verbose,
X_o = model$X_emission,
X_d = model$X_cluster,
obs = obs,
ids = ids,
ids = as.array(ids),
N_sample = n
),
as_vector = FALSE,
Expand Down Expand Up @@ -121,7 +121,7 @@ fit_mnhmm2 <- function(model, inits, init_sd, restarts, threads, verbose,
X_o = model$X_emission,
X_d = model$X_cluster,
obs = obs,
ids = seq_len(model$n_sequences),
ids = as.array(seq_len(model$n_sequences)),
N_sample = model$n_sequences
),
as_vector = FALSE,
Expand Down
4 changes: 2 additions & 2 deletions R/fit_nhmm.R
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ fit_nhmm <- function(model, inits, init_sd, restarts, threads, verbose, penalize
X_s = model$X_transition,
X_o = model$X_emission,
obs = obs,
ids = seq_len(model$n_sequences),
ids = as.array(seq_len(model$n_sequences)),
N_sample = model$n_sequences
),
as_vector = FALSE,
Expand Down Expand Up @@ -118,7 +118,7 @@ fit_nhmm <- function(model, inits, init_sd, restarts, threads, verbose, penalize
X_s = model$X_transition,
X_o = model$X_emission,
obs = obs,
ids = seq_len(model$n_sequences),
ids = as.array(seq_len(model$n_sequences)),
N_sample = model$n_sequences
),
as_vector = FALSE,
Expand Down

0 comments on commit 548e9c5

Please sign in to comment.