VISUALIZATION OF DENSITY FUNCTIONS WITH GEOGEBRA Csilla Csendes University of Miskolc, Hungary Department of Applied Mathematics ICAM 2010
Probability density functions A random variable X has density f, where f is a non-negative Lebesgue-integrable function, if: P[a X b] = b a f (x) dx. Hence, if F is the cumulative distribution function of X, then: F(x) = x f (u) du Intuitively, one can think of f (x)dx as being the probability of X falling within the infinitesimal interval [x, x + dx].
Stable distributions Stable distributions Definition (broad sense) Let X, X 1, X 2,... be iid. random variables. The distribution of X is stable if it is not concentrated at one point and if for each n there exist constants a n > 0 and b n such that X 1 + X 2 +... + X n a n b n has the same distribution as X.
Stable distributions Properties infinite variance non-known density and distribution function describe with characteristic function applications: finance, signal processing, etc. class of possible limit distributions as a solution to the domain of attraction problem
Stable distributions Parameters Characterization characteristic exponent or index of stability α (0, 2] skewness β [ 1, 1] scale γ 0 location δ R Characteristic function φ(u α, β, γ, δ) = E exp(iuz ) = exp( γ α [ u α + iβη(u, α)] + iuδ), η(u, α) = { (signu)tan(πα/2) u α, if α 1, (2/π)u ln u, if α = 1.
Stable distributions Density functions α = 1 - Cauchy distribution α = 2 - Normal distribution
Other Continuous Distributions Exponential distribution The exponential distribution occurs naturally when describing the lengths of the inter-arrival times in a homogeneous Poisson process. parameter λ > 0 (rate parameter) An exponential random sample can be generated as ln(1 U) where U is uniformly distributed. Probability density function: { λe λx if x 0, f (x) = 0, otherwise
Other Continuous Distributions Gamma distribution The pdf. of the gamma distribution can be expressed in terms of the gamma function parameterized in terms of a shape parameter k and scale parameter θ. Both k and θ will be positive values. sum of k independent exponentially distributed random variables, each of which has a mean of θ frequently a probability model for waiting times; for instance, in life testing, the waiting time until death Probability density function k 1 e x/θ f (x; θ, k) = x θ k Γ(k) x 0, k, θ > 0
Other Continuous Distributions Chi-square distribution If X 1,..., X k are independent, standard normal random variables, then the sum of their squares Q = k i=1 X 2 i is distributed according to the chi-square distribution with k degrees of freedom. Probability density function f (x; k) = 1 2 k/2 Γ(k/2) x k/2 1 e x/2
Statistical tools Basics Mean[list of numbers L] Mode[list of numbers L] Median[list of numbers L] Variance[list of numbers L] CorrelationCoefficient[List of x-coordinates, List of y-coordinates]
Statistical tools BoxPlot BoxPlot[yOffset, yscale, List of Raw Data]: Creates a box plot using the given raw data and whose vertical position in the coordinate system is controlled by variable yoffset and whose height is influenced by factor yscale. BoxPlot[yOffset, yscale, Start Value a, Q1, Median, Q3, End Value b]: Creates a box plot for the given statistical data in interval [a, b].
Statistical graphics Histograms A histogram is a graphical display of tabular frequencies, shown as adjacent rectangles. A histogram may also be based on relative frequencies. It then shows the proportion of cases that fall into each of several categories, with the total area equaling 1. Histograms are used to plot density of data, and often for density estimation: estimating the probability density function of the underlying variable. The total area of a histogram used for probability density is always normalized to 1.
GeoGebra functions - Syntax Histogram Histogram[List of Class Boundaries, List of Heights]: Creates a histogram with bars of the given heights. The class boundaries determine the width and position of each bar of the histogram. Histogram[List of Class Boundaries, List of Raw Data]: Creates a histogram using the raw data. The class boundaries determine the width and position of each bar of the histogram and are used to determine how many data elements lie in each class.
GeoGebra functions - Syntax BarChart BarChart[Start Value, End Value, List of Heights]: Creates a bar chart over the given interval where the number of bars is determined by the length of the list whose elements are the heights of the bars. BarChart[Start Value a, End Value b, Expression, Variable k, From Number c, To Number d]: Creates a bar chart over the given interval [a, b], that calculates the bars heights using the expression whose variable k runs from number c to number d. BarChart[Start Value a, End Value b, Expression, Variable k, From Number c, To Number d, Step Width s]: Creates a bar chart over the given interval [a, b], that calculates the bars heights using the expression whose variable k runs from number c to number d using step width s. BarChart[List of Raw Data, Width of Bars]: Creates a bar chart using the given raw data whose bars have the given width.
Histograms Normal distribution
Histograms Levy distribution
Histograms Cauchy distribution
Curve fitting commands in GeoGebra Commands FitExp[List of Points] - Calculates the exponential regression curve. FitLog[List of Points] - Calculates the logarithmic regression curve (i.e. the regression curve of the form y=a+bln(x)). FitPoly[list of points P, number N] - Calculates the regression polynomial of degree N. FitPow[list of points P] - Calculates the regression curve in the form y = ax b.
Curve fitting commands in GeoGebra Normal distribution, polynomials of 8 and 9 degrees
Curve fitting commands in GeoGebra Normal distribution, polynomials of 10 and 12 degrees
Curve fitting commands in GeoGebra Cauchy distribution, polynomials of 8 and 9 degrees
Curve fitting commands in GeoGebra Cauchy distribution, polynomials of 12 and 13 degrees
Curve fitting commands in GeoGebra Exponential distribution, exponential curve f (x) = 0.29e 1.06x
Curve fitting commands in GeoGebra THANKS FOR YOUR ATTENTION!