Skip to content

Commit

Permalink
Merge branch 'master' of github.com:RGLab/COMPASS
Browse files Browse the repository at this point in the history
  • Loading branch information
Greg Finak committed Feb 7, 2021
2 parents ab2cf68 + f78f1cd commit 38dc986
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 78 deletions.
70 changes: 0 additions & 70 deletions .travis.yml

This file was deleted.

17 changes: 9 additions & 8 deletions R/COMPASS.R
Original file line number Diff line number Diff line change
Expand Up @@ -450,25 +450,26 @@ COMPASS <- function(data, treatment, control, subset=NULL,

## go to the model fitting processes
if(run_model_or_return_data=="run_model"){
output <- list(
fit=.COMPASS.discrete(n_s=n_s, n_u=n_u, categories=categories,
iterations=iterations, replications=replications, verbose=verbose, init_with_fisher=init_with_fisher, ...),
data=list(n_s=n_s, n_u=n_u, counts_s=counts_s, counts_u=counts_u,
categories=categories, meta=data$meta, sample_id=data$sample_id,
individual_id=data$individual_id)
)
output <- list(
fit=.COMPASS.discrete(n_s=n_s, n_u=n_u, categories=categories,
iterations=iterations, replications=replications, verbose=verbose, init_with_fisher=init_with_fisher, ...),
data=list(n_s=n_s, n_u=n_u, counts_s=counts_s, counts_u=counts_u,
categories=categories, meta=data$meta, sample_id=data$sample_id,
individual_id=data$individual_id)
)
}else{
output<-list(fit="No model was fitted");
}

if (keep_original_data) {
output$orig <- data
}

if(run_model_or_return_data == "run_model"){
## Compute the posterior ps-pu; log(ps)-log(pu)
vmessage("Computing the posterior difference in proportions, posterior log ratio...")
output$fit$posterior <- compute_posterior(output)
vmessage("Done!")
}

## Filter metadata
..iid.. <- iid
Expand Down

0 comments on commit 38dc986

Please sign in to comment.