File:Nc student t pdf.svg
From Wikimedia Commons, the free media repository
Jump to navigation
Jump to search
Size of this PNG preview of this SVG file: 360 × 288 pixels. Other resolutions: 300 × 240 pixels | 600 × 480 pixels | 960 × 768 pixels | 1,280 × 1,024 pixels | 2,560 × 2,048 pixels.
Original file (SVG file, nominally 360 × 288 pixels, file size: 41 KB)
File information
Structured data
Captions
Summary
[edit]DescriptionNc student t pdf.svg |
English: Graphs of the probability density functions for several members of the noncentral Student-t family. |
Date | |
Source | Own work |
Author | Skbkekas |
SVG development InfoField | This plot was created with Matplotlib. |
Source code InfoField | Python codeimport numpy as np
import matplotlib.pyplot as plt
import scipy.special as sp
col = ['orange', 'purple', 'deepskyblue', 'mediumseagreen']
X = np.arange(-5, 10, 0.01)
##
## PDF
##
plt.clf()
plt.figure(figsize=(4,3.2))
plt.axes([0.17,0.13,0.79,0.8])
plt.hold(True)
Q = []
for k,(mu,df) in enumerate([(0.,1.),(0.,4.),(2.,1.),(2.,4.)]):
Y = df/2*np.log(df) + sp.gammaln(df+1) - df*np.log(2) - mu**2/2
Y -= (df/2)*np.log(df+X**2)
Y -= sp.gammaln(df/2)
A = sp.hyp1f1(df/2+1, 1.5, mu**2*X**2/(2*(df+X**2)))
B = sp.hyp1f1((df+1)/2, 0.5, mu**2*X**2/(2*(df+X**2)))
C = np.sqrt(2)*mu*X*A
C /= df+X**2
C /= np.exp(sp.gammaln((df+1)/2))
D = B/np.sqrt(df+X**2)
D /= np.exp(sp.gammaln(df/2+1))
Y += np.log(C+D)
a = plt.plot(X, np.exp(Y), '-', color=col[k], lw=2)
Q.append(a)
plt.xlabel("x")
plt.ylabel("P(x)")
bx = plt.legend(Q, (r"$\mu=0,\,\nu=1$", r"$\mu=0,\,\nu=4$",\
r"$\mu=2,\,\nu=1$", r"$\mu=2,\,\nu=4$"),\
numpoints=1, handlelen=0.05, handletextpad=0.4,\
loc="upper right")
bx.draw_frame(False)
plt.xlim(-5,10)
plt.savefig("nc_student_t_pdf.pdf")
plt.savefig("nc_student_t_pdf.svg")
|
Licensing
[edit]I, the copyright holder of this work, hereby publish it under the following license:
This file is licensed under the Creative Commons Attribution 3.0 Unported license.
- You are free:
- to share – to copy, distribute and transmit the work
- to remix – to adapt the work
- Under the following conditions:
- attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 04:07, 15 March 2010 | 360 × 288 (41 KB) | Skbkekas (talk | contribs) | {{Information |Description={{en|1=Graphs of the probability density functions for several members of the noncentral Student-t family.}} |Source={{own}} |Author=Skbkekas |Date=2010-03-15 |Permission= |other_versions= }} [[Category:Statis |
You cannot overwrite this file.
File usage on Commons
There are no pages that use this file.
File usage on other wikis
The following other wikis use this file:
- Usage on ca.wikipedia.org
- Usage on en.wikipedia.org
- Usage on es.wikipedia.org
- Usage on fa.wikipedia.org
- Usage on ja.wikipedia.org