Skip to content

Commit 6b5702a

Browse files
committed
merged the new master, resolved conflicts
2 parents 96fc1aa + a9684fd commit 6b5702a

File tree

16 files changed

+35
-469
lines changed

16 files changed

+35
-469
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@ doc/config/latexextras.sty
1414
doc/config/mtocpp_filter.sh
1515
DRAMToolbox
1616
*.asv
17-
examples\RAmPART_examples\results
17+
examples/RAmPART_examples/results
1818

@PestoOptions/PestoOptions.m

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -419,9 +419,9 @@
419419
end
420420

421421
% Add required subclasses
422-
% obj.MCMC = PestoSamplingOptions();
423-
% obj.HO = HOOptions;
424-
% obj.HO.foldername = obj.foldername;
422+
obj.MCMC = PestoSamplingOptions();
423+
obj.HO = HOOptions;
424+
obj.HO.foldername = obj.foldername;
425425

426426
end
427427

@PestoSamplingOptions/PestoSamplingOptions.m

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,10 @@
6969
saveFileName = '';
7070
saveEach = 0;
7171

72-
% Parallel Tempering Options, an instance of PTOptions
73-
PT;
72+
% Parallel Tempering Options, an instance of PTOptions - this
73+
% instance is also used for initalization in case no algorithm was
74+
% specified
75+
PT = PTOptions();
7476

7577
% Parallel Hierarchical Sampling options, an instance of PHSOptions
7678
PHS;
@@ -322,20 +324,22 @@
322324
end
323325

324326
else
325-
warning('No user-provided initial point found. Setting Initial points randomly.')
327+
warning('No user-provided initial point found. Setting Initial points randomly.')
328+
par.min = par.min(:);
329+
par.max = par.max(:);
326330
switch this.samplingAlgorithm
327331
case {'DRAM','MALA'}
328-
this.theta0 = bsxfun(@plus, par.min', ...
329-
bsxfun(@times, par.max' - par.min', rand(par.number,1)))';
332+
this.theta0 = bsxfun(@plus, par.min, ...
333+
bsxfun(@times, par.max - par.min, rand(par.number,1)));
330334
case 'PT'
331-
this.theta0 = bsxfun(@plus, par.min', ...
332-
bsxfun(@times, par.max' - par.min', rand(par.number,this.PT.nTemps)))';
335+
this.theta0 = bsxfun(@plus, par.min, ...
336+
bsxfun(@times, par.max - par.min, rand(par.number,this.PT.nTemps)));
333337
case 'PHS'
334-
this.theta0 = bsxfun(@plus, par.min', ...
335-
bsxfun(@times, par.max' - par.min', rand(par.number,this.PHS.nChains)))';
338+
this.theta0 = bsxfun(@plus, par.min, ...
339+
bsxfun(@times, par.max - par.min, rand(par.number,this.PHS.nChains)));
336340
case 'RAMPART'
337-
this.theta0 = bsxfun(@plus, par.min', ...
338-
bsxfun(@times, par.max' - par.min', rand(par.number,this.RAMPART.nTemps)))';
341+
this.theta0 = bsxfun(@plus, par.min, ...
342+
bsxfun(@times, par.max - par.min, rand(par.number,this.RAMPART.nTemps)));
339343
end
340344
end
341345
if ~isempty(this.sigma0)

examples/RAmPART_examples/Bachmann_JakStat/logLikelihood_Bachmann.m renamed to examples/RAmPART_examples/Bachmann_JakStat/logLikelihood_Bachmann_rampart.m

File renamed without changes.

examples/RAmPART_examples/Gauss/mainExampleGauss.m

Lines changed: 0 additions & 164 deletions
This file was deleted.

examples/RAmPART_examples/Gauss/plot_Gauss_LH.m

Lines changed: 0 additions & 28 deletions
This file was deleted.

examples/RAmPART_examples/Gauss/plot_gaussian_ellipsoid.m

Lines changed: 0 additions & 114 deletions
This file was deleted.

examples/RAmPART_examples/Gauss/simulateGaussLLH.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
% distributed
3737
m = length(par);
3838
for i = p+1:m
39-
llh = llh + log(normpdf(par(i),25,1));
39+
llh = llh - log(1*sqrt(2*pi)) - 0.5 * ((par(i)-25)/1)^2;
4040
end
4141

4242
end

examples/RAmPART_examples/JakStat/logLikelihoodJakstat.m renamed to examples/RAmPART_examples/JakStat/logLikelihoodJakstat_rampart.m

File renamed without changes.

examples/RAmPART_examples/RafMekErk/logLikelihoodRafMekErk.m renamed to examples/RAmPART_examples/RafMekErk/logLikelihoodRafMekErk_rampart.m

File renamed without changes.

0 commit comments

Comments
 (0)