R Scripts to conduct statistical anaylsis with example datasets.
Statistical Analysis Includes
- Confidence Interval Calculation
- Hypothesis Testing
- Linear Modelling
- Robust Linear Modelling
- Sample Size Calculation
-
Confidence Interval Calculation
- Confidence Interval from Bootstrapped Data
- Confidence Interval from Population mean (assuming normally distributed data)
- Confidence Interval Calculations
- Tolerance Interval
- Population Proportion Confidence Interval
- Population Variance Confidence INterval
- Median Confidence Interval
- Variance and Correlatino Testing
- Wilcox Test paired
-
Hypothesis Testing
- Hypothesis Testing of Mean ( Small Sample N < 40), Test statistic - T distribution (if small sample)
- Hypothesis Testing Variance ( Small Sample N < 40), Test statistic - Chi distribution (if small sample)
- Hypothesis Testing Independence of two groups, Test statistic - Chi distribution
- Hypothesis Testing for Comparing two Variances, Use F statisitc = s1^2/s2^2
- Hypothesis of Delta between Two Data Sets, Test statistic - T distribution (if small sample)
- Hypothesis Testing of two Proportions, Use Z statistics proportion of children in either groups is statisiically different
- Hypothesis Test of Median, Test statistics is the observed number of plus differences r+ = (n/2)
- Non Parametric Median Hypothesis (Wicox Rank Sum, Wilcox Sign Rank, Sign Test)
-
Linear Modelling
- BIC
- AIC
- Error/Residual Diagnostics
- Model Diagnostics plot the histogram of the residuals and add the pdf. This is to see how good the residuals fit a normal distribution. You can do a KS test on this, or a qqplot..)
- Skill Evaluation
- Gamma Function Fitting
- Log Normal Fit
-
Robust Linear Modelling
- Perason Correlation Calculation
- Kedall's Tau Correlation Caluclation
- Spearman's Rank Correlation Calculation
- Kendall Thiel Slope Estimate
-
Sample Size Calculation
- Simple sample size calculation based on desired alpha
Scripts created using RStudio V.99.491
MIT License
Copyright (c) 2016 Justin Chin
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Sample datasets used in the scripts are from CU Boulder Professor Balaji's PROBABILITY & STATISTICAL METHODS FOR NATURAL AND ENGINEERED SYSTEMS course website http://ceae.colorado.edu/~balajir/CVEN5454/