ParaMonte MATLAB 3.0.0
Parallel Monte Carlo and Machine Learning Library
See the latest version documentation.
FileContentsChainDRAM.m
Go to the documentation of this file.
1%> \brief
2%> This is the base class for generating objects that contain the contents of a chain
3%> file generated by a sampler of superclass [pm.sampling.Paradram](@ref Paradram).<br>
4%>
5%> \details
6%> This class is meant to be primarily internally used by the ParaMonte MATLAB library samplers.<br>
7%> This class merely adds a number of visualizations to its superclass which are
8%> specific to the [pm.sampling.Paradram](@ref Paradram) sampler.<br>
9%>
10%> \note
11%> See also the documentation of the class constructor
12%> [pm.sampling.FileContentsChainDRAM::FileContentsChainDRAM](@ref FileContentsChainDRAM::FileContentsChainDRAM).<br>
13%>
14%> \note
15%> See also the documentation of the superclass [pm.sampling.FileContentsChainMCMC](@ref FileContentsChainMCMC).<br>
16%>
17%> \note
18%> See below for information on the attributes (properties).<br>
19%>
20%> \note
21%> See below for information on the class methods.<br>
22%>
23%> \final{FileContentsChainDRAM}
24%>
25%> \author
26%> \FatemehBagheri, May 20 2024, 1:25 PM, NASA Goddard Space Flight Center (GSFC), Washington, D.C.<br>
27%> \AmirShahmoradi, May 16 2016, 9:03 AM, Oden Institute for Computational Engineering and Sciences (ICES), UT Austin<br>
28classdef FileContentsChainDRAM < pm.sampling.FileContentsChainMCMC
29
30 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
31
32 properties(Access = public)
33 end
34
35 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
36
37 properties(Hidden)
38 end
39
40 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
41
42 methods(Access = public)
43
44 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
45
46 %> \brief
47 %> Return a scalar object of class [pm.sampling.FileContentsChainDRAM](@ref FileContentsChainDRAM).<br>
48 %>
49 %> \details
50 %> This is the constructor of the class [pm.sampling.FileContentsChainDRAM](@ref FileContentsChainDRAM).<br>
51 %>
52 %> \param[in] file : The input scalar MATLAB string containing the path or web address to an external file.<br>
53 %> \param[in] silent : See the corresponding argument of the superclass constructor [pm.sampling.FileContentsChainMCMC::FileContentsChainMCMC](@ref FileContentsChainMCMC::FileContentsChainMCMC).<br>
54 %> (**optional**. The default is set by the superclass constructor [pm.sampling.FileContentsChainMCMC::FileContentsChainMCMC](@ref FileContentsChainMCMC::FileContentsChainMCMC).)
55 %> \param[in] sep : See the corresponding argument of the superclass constructor [pm.sampling.FileContentsChainMCMC::FileContentsChainMCMC](@ref FileContentsChainMCMC::FileContentsChainMCMC).<br>
56 %> (**optional**. The default is set by the superclass constructor [pm.sampling.FileContentsChainMCMC::FileContentsChainMCMC](@ref FileContentsChainMCMC::FileContentsChainMCMC).)
57 %> \param[in] format : The input scalar MATLAB string containing the reading format of the Markov chain:
58 %> <ol>
59 %> <li> If ``format`` is set to ``"compact"``,
60 %> the Markov chain will be read in compact (weighted) format.<br>
61 %> This format is fast and potentially highly memory-efficient.<br>
62 %> Beware that this format does not necessarily generate a compact chain
63 %> when the specified chain file is already written in verbose format.<br>
64 %> <li> If ``format`` is set to ``"verbose"``,
65 %> the Markov chain will be read in verbose (unweighted or unrolled) format.<br>
66 %> While the chain in this format is the **actual Markov chain**,
67 %> reading the chain in this format can be highly inefficient as it
68 %> can use too much memory for high-dimensional density functions.<br>
69 %> </ol>
70 %> (**optional**, default = ``"compact"``.)
71 %>
72 %> \return
73 %> ``self`` : The output scalar object of class [pm.sampling.FileContentsChainDRAM](@ref FileContentsChainDRAM).<br>
74 %>
75 %> \interface{FileContentsChainDRAM}
76 %> \code{.m}
77 %>
78 %> contents = pm.sampling.FileContentsChainDRAM(file)
79 %> contents = pm.sampling.FileContentsChainDRAM(file, [])
80 %> contents = pm.sampling.FileContentsChainDRAM(file, silent)
81 %> contents = pm.sampling.FileContentsChainDRAM(file, [], sep)
82 %> contents = pm.sampling.FileContentsChainDRAM(file, silent, sep)
83 %>
84 %> \endcode
85 %>
86 %> \example{FileContentsChainDRAM}
87 %> \include{lineno} example/sampling/FileContentsChainDRAM/main.m
89 %> <br><br>
90 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour.1.png width=700
91 %> <br><br>
92 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour.2.png width=700
93 %> <br><br>
94 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour.3.png width=700
95 %> <br><br>
96 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour3.1.png width=700
97 %> <br><br>
98 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour3.2.png width=700
99 %> <br><br>
100 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contour3.3.png width=700
101 %> <br><br>
102 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contourf.1.png width=700
103 %> <br><br>
104 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contourf.2.png width=700
105 %> <br><br>
106 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.contourf.3.png width=700
107 %> <br><br>
108 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histfit.1.png width=700
109 %> <br><br>
110 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histfit.2.png width=700
111 %> <br><br>
112 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histfit.3.png width=700
113 %> <br><br>
114 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram.1.png width=700
115 %> <br><br>
116 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram.2.png width=700
117 %> <br><br>
118 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram.3.png width=700
119 %> <br><br>
120 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram2.1.png width=700
121 %> <br><br>
122 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram2.2.png width=700
123 %> <br><br>
124 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.histogram2.3.png width=700
125 %> <br><br>
126 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line.1.png width=700
127 %> <br><br>
128 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line.2.png width=700
129 %> <br><br>
130 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line.3.png width=700
131 %> <br><br>
132 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line3.1.png width=700
133 %> <br><br>
134 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line3.2.png width=700
135 %> <br><br>
136 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.line3.3.png width=700
137 %> <br><br>
138 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter.1.png width=700
139 %> <br><br>
140 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter.2.png width=700
141 %> <br><br>
142 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter.3.png width=700
143 %> <br><br>
144 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter3.1.png width=700
145 %> <br><br>
146 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter3.2.png width=700
147 %> <br><br>
148 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.lineScatter3.3.png width=700
149 %> <br><br>
150 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter.1.png width=700
151 %> <br><br>
152 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter.2.png width=700
153 %> <br><br>
154 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter.3.png width=700
155 %> <br><br>
156 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter3.1.png width=700
157 %> <br><br>
158 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter3.2.png width=700
159 %> <br><br>
160 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.cascade.scatter3.3.png width=700
161 %> <br><br>
162 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.contour.png width=700
163 %> <br><br>
164 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.contour3.png width=700
165 %> <br><br>
166 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.contourf.png width=700
167 %> <br><br>
168 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.histfit.png width=700
169 %> <br><br>
170 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.histogram.png width=700
171 %> <br><br>
172 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.histogram2.png width=700
173 %> <br><br>
174 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.line.png width=700
175 %> <br><br>
176 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.line3.png width=700
177 %> <br><br>
178 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.lineScatter.png width=700
179 %> <br><br>
180 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.lineScatter3.png width=700
181 %> <br><br>
182 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.scatter.png width=700
183 %> <br><br>
184 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.plot.scatter3.png width=700
185 %> <br><br>
186 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.contour.png width=700
187 %> <br><br>
188 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.contour3.png width=700
189 %> <br><br>
190 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.contourf.png width=700
191 %> <br><br>
192 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.histfit.png width=700
193 %> <br><br>
194 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.histogram.png width=700
195 %> <br><br>
196 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.histogram2.png width=700
197 %> <br><br>
198 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.line.png width=700
199 %> <br><br>
200 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.line3.png width=700
201 %> <br><br>
202 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.lineScatter.png width=700
203 %> <br><br>
204 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.lineScatter3.png width=700
205 %> <br><br>
206 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.scatter.png width=700
207 %> <br><br>
208 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.tile.scatter3.png width=700
209 %> <br><br>
210 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.triplex.lshc2.png width=700
211 %> <br><br>
212 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.triplex.lshc3.png width=700
213 %> <br><br>
214 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.triplex.lshcf.png width=700
215 %> <br><br>
216 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.proposalAdaptation.scatter.png width=700
217 %> <br><br>
218 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.proposalAdaptation.line.png width=700
219 %> <br><br>
220 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.meanAcceptanceRate.line.png width=700
221 %> <br><br>
222 %> \image html example/sampling/FileContentsChainDRAM/FileContentsChainDRAM.burninLocation.line.png width=700
223 %>
224 %> \final{FileContentsChainDRAM}
225 %>
226 %> \author
227 %> \FatemehBagheri, May 20 2024, 1:25 PM, NASA Goddard Space Flight Center (GSFC), Washington, D.C.<br>
228 %> \AmirShahmoradi, May 16 2016, 9:03 AM, Oden Institute for Computational Engineering and Sciences (ICES), UT Austin<br>
229 function self = FileContentsChainDRAM(file, silent, sep, format)
230
231 if nargin < 4
232 format = [];
233 end
234
235 if nargin < 3
236 sep = [];
237 end
238
239 if nargin < 2
240 silent = [];
241 end
242
243 self = self@pm.sampling.FileContentsChainMCMC(file, silent, sep, format);
244
245 %%%%
246 %%%% Compute the ParaDRAM-specific statistics.
247 %%%%
248
249 self.setstats();
250
251 %%%%
252 %%%% Add the ParaDRAM-specific visualizations.
253 %%%%
254
255 self.setvis();
256
257 end
258
259 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
260
261 end
262
263 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
264
265end
This is the base class for generating objects that contain the contents of a chain file generated by ...
function FileContentsChainDRAM(in file, in silent, in sep, in format)
Return a scalar object of class pm.sampling.FileContentsChainDRAM.
This is the base class for generating objects that contain the contents of a chain file generated by ...
This is the ParaDRAM class for generating instances of serial and parallel Delayed-Rejection Adaptive...
Definition: Paradram.m:18
function statistics()
Return a scalar MATLAB logical that is true if and only if the current installation of MATLAB contain...
function verbose(in cmat, in dim, in weight)
Return a MATLAB double, cell, or table matrix whose rows or columns are unrolled according to a presp...
function which(in vendor)
Return the a MATLAB string containing the path to the first mpiexec executable binary found in system...