LearningStats-package: Elemental Descriptive and Inferential Statistics...

Description Details

Description

This package provides tools to teach students elemental Statistics. The main topics covered are Descriptive Statistics, Probability models (discrete and continuous variables) and Statistical Inference (confidence intervals and hypothesis tests).

Details

Main sections of LearningStats-package are:

A.- Data
B.- Descriptive Statistics
C.- Probability models
D.- Statistical Inference
E.- Regression

A.- Data

This section includes a function to read different file extensions and a dataset on health-related behaviours with 18 variables. The main advantage of this tool is that with just one single function most of the common file extensions can be imported into R.

read.data Data Input
sicri2018 SICRI: information system on risk-taking behaviour

B.- Descriptive Statistics

The functions included in this section perform Descriptive Statistics by quantitatively describing or summarizing different characteristics from a sample. Graphical tools are also available.

freq.pol Plot a Cumulative Frequency Polygon
freq.table Frequency Table
Histogram Plot a Histogram

C.- Probability models

In this section probability models for discrete and continuous variables are provided.

C.1-Discrete variables:

The user is allowed to display, with several options, the probability mass and/or distribution function for the following discrete distributions: Binomial, Discrete Uniform, Hypergeometric, Negative Binomial and Poisson.

plotBinom Probability Mass and/or Distribution Function Representations associated with a
Binomial Distribution
plotDUnif Probability Mass and/or Distribution Function Representations associated with a
Discrete Uniform Distribution
plotHyper Probability Mass and/or Distribution Function Representations associated with a
Hypergeometric Distribution
plotNegBinom Probability Mass and/or Distribution Function Representations associated with a
Negative Binomial Distribution
plotPois Probability Mass and/or Distribution Function Representations associated with a
Poisson Distribution

C.2-Continuous variables:

The user is allowed to display, with several options, the density, distribution and/or quantile functions for the following continuous distributions: Beta, Chi-squared, Exponential, F-Snedecor, Gamma, Normal, T-Student and Uniform.

plotBeta Density Function, Distribution Function and/or
Quantile Function Representations associated with a Beta Distribution
plotChi Density Function, Distribution Function and/or
Quantile Function Representations associated with a Chi-squared Distribution
plotExp Density Function, Distribution Function and/or
Quantile Function Representations associated with a Exponential Distribution
plotFS Density Function, Distribution Function and/or
Quantile Function Representations associated with a F-Snedecor Distribution
plotGamma Density Function, Distribution Function and/or
Quantile Function Representations associated with a Gamma Distribution
plotNorm Density Function, Distribution Function and/or
Quantile Function Representations associated with a Normal Distribution
plotTS Density Function, Distribution Function and/or
Quantile Function Representations associated with a T-Student Distribution
plotUnif Density Function, Distribution Function and/or
Quantile Function Representations associated with a Uniform Distribution

C.3-Illustrations:

Also in this section three common approximations between different distributions are illustrated. The approximations considered are: the Normal approximation to Binomial, the Normal approximation to Poisson and the Poisson approximation to Binomial.

AproxBinomNorm Illustration of the Normal Approximation to Binomial
AproxPoisNorm Illustration of the Normal Approximation to Poisson
AproxBinomPois Illustration of the Poisson Approximation to Binomial

D.- Statistical Inference

This section includes functions to perform Statistical Inference (confidence intervals and hypothesis testing) with one or two populations and also for categorical data.

D.1-Confidence intervals:

The functions included here provide pointwise and confidence interval estimation for different population parameters. One or two populations are supported.

One population:

Mean.CI Confidence Interval for the Mean of a Normal Population
proportion.CI Large Sample Confidence Interval for a Population Proportion
variance.CI Confidence Interval for the Variance and the Standard
Deviation of a Normal Population

Two populations:

diffmean.CI Confidence Interval for the Difference
between the Means of Two Normal Populations
diffproportion.CI Large Sample Confidence Interval for the
Difference between Two Population Proportions
diffvariance.CI Confidence Interval for the Ratio between the
Variances of Two Normal Populations

D.2-Hypothesis tests:

This sections allows to compute hypothesis tests for different population parameters (mean, variance and proportion) in one or two populations. The scenarios covered here are those mentioned in the Confidence Interval section as well as a Chi-squared independence test.

One population:

Mean.test One Sample Mean Test of a Normal Population
proportion.test Large Sample Test for a Population Proportion
variance.test One Sample Variance Test of a Normal Population

Two populations:

diffmean.test Two Sample Mean Test of Normal Populations
diffproportion.test Two Sample Proportion Test
diffvariance.test Two Sample Variance Test of Normal Populations

Categorical data:

indepchisq.test Chi-squared Independence Test for Categorical Data

E.- Regression

This section includes a function to describe the relationship between two continuous variables through a simple linear regression model, providing the R-squared coefficient.

plotReg Representation of a Linear Regression Model

LearningStats documentation built on April 21, 2021, 9:06 a.m.