binomialrvls
Class normDist
- public class normDist
- extends java.awt.Canvas
normDist
public normDist()
- class constructor, create basic normal distribution contour
setMean
public void setMean(double mean)
- set the mean (default = 0)
setSd
public void setSd(double sd)
- sd default = 1
setShade
public void setShade(boolean shade)
- Whether to shade in the specified area
setShadeBetween
public void setShadeBetween(boolean _between)
- if shadeBetween is true, shade between lowCutoff and upCutoff otherwise shade the tails
setYaxis
public void setYaxis(boolean yaxis)
- set up to draw Y axis
setTitle
public void setTitle(String title)
- set up the title for this normal distribution
setUpLimit
public void setUpLimit(double upLimit)
- upperlimit on x axis, but not the upCutoff
setLowLimit
public void setLowLimit(double lowLimit)
- set the lower limit on x axis
setUpCutoff
public void setUpCutoff(double upCutoff)
- set the cut off points on x axis
setFillColor
public void setFillColor(Color fillColor)
- set the color filling color for shaded area
setLimits
public void setLimits(double lowLimit,
double upLimit,
int numTicks)
- lowLimit: lower x axis limit upLimit: upper x axis limit mumTicks: number of ticks on x axis
setShadedArea
public void setShadedArea(double lowCutoff,
double upCutoff)
- shades the specified area
setAutoRepaint
public void setAutoRepaint(boolean autoRepaint)
- if autorepaint is true then changing a parameter will cause a repaint.
initialize
public void initialize(int _numTicks,
double _LL,
double _UL,
double _mean,
double _sd,
double _LC,
double _UC,
boolean _between,
String _title,
Color _fillColor)
- set up all initialization parameters
paint
public void paint(Graphics g)
- paint X axis and Y axis(if set up), and then call drawDist(g) to draw normal distribution figure
getDensity
public double getDensity(double x)
- get density for p(X<=x) for normal distribution