예제 #1
0
        /// <summary>
        /// Returns a new instance of the <see cref="BernoulliIntegerSubset"/> class from a sparse list of Bernoulli distributions.
        /// </summary>
        /// <param name="bernoullis">The sparse list of Bernoulli distributions.</param>
        /// <param name="tolerance">The tolerance.</param>
        /// <returns>The new <see cref="BernoulliIntegerSubset"/> instance.</returns>
        public static BernoulliIntegerSubset FromSparseList(ISparseList <Bernoulli> bernoullis, double tolerance)
        {
            var result = new BernoulliIntegerSubset();

            result.SparseBernoulliList = SparseBernoulliList.FromSparseList(bernoullis, tolerance);
            return(result);
        }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BernoulliIntegerSubset"/> class from a sparse list of <see cref="Bernoulli"/> distributions.
 /// </summary>
 /// <param name="bernoullis">The sparse list of Bernoulli distributions.</param>
 protected BernoulliIntegerSubset(ISparseList <Bernoulli> bernoullis)
 {
     SparseBernoulliList = SparseBernoulliList.FromSparseList(bernoullis);
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BernoulliIntegerSubset"/> class from a sparse list of Bernoulli distributions.
 /// </summary>
 /// <param name="bernoullis">The sparse list of Bernoulli distributions.</param>
 /// <param name="tolerance">The tolerance.</param>
 protected BernoulliIntegerSubset(ISparseList <Bernoulli> bernoullis, double tolerance)
 {
     SparseBernoulliList = SparseBernoulliList.FromSparseList(bernoullis, tolerance);
 }