Learn R Programming

⚠️There's a newer version (2.13) of this package.Take me there.

TeachingDemos (version 2.1)

Demonstrations for teaching and learning

Description

This package is a set of demonstration functions that can be used in a classroom to demonstrate statistical concepts, or on your own to better understand the concepts or the programming.

Copy Link

Version

Install

install.packages('TeachingDemos')

Monthly Downloads

4,078

Version

2.1

License

Artistic-2.0

Maintainer

Greg Snow

Last Published

February 17th, 2024

Functions in TeachingDemos (2.1)

bct

Box-Cox Transforms
loess.demo

Demonstrate the internals of loess curve fits
faces2

Chernoff Faces
rotate.cloud

Interactively rotate 3D plots
subplot

Embed a new plot within an existing plot
roc.demo

Demonstrate ROC curves by interactively building one
dots

Create a quick dotchart (histogram)
txtStart

Save a transcript of commands and/or output to a text file.
plot2script

Create a script from the current plot
TkSpline

Plot a set of data in a Tk window and interactively move a line to see predicted y-values from a spline fit corresponding to selected x-values.
col2grey

Convert colors to grey/grayscale
faces

Chernoff Faces
gp.open

Alpha version functions to send plotting commands to GnuPlot
z.test

Z test for known population standard deviation
chisq.detail

Print details of a chi-squared test
tree.demo

Interactively demonstrate regression trees
digits

Return the digits that make up an integer
slider

slider / button control widgets
ci.examp

Plot examples of Confidence Intervals
dice

Simulate rolling dice
SensSpec.demo

Demonstrate Sensitivity, Specificity, PPV, and NPV
coin.faces

Designs for coin faces for use with plot.rgl.coin
dynIdentify

Interacively place labels for points in a plot
ms.polygram

Symbol functions/data to be passed as symb argument to my.symbols
%<%

Less than or Less than and equal operators that can be chained together.
limits.g

Functions to plot Shewhart g chart
put.points.demo

Demonstrate Correlation and Regression by placing and moving data points
sliderv

Create a Tk slider window
run.cor.examp

Interactively demonstrate correlations
tkprogress

Create a progress bar and function to control it.
rgl.coin

Animated die roll or coin flip
my.symbols

Draw Symbols (User Defined) on a Plot
power.examp

Graphically illustrate the concept of power.
tkexamp

Create Tk dialog boxes with controls to show examples of changing parameters on a graph.
clipplot

Clip plotting to a rectangular region
squishplot

Squish the plotting area to a specified aspect ratio
vis.boxcox

Interactively visualize Box-Cox transformations
HWidentify

Show label for point being Hovered over.
plot.rgl.coin

Animated die roll or coin flip
TkBuildDist

Interactively create a probability distribution.
TeachingDemos-package

Various functions for demonstration and learning.
zoomplot

Zoom or unzoom an existing plot in the plot window
cnvrt.coords

Convert between the 5 different coordinate sytems on a graphical device
vis.test

Do a Visual test of a null hypothesis by choosing the graph that does not belong.
run.hist.demo

Create a histogram and interactively change the number of bars.
identify.Map

Identify polygons within a plotted map from the maptools packages.
char2seed

Convert a character string into a random seed
hpd

Compute Highest Posterior Density Intervals
mle.demo

Demonstrate the basic concept of Maximum Likelihood Estimation
steps

Steps data
TkApprox

Plot a set of data in a Tk window and interactively move lines to see predicted y-values corresponding to selected x-values.
Pvalue.norm.sim

Simulate P-values
towork

Sample data downloaded and converted from a GPS unit
rgl.Map

Plot a map in an rgl window
TkPredict

Plot predicted values from a model against one of the predictors for a given value of the othe predictors
TkListView

Interactivly view structures of list and list like objects.
triplot

Create or add to a Trilinear Plot
fagan.plot

Create a Fagan plot to demonstrate Bayes Theorem and screening tests
clt.examp

Plot Examples of the Central Limit Theorem
lattice.demo

Interactively explore the conditioned panels in lattice plots.
ldsgrowth

Growth of The Church of Jesus Christ of Latter-day Saints.
strip.shingle

strip function for trellis plots
cor.rect.plot

Plot a visualization of the correlation using colored rectangles
vis.binom

Plot various distributions then interactivly adjust the parameters.
tkBrush

Change the Color and Styles of points interactively
state.vbm

Map object for the US State Visibility Based Map
shadowtext

Add text to a plot with a contrasting background.
outliers

Outliers data
petals

Play the Petals Around the Rose game
stork

Neyman's Stork data
cal

Plot a month or year calendar
spread.labs

Spread out close points for labeling in plots
evap

Data on soil evaporation.
updateusr

Updates the 'usr' coordinates in the current plot.
simfun

Create a function to simulate data
SnowsCorrectlySizedButOtherwiseUselessTestOfAnything

Snow's Correctly Sized But Otherwise Useless Test of Anything
recenter.Map

Recenter a Map object from the maptools package.
project.Map

Apply projections to Map objects (from maptools package)
panel.my.symbols

Draw Symbols (User Defined) on a Lattice Plot
pairs2

Create part of a scatterplot matrix
USCrimes

US Crime Statistics
sigma.test

One sample Chi-square test for a population variance
SnowsPenultimateNormalityTest

Test the uninteresting question of whether the data represents an exact normal distribution.