Descriptive Statistics

Random Variable: A function that maps each outcome in a sample space to a real number

  • Discrete Random Variable: Countable values with gaps between them; often integer counts

  • Continuous Random Variable: Uncountable continuum of values over an interval

Measures of Central Tendency

  • Mean

    • Arithmetic center of gravity

  • Median

    • Middle value after sorting

    • 50th percentile

    • Percentile: Cutoff in the data in which you find a given percentage below the value

  • Mode

    • Most frequent value/highest frequency bin

    • Only measure for nominal data

Right-skewed: Mode < Median < Mean

Left-skewed: Mean < Median < Mode

Symmetric: Mode = Median = Mean (roughly)

Measures of Spread

  • Variance (s2)(s²)

    • Average squared deviation from the mean

    • s2=Σ(xi−x‾)2n−1s^2=\frac{\Sigma\left(x_{i}-\overline{x}\right)^2}{n-1}

    • n−1n-1 comes from a correction for the downward bias of using a sample mean rather than the true population mean

  • Standard Deviation (s)(s)

    • Square root of variance

    • Used to return to original units

    • s=s2s=\sqrt{s^2}

  • Interquartile Range (IQR)

    • Q3 - Q1

    • Range of the middle 50% of values

Visualizing Distribution

Histogram

  • Bar plot used effectively in conjunction with samples from a continuous random variable

  • Bins hold all values between a start and end value. Bins should be equal width to each other

  • Can show a bimodal distribution

    • Two distinct peaks often indicate that data is a mixture of two underlying populations

    • Mean often falls in the valley and therefore describes neither population well

    Skewness: Direction of tails

    Kurtosis: Weight of curve

    Concentration: within k standard deviations of the mean, we have at least 1−1k2%1-\frac{1}{k^2}\%

Data collected from a feature is a vector of information
cos⁡θ=(zx→⋅zy→)∥zx→∥⋅∥zy→∥\cos\theta=\frac{\left(\overrightarrow{z_{x}}\cdot\overrightarrow{z_{y}}\right)}{\left\Vert\overrightarrow{z_{x}}\right\Vert\cdot\left\Vert\overrightarrow{z_{y}}\right\Vert}

Residuals: Difference between observed and predicted