title: How do I check if my (x,y) are gaussian sampled?
body: <p>I want to get (x,y) of 100 particles (x and y being initial conditions) sampled from a 2D gaussian where the 2-D gaussian is a product of two 1-D Gaussians so that (x,y) corresponds to a point on the surface of a 3D gaussian figure.</p>
  <p>I did the following for that:</p>
  <pre><code>&quot;r&quot;
   mu=np.random.uniform(0,1,10000)
   r=[sqrt(-2*log(1-i)) for i in mu]
   &quot;theta&quot;
   eta=np.random.uniform(0,1,10000)
   theta=2*pi*eta;
   cuz=[cos(i) for i in theta]
   suz=[sin(i) for i in theta]
   &quot;initial conditions&quot;
   Zinitial=[a*b for a,b in zip(r,cuz)];
   Pinitial=[a*b for a,b in zip(r,suz)];
  </code></pre>
  <p>I now want to confirm whether these data points actually are gaussian sampled by drawing contour or 3-d plot.</p>
  <p>How can I do that?</p>
  <p>Now consider the following code:
  Consider the following code:</p>
  <pre><code>def gauss2d(mu,sigma):
      x=gauss(mu,sigma);
      y=gauss(mu,sigma);
   return(x,y)
  ic=[];
  for i in range(50):
      ic.append(gauss2d(0,1))
      x=[x[0] for x in ic];
  t=np.linspace(-2,2,50)
  plt.plot(x,t)
  </code></pre>
  <p>This is what I get.
  <a href="https://i.stack.imgur.com/g3US5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/g3US5.png" alt="enter image description here" /></a></p>
  <p>Why doesn't it look like a gaussian curve?</p>
  <p>My plots of this and the one I did with a different method match but both don't look like a gaussian but the plot like above.</p>