Skip to main content

New answers tagged

7 votes
Accepted

How to use Mathematica to find the maximum expected value of multiple normal distributions?

This is only a partial answer in that it only provides the means for $n=2$ through $n=5$. With $n>6$ Mathematica only returns the input. ...
JimB's user avatar
  • 41.8k
6 votes

Plot fails to plot. What am I doing wrong?

If you just need a display of an approximation of the pdf, random sampling with a large sample and a SmoothHistogram works fine for your particular distribution. <...
JimB's user avatar
  • 41.8k
2 votes

How to select elements from a list using another list

"Using Select with ContainsAny Last /@ Select[list1, ContainsAny @ list2] {19, 18, 17,...
eldo's user avatar
  • 74.4k
1 vote

How to find the regression line equation of these two groups of data and draw the scatter diagram and regression line?

I post this to illustrate versatility of Mathematica/Wolfram Language: ...
ubpdqn's user avatar
  • 61.6k
1 vote

Integrating the derivative of a distribution via Expectation

This seems to work: dist = BinormalDistribution[1/2] pdf = PDF[dist, {x1, x2}] exp = Simplify[x1*D[pdf, x1]/pdf] Expectation[exp, {x1, x2} \[Distributed] dist] Is ...
Sjoerd Smit's user avatar
  • 23.6k
0 votes

Integrating the derivative of a distribution via Expectation

One trick is to work with the equality $$ \int g(x) \frac{\partial f(x)}{\partial x} dx = \int g(x) \frac{\partial \log f(x)}{\partial x} f(x) dx$$ So now you're just computing the expected value of $...
Sam's user avatar
  • 1
1 vote

Integrating the derivative of a distribution via Expectation

...
Bob Hanlon's user avatar
  • 159k
1 vote

How to find the regression line equation of these two groups of data and draw the scatter diagram and regression line?

v1 = {0.04, 0.06, 0.04, 0.08, 0.08, 0.05, 0.05, 0.07, 0.07, 0.06}; v2 = {0.25, 0.4, 0.22, 0.54, 0.51, 0.34, 0.36, 0.46, 0.42, 0.4}; data = Transpose[{v1, v2}]; ...
eldo's user avatar
  • 74.4k
1 vote

Obtaining formula of $E[X^T A X B X^T CX]$ for Gaussian $X$

I wrote a program (tensorgrad) that allows doing this kind of computation. It uses Gaussian integration by parts (basically the same as Isserlis' theorem), and allows easily computing: \begin{align} E[...
Thomas Ahle's user avatar

Top 50 recent answers are included