Skip to contents

Launches a Shiny app that plots a normal density curve (with adjustable mean and standard deviation) and lets you link an x value, its corresponding z value, and the area under the curve; changing any one of x, z, or area updates the others. Areas can be shown to the left, to the right, in the center, in the tails, or over an interval.

Usage

ShinyNormal()

Details

This function requires the shiny package to be installed. Numeric inputs for x, z, and Area are kept consistent with each other and with the chosen mean and standard deviation; selecting a “Fill Area” option shades the corresponding region under the curve. The x-axis range of the plot can be reset to +/- 4 standard deviations with the “Update x Range” button.

Value

Launches the app in non-blocking mode (via startApp) and returns a ShinyAppHandle immediately, so the R console remains available while the app runs in the background. Use handle$stop() to stop the app.

Author

Greg Snow 538280@gmail.com

See also

Examples

if(interactive()) {
  h <- ShinyNormal()
  # h$stop() # run this when finished with the app
}