@@ -24,12 +24,7 @@ and how much the true posterior in the unconstrained space resembles a Gaussian.
24
24
25
25
## Configuration
26
26
27
- This method takes 2 arguments:
28
-
29
- - ` jacobian ` - Whether or not the
30
- [ Jacobian adjustment] ( https://mc-stan.org/docs/stan-users-guide/reparameterization.html )
31
- should be included in the gradient. The default value is ` true ` (include adjustment).
32
- (Note: in optimization, the default value is ` false ` , for historical reasons.)
27
+ This method takes several arguments:
33
28
34
29
- ` mode ` - Input file of parameters values on the constrained scale.
35
30
When Stan's ` optimize ` method is used to estimate the modal values,
@@ -38,6 +33,16 @@ run with default settings, i.e., the input is the MLE estimate;
38
33
if ` optimize ` was run with argument ` jacobian=true ` , then the ` laplace `
39
34
method default setting, ` jacobian=true ` , should be used.
40
35
36
+ - ` jacobian ` - Whether or not the
37
+ [ Jacobian adjustment] ( https://mc-stan.org/docs/stan-users-guide/reparameterization.html )
38
+ should be included in the gradient. The default value is ` true ` (include adjustment).
39
+ (Note: in optimization, the default value is ` false ` , for historical reasons.)
40
+
41
+ - ` draws ` - How many total draws to return. The default is $1000$.
42
+
43
+ - ` calculate_lp ` - Whether to calculate the log probability of the model at
44
+ each draw. If this is ` false ` , the ` log_p__ ` column of the output will be
45
+ entirely ` nan ` . The default value is ` true ` .
41
46
42
47
43
48
## CSV output
@@ -53,6 +58,12 @@ These can be used for diagnostics and importance sampling.
53
58
54
59
- Output columns for all model parameters on the constrained scale.
55
60
61
+ ## Diagnostic file outputs
62
+
63
+ If requested with ` output diagnostic_file= ` , a JSON file will be
64
+ created which contains the log density, the gradient, and the Hessian
65
+ of the log density evaluated at the mode.
66
+
56
67
## Example
57
68
58
69
To get an approximate estimate of the mode and standard deviation of the
@@ -83,7 +94,7 @@ The header and first few data rows of the output sample are shown below.
83
94
84
95
```
85
96
# stan_version_major = 2
86
- # stan_version_minor = 31
97
+ # stan_version_minor = 35
87
98
# stan_version_patch = 0
88
99
# model = bernoulli_model
89
100
# start_datetime = 2022-12-20 01:01:14 UTC
@@ -92,6 +103,7 @@ The header and first few data rows of the output sample are shown below.
92
103
# mode = bernoulli_lbfgs.csv
93
104
# jacobian = true (Default)
94
105
# draws = 1000 (Default)
106
+ # calculate_lp = true (default)
95
107
# id = 1 (Default)
96
108
# data
97
109
# file = examples/bernoulli/bernoulli.data.json
0 commit comments