R Under development (unstable) (2024-06-20 r86796 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > library(testthat) > library(o2geosocial) Registered S3 methods overwritten by 'o2geosocial': method from plot.outbreaker_chains outbreaker2 print.custom_likelihoods outbreaker2 print.custom_priors outbreaker2 print.outbreaker_chains outbreaker2 summary.outbreaker_chains outbreaker2 > > test_check("o2geosocial") ///// outbreaker custom likelihoods /// class: custom_likelihoods list number of items: 5 /// custom likelihoods set to NULL (default used) // $reporting NULL $timing_infections NULL $timing_sampling NULL $space NULL $age NULL ///// outbreaker custom likelihoods /// class: custom_likelihoods list number of items: 5 /// custom likelihoods // $reporting function(data, param, i) cpp_ll_reporting(data, param, i) $timing_infections function(data, param, i) cpp_ll_timing_infections(data, param, i) $timing_sampling function(data, param, i) cpp_ll_timing_sampling(data, param, i) $space function(data, config, param, i) cpp_ll_space(data, config, param, i) $age function(data, param, i) cpp_ll_age(data, param, i) ///// outbreaker results /// class: outbreaker_chains data.frame dimensions 21 rows, 22 columns ancestries not shown: alpha_2 - alpha_5 infection dates not shown: t_inf_1 - t_inf_5 intermediate generations not shown: kappa_1 - kappa_5 /// head // step post like prior a b pi alpha_1 1 1 -32.60111 -33.00495 0.4038415 0.7 0.1 0.9614177 NA 2 50 -36.80173 -38.03852 1.2367946 0.7 0.1 0.9872715 2 3 100 -31.05555 -32.21853 1.1629811 0.7 0.1 0.9792075 NA ... /// tail // step post like prior a b pi alpha_1 19 900 -33.20696 -34.48840 1.2814403 0.7 0.1 0.9921812 2 20 950 -33.63650 -34.27655 0.6400423 0.7 0.1 0.9239327 2 21 1000 -32.43451 -33.49219 1.0576820 0.7 0.1 0.9678177 5 ///// outbreaker results /// class: outbreaker_chains data.frame dimensions 21 rows, 22 columns ancestries not shown: alpha_2 - alpha_5 infection dates not shown: t_inf_1 - t_inf_5 intermediate generations not shown: kappa_1 - kappa_5 /// head // step post like prior a b pi alpha_1 1 1 -32.60111 -33.00495 0.4038415 0.7 0.1 0.9614177 NA 2 50 -36.80173 -38.03852 1.2367946 0.7 0.1 0.9872715 2 ... /// tail // step post like prior a b pi alpha_1 20 950 -33.63650 -34.27655 0.6400423 0.7 0.1 0.9239327 2 21 1000 -32.43451 -33.49219 1.0576820 0.7 0.1 0.9678177 5 ///// outbreaker results /// class: outbreaker_chains data.frame dimensions 21 rows, 22 columns ancestries not shown: alpha_1 - alpha_5 infection dates not shown: t_inf_1 - t_inf_5 intermediate generations not shown: kappa_1 - kappa_5 /// head // step post like prior 1 1 -32.60111 -33.00495 0.4038415 2 50 -36.80173 -38.03852 1.2367946 3 100 -31.05555 -32.21853 1.1629811 ... /// tail // step post like prior 19 900 -33.20696 -34.48840 1.2814403 20 950 -33.63650 -34.27655 0.6400423 21 1000 -32.43451 -33.49219 1.0576820 /// head // 1 2 3 4 5 1 0 0 0 0 1 2 0 0 0 0 1 3 0 0 0 0 1 ... /// tail // 1 2 3 4 5 19 0 0 0 0 1 20 0 0 0 0 1 21 0 0 0 0 1 Biggest cluster: 5 Cluster not shown: 2 to 5 /// head // 1 2 1 0 0 2 0 0 3 0 0 ... /// tail // 1 2 19 0 0 20 0 0 21 0 0 /// head // 1 2 3 4 5 1 0 0 0 0 1 2 0 0 0 0 1 3 0 0 0 0 1 ... /// tail // 1 2 3 4 5 19 0 0 0 0 1 20 0 0 0 0 1 21 0 0 0 0 1 ///// outbreaker custom priors /// class: custom_priors list number of items: 3 /// custom priors set to NULL (default used) // $pi NULL $a NULL $b NULL ///// outbreaker custom priors /// class: custom_priors list number of items: 3 /// custom priors // $pi function(param){ return(dnorm(x = param$pi, mean = config$prior_pi[1], sd = config$prior_pi[2], log = T)) } $a function(param){ return(dnorm(x = param$a, mean = config$prior_a[1], sd = config$prior_a[2], log = T)) } $b function(param){ return(dnorm(x = param$b, mean = config$prior_b[1], sd = config$prior_b[2], log = T)) } [ FAIL 0 | WARN 35 | SKIP 0 | PASS 197 ] [ FAIL 0 | WARN 35 | SKIP 0 | PASS 197 ] > > proc.time() user system elapsed 8.43 0.84 9.29