Index a cia_chains object
Examples
data <- bnlearn::learning.test
dag <- UniformlySampleDAG(colnames(data))
partitioned_nodes <- DAGtoPartition(dag)
scorer <- CreateScorer(
scorer = BNLearnScorer,
data = data
)
results <- SampleChains(10, partitioned_nodes, PartitionMCMC(), scorer)
results[[1]][1:3]
#> $state
#> $state[[1]]
#> partition node
#> 1 1 D
#> 2 2 A
#> 3 3 C
#> 4 4 E
#> 5 5 F
#> 6 6 B
#>
#> $state[[2]]
#> partition node
#> 1 1 D
#> 2 2 A
#> 3 3 C
#> 4 4 E
#> 5 5 F
#> 6 6 B
#>
#> $state[[3]]
#> partition node
#> 1 1 D
#> 2 2 A
#> 3 3 C
#> 4 4 E
#> 5 5 F
#> 6 6 B
#>
#>
#> $log_score
#> [1] -24189.72 -24189.72 -24189.72
#>
#> $proposal_info
#> $proposal_info[[1]]
#> $proposal_info[[1]]$proposal_used
#> [1] "swap_node"
#>
#>
#> $proposal_info[[2]]
#> $proposal_info[[2]]$proposal_used
#> [1] "node_move"
#>
#>
#> $proposal_info[[3]]
#> $proposal_info[[3]]$proposal_used
#> [1] "swap_node"
#>
#>
#>
#> $mcmc_info
#> $mcmc_info[[1]]
#> $mcmc_info[[1]]$accept
#> [1] FALSE
#>
#> $mcmc_info[[1]]$white_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[1]]$black_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[1]]$jac
#> [1] 0
#>
#> $mcmc_info[[1]]$mhr
#> [1] -122.0319
#>
#>
#> $mcmc_info[[2]]
#> $mcmc_info[[2]]$accept
#> [1] FALSE
#>
#> $mcmc_info[[2]]$white_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[2]]$black_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[2]]$jac
#> [1] 0
#>
#> $mcmc_info[[2]]$mhr
#> [1] -184.7172
#>
#>
#> $mcmc_info[[3]]
#> $mcmc_info[[3]]$accept
#> [1] FALSE
#>
#> $mcmc_info[[3]]$white_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[3]]$black_obeyed
#> [1] TRUE
#>
#> $mcmc_info[[3]]$jac
#> [1] 0
#>
#> $mcmc_info[[3]]$mhr
#> [1] -137.395
#>
#>
#>
#> attr(,"class")
#> [1] "cia_chain"