The tag has no wiki summary.

learn more… | top users | synonyms

2
votes
2answers
76 views

Python: What is a good way to generate a 1D particle field with a gaussian distribution?

If I have N particles how do I assign their x values so that the end result is Gaussian distribution. i.e. particles near the ends are more spread out than particles near the center.
0
votes
0answers
35 views

Getting to a number as an addition of products (x*constant)

I have a list of constants and a list of targets. For each target, I want to find a set of probabilities (3-6 values != 0) such that the sum of constant^i * prob^i is close to the target. I get ...
2
votes
2answers
64 views

Extracting time scales information from empirical cumulative distribution function

I have a stochastic process (a Markov chain actually) that has two absorbing states. I am using a difference equation to calculate the first passage time to either of the absorbing states. There are ...
1
vote
1answer
149 views

Coding complex equations into C++

I have here equations from a paper by E. Bradlow. They're for counting the events in a Weibull-distributed data set. $$\begin{align} \Pr(N(t)=n) &= \sum_{j=n}^\infty{\frac{(-1)^{j+n}(\lambda ...
1
vote
2answers
2k views

How to plot probability density function in MATLAB?

I'm trying to get a frequency plot, or PDF (probability density function) plot for my biometrics project in MATLAB. I have two vectors genuine_scores and ...
2
votes
2answers
232 views

visualization of 3D probability flow

I have a master equation for $P(N_A^+,N_B^+,N_C^+,t)$, with $N_A^+,N_B^+,N_C^+$ all discrete. The numerical integration is done by this Matlab program using Euler's method. Despite the crude Euler's ...
2
votes
0answers
22 views

Approximate convolution of independent Beta variates?

Is there a way to approximate the convolution of Beta variables? Specifically, I am trying to find an approximation to $g(x_0)$: $$g(x_0) = \int \delta(x_0-\sum_{i=1}^{n} a_i x_i) \prod_{i=1}^{n} ...
2
votes
3answers
91 views

Hash in set probability?

First off I would like to mention that I am absolutely terrible at statistics... so bear with me please. The question: a sha1 hash is a hexadecimal string of 40 characters, the largest number being: ...
8
votes
2answers
1k views

How do I plot the surface of a 4D plot?

I am trying to plot the wave function for a particle in a 3D box. This requires me to plot 4 variables: x, y, z axes and the probability density function. The probability density function is: ...
2
votes
1answer
103 views

Multiple independent random number streams

Having multiple streams of pseudo-random numbers known to be independent and with a uniform distribution I want to do Monte Carlo simulations in parallel. In other words, one thread will have a ...
4
votes
3answers
348 views

How to sample numerically from an arbitrary smooth distribution?

I'm given a smooth probability density function via its values on a reasonable fine grid. I assume that cubic spline interpolation (or cubic spline interpolation of the logarithm of the density) will ...
2
votes
1answer
155 views

Chinese Restaurant Process… Why?

I recently started to study non-parametric clustering methods and I come across to CRP. After reading all the material I found on the web there is one thing which is not completely clear to me: which ...
3
votes
2answers
412 views

Efficient computation of Markov chain transition probability matrix

Consider a continuous Markov chain $X=(X_t)$ on a finite state space and let $Q$ be the (given) transition rate matrix. This matrix is very sparse, with non-zero values on 3 diagonals only (so from ...
0
votes
1answer
72 views

sum of random variables, probability 101

Consider $n$ integer-valued and independent random variables $e_1, e_2, \dots, e_n$ with known distribution functions $m_1, m_2, \dots, m_n$. Let's denote with $E^{1..n}$ the random variable given by ...
2
votes
0answers
78 views

function over conditional probability

I need to create a scoring model out of estimated conditional probability functions for two events, A and B. Let 0.5 be the threshold value. Ideally, the probability is in the interval $[0,0.5)$ for A ...
5
votes
3answers
274 views

Computing the PDF of a quadratic function of two random variables

Given the function $\mathcal{M} = g + Ah + Bh^2$ where $A$ and $B$ are constants and $g$ and $h$ are random variables with their distributions $f_G(g)$ and $f_H(h)$ known, is it possible to compute ...
4
votes
1answer
186 views

Convert ODE into discrete probabilistic model

how can I turn an ODE equation into a discrete probabilistic model? I take for example the Verhulst equation for the growth of a population. $$\frac{dP}{dt} = rP(1-P/K)$$ I was thinking to simulate ...
8
votes
2answers
2k views

Define custom probability density function in Python

Is there a way, using some stablished or known Python package (i.e. SciPy) to define my own probability density function (without any prior data, just $f(x) = a x + b$), so I can then make ...
5
votes
1answer
709 views

How can I generate half-normal variates in MATLAB?

I can find the random('normal', 0, 1, 10000,1) command in MATLAB but it generates half-normal variates. I would like to generate random half-normal variates. The ...
9
votes
3answers
830 views

Drawing samples from a finite mixture of normal distributions?

After some Bayesian update steps, I am left with a posterior distribution of the form of a mixture of normal distributions,$$\Pr(\theta| \text{data} ) = \sum_{i=1}^k w_i N(\mu_i, \sigma^2).$$ That is, ...