title: Probability Density Function using Python
body: <p>I have a data set which has values in the range of 1e-2 and 1e-3. I have the following code to obtain the values and plot the distribution.</p>
  
  <pre><code>def get_pdf(data):
      a = np.array(data)
      ex = st.gaussian_kde(a)
      x = np.linspace(0, max(data), max(data))
      y = ag(ex)
      return x, y
  
  data_list = dataset.iloc[:, 2].tolist()
  data = [i * 10000 for i in data_list]
  x_pdf, y_pdf = get_pdf(data)
  
  plt.figure()
  plt.plot(x_pdf, y_pdf, label='PDF of values')
  plt.legend()
  plt.xlabel('Value')
  plt.ylabel('Probability')
  output_image = "ex.png"
  plt.savefig(output_image)
  plt.close()
  </code></pre>
  
  <p>However, this code does not work unless each value in the data set is multiplied by <code>10,000</code>. I want to use the values in my data set as it is without multiplying. I would really appreciate some help. Thanks.</p>