Skip to content

Commit ad90ec8

Browse files
committed
format some example files
1 parent 2bc9e4b commit ad90ec8

File tree

7 files changed

+10
-3
lines changed

7 files changed

+10
-3
lines changed

JuliaBUGS/src/BUGSExamples/Volume_2/08_Cervix.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ model
4747
}
4848
"""
4949

50+
#! format: off
5051
data = (N = 2044,
5152
d = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
5253
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -442,6 +443,7 @@ data = (N = 2044,
442443

443444
inits = (beta0C = 0, beta = 0, q = 0.5, phi = [0.5 0.5; 0.5 0.5])
444445
inits_alternative = (beta0C = 1.0, beta = 1.0, q = 0.75, phi = [0.15 0.15; 0.15 0.15])
446+
#! format: on
445447

446448
reference_results = (
447449
var"beta" = (mean = 0.6156, std = 0.3406),

JuliaBUGS/src/BUGSExamples/Volume_2/11_Schools.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ model
7070
}
7171
"""
7272

73+
#! format: off
7374
data = (N = 1978, M = 38, mn = [0, 0, 0],
7475
prec = [0.0001 0 0; 0 0.0001 0; 0 0 0.0001],
7576
R = [0.1 0.005 0.005; 0.005 0.1 0.005; 0.005 0.005 0.1],
@@ -1573,6 +1574,7 @@ inits_alternative = (theta = 0.1, phi = 0, gamma = [1.0, 1.0, 1.0],
15731574
0 0 0
15741575
0 0 0
15751576
0 0 0])
1577+
#! format: on
15761578

15771579
reference_results = (
15781580
var"beta[1]" = (mean = 2.589E-4, std = 9.8E-5),

JuliaBUGS/src/BUGSExamples/Volume_2/16_Stagnant.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,4 @@ reference_results = (
5252
)
5353

5454
stagnant = Example(
55-
name, model_def, original, data, inits, inits_alternative, reference_results)
55+
name, model_def, original, data, inits, inits_alternative, reference_results)
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

JuliaBUGS/src/BUGSExamples/Volume_3/09_Hips4.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ model_def = @bugs begin
9292
for t in 2:N
9393
for s in 1:S
9494
var"pi"[
95-
n, k, t, s] = inprod(
95+
n, k, t, s] = inprod(
9696
var"pi"[n, k, t - 1, :], Lambda[n, k, t, :, s])
9797
end
9898
end

JuliaBUGS/src/BUGSExamples/Volume_4/11_Methadone.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,8 @@ end
5151
data_dict = JSON.parsefile(joinpath(readdir(), "methadone_data.json"))
5252
data = NamedTuple{Tuple([Symbol(key) for key in keys(data_dict)])}(Tuple([map(identity,
5353
val)
54-
for val in values(data_dict)]))
54+
for val in
55+
values(data_dict)]))
5556

5657
inits = (
5758
lambda = 0,

0 commit comments

Comments
 (0)