Monte Carlo sampler. More...
Public Member Functions | |
| RandomStream | getStream () |
| Returns the currently used random stream. | |
| int | getNumSimulationsPerSample () |
| Returns the number of times the model is simulated each time a sample is produced. | |
| int | getNumSamples () |
| Returns the number of samples produced each time the simulateRuns() method is called. | |
| void | setNumSamples (int nSamples) |
| Sets the number of samples. | |
| void | setStream (RandomStream stream) |
Use stream to produce random points. | |
| void | simulateRuns (MonteCarloModelDouble model, Tally collector) |
Package Functions | |
| public< E > void | simulateRuns (MonteCarloModel<? extends E > model, ObservationCollector< E > collector) |
Monte Carlo sampler.
The samples produced by this class are random and independent if the underlying random stream produces random and independent outputs.
Definition at line 15 of file MonteCarloSampler.java.
| int umontreal.ssj.mcqmctools.anova.MonteCarloSampler.getNumSamples | ( | ) |
Returns the number of samples produced each time the simulateRuns() method is called.
Implements umontreal.ssj.mcqmctools.anova.Sampler.
Definition at line 40 of file MonteCarloSampler.java.
| int umontreal.ssj.mcqmctools.anova.MonteCarloSampler.getNumSimulationsPerSample | ( | ) |
Returns the number of times the model is simulated each time a sample is produced.
Implements umontreal.ssj.mcqmctools.anova.Sampler.
Definition at line 35 of file MonteCarloSampler.java.
| RandomStream umontreal.ssj.mcqmctools.anova.MonteCarloSampler.getStream | ( | ) |
Returns the currently used random stream.
May be null.
Implements umontreal.ssj.mcqmctools.anova.RandomSampler.
Definition at line 30 of file MonteCarloSampler.java.
| void umontreal.ssj.mcqmctools.anova.MonteCarloSampler.setNumSamples | ( | int | nSamples | ) |
Sets the number of samples.
Definition at line 48 of file MonteCarloSampler.java.
| void umontreal.ssj.mcqmctools.anova.MonteCarloSampler.setStream | ( | RandomStream | stream | ) |
Use stream to produce random points.
Sets the internal random stream to stream.
Implements umontreal.ssj.mcqmctools.anova.RandomSampler.
Definition at line 58 of file MonteCarloSampler.java.
|
package |
Implements umontreal.ssj.mcqmctools.anova.Sampler.
Definition at line 66 of file MonteCarloSampler.java.
| void umontreal.ssj.mcqmctools.anova.MonteCarloSampler.simulateRuns | ( | MonteCarloModelDouble | model, |
| Tally | collector ) |
Implements umontreal.ssj.mcqmctools.anova.Sampler.
Definition at line 84 of file MonteCarloSampler.java.