Commit 604ea30f authored by Poppy Miller's avatar Poppy Miller
Browse files

Fixed problem with initial starting values for q being in the wrong order....

Fixed problem with initial starting values for q being in the wrong order. Changed update lists to a single list to remove mcmc func closures. Added names to updaters so they can be identified for the acceptance rates. Added some more help file notes. NOT WORKING CORRECTLY for sim data.
parent 614b5ad1
This diff is collapsed.
......@@ -195,9 +195,10 @@ AdaptiveDirMRW <- R6::R6Class(
batchsize = NA,
node = NA,
tune = NA,
name = NA,
initialize = function(node, toupdate = function() 1:length(node$getData()),
tune = rep(0.1, length(node$getData())),
batchsize = 50) {
batchsize = 50, name = "name") {
self$toupdate = toupdate
self$naccept <- rep(0, length(node$getData()))
self$ncalls <- 0
......@@ -206,6 +207,7 @@ AdaptiveDirMRW <- R6::R6Class(
self$batchsize <- batchsize
self$tune <- tune
self$node <- node
self$name <- name
},
update = function() {
self$ncalls <- self$ncalls + 1
......@@ -312,9 +314,10 @@ AdaptiveLogDirMRW <- R6::R6Class(
batchsize = NA,
node = NA,
tune = NA,
name = NA,
initialize = function(node, toupdate = function() 1:length(node$getData()),
tune = rep(0.1, length(node$getData())),
batchsize = 50) {
batchsize = 50, name = "name") {
self$toupdate = toupdate
self$naccept <- rep(0, length(node$getData()))
self$ncalls <- rep(0, length(node$getData()))
......@@ -323,6 +326,7 @@ AdaptiveLogDirMRW <- R6::R6Class(
self$batchsize <- batchsize
self$tune <- tune
self$node <- node
self$name <- name
},
update = function() {
updIdx <- self$toupdate()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment