LogisticNormal is the class for the usual logistic regression model with
a bivariate normal prior on the intercept and slope.
Details
The covariate is the natural logarithm of the dose \(x\) divided by the reference dose \(x*\), i.e.: $$logit[p(x)] = alpha0 + alpha1 * log(x/x*),$$ where \(p(x)\) is the probability of observing a DLT for a given dose \(x\). The prior $$(alpha0, alpha1) ~ Normal(mean, cov).$$
Examples
# Define the dose-grid.
empty_data <- Data(doseGrid = c(1, 3, 5, 10, 15, 20, 25, 40, 50, 80, 100))
my_model <- LogisticNormal(
mean = c(-0.85, 1),
cov = matrix(c(1, -0.5, -0.5, 1), nrow = 2)
)
my_options <- McmcOptions(burnin = 10, step = 2, samples = 100)
samples <- mcmc(empty_data, my_model, my_options)
samples
#> An object of class "Samples"
#> Slot "data":
#> $alpha0
#> [1] -2.340131855 -1.101269773 -1.166113717 -2.408639618 0.025387599
#> [6] 0.383326868 -3.549434060 -0.331145396 -1.379215137 -0.955975125
#> [11] -0.784898159 -1.253269187 -1.445455143 -0.815082619 -0.582551350
#> [16] -3.336837735 -2.799487997 0.850082421 -1.337395945 -0.536545140
#> [21] 0.303465825 -2.016517309 -2.050202142 -1.342355176 -1.916535664
#> [26] -0.700983780 -0.843067324 -1.847374593 -1.321957554 -1.038221493
#> [31] -0.311497267 -2.569897507 -0.991323738 -0.889499404 0.703523164
#> [36] -1.167505994 -0.018742191 -1.242087093 -1.285426537 -1.630612379
#> [41] -0.803889900 -1.065616006 0.467454981 0.465777451 -0.005154571
#> [46] -2.488022418 -1.534366717 -1.777327686 -1.795710315 -1.009855866
#> [51] -0.232552851 -0.201816969 0.029513937 -1.081178368 -1.098242691
#> [56] -1.367581691 -3.193730735 -1.122425176 -2.033604033 -2.038209999
#> [61] -0.371511634 -1.952157586 -1.285099319 -0.408026122 0.174499883
#> [66] -1.843202171 -1.327465396 -0.112784449 -1.259452484 -1.137322961
#> [71] -1.970894262 -0.684010378 -2.518420060 -1.933332082 -0.464202045
#> [76] -0.661114484 -0.205251794 -1.738377749 -1.024072184 -0.563885686
#> [81] -1.287187390 0.090299772 -1.913330282 -1.005827591 -2.420592555
#> [86] -0.889120065 -2.146610106 -0.088631254 -0.701535529 -1.500497309
#> [91] -0.132492199 1.268038963 -1.587332135 -1.498055505 0.262911457
#> [96] -0.217729616 1.411819264 -0.685845274 -0.203796710 0.111649592
#>
#> $alpha1
#> [1] 1.01398841 1.56566128 -0.70237537 2.29234015 -0.53435720 1.71652381
#> [7] 1.19530803 1.51547497 1.79866938 1.48153848 1.66616656 1.71483075
#> [13] 2.41042114 1.55021500 0.17934873 2.58297580 2.98709153 -0.66868091
#> [19] 2.19307827 1.56814853 1.28745685 1.04816322 2.73207674 0.85164066
#> [25] 1.03611422 2.01264245 2.27095088 3.07471308 -0.49740236 1.29643463
#> [31] -0.55420091 2.93383316 0.99886801 1.69949281 -0.49666672 0.20345308
#> [37] 1.85829535 0.48500033 -0.50146935 2.73101717 1.28343722 0.82025186
#> [43] 0.78736783 1.44383324 0.31418922 2.27750346 2.74722500 0.73282653
#> [49] 0.64588078 0.81273916 0.07739871 0.91184640 1.02600750 2.77677847
#> [55] 0.18166404 2.02227440 1.66960111 0.23255165 2.51727613 0.76073368
#> [61] 3.00083691 0.55305830 0.95857150 1.39803487 0.93644781 1.35244504
#> [67] 2.18225990 -1.12737965 1.76220336 1.59148503 3.23293586 1.70854891
#> [73] 0.22922087 1.48910859 0.96334508 1.11322484 0.78179463 1.96134353
#> [79] -0.99592652 2.09198325 -0.04713409 1.67449636 1.76566497 1.45598201
#> [85] 1.02047017 0.69328814 1.19256669 0.63796497 0.33673949 0.38050675
#> [91] 1.19062618 -1.73114647 2.11635031 2.16218417 0.56861246 0.31045862
#> [97] 1.28056412 -0.06391553 1.33886636 0.82044731
#>
#>
#> Slot "options":
#> An object of class "McmcOptions"
#> Slot "iterations":
#> [1] 210
#>
#> Slot "burnin":
#> [1] 10
#>
#> Slot "step":
#> [1] 2
#>
#> Slot "rng_kind":
#> [1] NA
#>
#> Slot "rng_seed":
#> [1] NA
#>
#>
