メイン ie-mean2.html Last modified: Sep 01, 2009
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;CHARSET=EUC-JP">
<link rel="shortcut icon" href="../favicon.ico">
<title>JavaScript</title>
<script src="pxt.js">document.write("pxt.js ファイルが見つかりません??<br>")</script>
<script src="txp.js">document.write("txp.js ファイルが見つかりません??<br>")</script>
<script src="pxg.js">document.write("pxg.js ファイルが見つかりません??<br>")</script>
<script src="gxp.js">document.write("gxp.js ファイルが見つかりません??<br>")</script>
<script src="fixed.js">document.write("fixed.js ファイルが見つかりません??<br>")</script>
<script src="out_pvalue.js">document.write("out_pvalue.js ファイルが見つかりません??<br>")</script>
<script language="JavaScript">
<!--
function calc(form)
{
var n, mean, variance, conf, se, t
if (isNaN(n = parseInt(form.n.value)) || n <= 1 || isNaN(mean = parseFloat(form.mean.value)) || isNaN(variance = parseFloat(form.variance.value)) || variance <= 0 || isNaN(conf = parseFloat(form.conf.value)) || conf <= 0 || conf >= 1) return
se = Math.sqrt(variance/n)
t = pxt(1-conf, n-1)
form.upper.value = fixed(mean+t*se, 5)
form.lower.value = fixed(mean-t*se, 5)
}
function calc2(form)
{
var n, mean, variance, conf, se, g
if (isNaN(n = parseInt(form.n.value)) || n <= 1 || isNaN(mean = parseFloat(form.mean.value)) || isNaN(variance = parseFloat(form.variance.value)) || variance <= 0 || isNaN(conf = parseFloat(form.conf.value)) || conf <= 0 || conf >= 1) return
se = Math.sqrt(variance/n)
g = pxg((1-conf)/2)
form.upper.value = fixed(mean+g*se, 5)
form.lower.value = fixed(mean-g*se, 5)
}
function calc3(form)
{
var n, mean, variance, mu, t, df
if (isNaN(n = parseInt(form.n.value)) || n <= 1 || isNaN(mean = parseFloat(form.mean.value)) || isNaN(variance = parseFloat(form.variance.value)) || variance <= 0 || isNaN(mu = parseFloat(form.mu.value))) return
t = Math.abs(mean-mu)/Math.sqrt(variance/n)
df = n-1
form.t.value = fixed(t, 5)
form.df.value = df
form.p.value = out_pvalue(txp(t, df))
}
function calc4(form)
{
var n, mean, variance, sigma2, mu, z
if (isNaN(n = parseInt(form.n.value)) || n <= 1 || isNaN(mean = parseFloat(form.mean.value)) || isNaN(variance = parseFloat(form.variance.value)) || variance <= 0 || isNaN(mu = parseFloat(form.mu.value)) || isNaN(sigma2 = parseFloat(form.variance.value)) || sigma2 <= 0) return
z = Math.abs(mean-mu)/Math.sqrt(sigma2/n)
form.z.value = fixed(z, 5)
form.p.value = out_pvalue(gxp(z)*2)
}
//-->
</script>
</head>
<body bgcolor="#ffffff">
<font size="+2"><b>母平均の検定・推定</b></font> <a href="src/ie-mean2.html"><img src="png/src.png" width=35 height=11 alt="src" align=top></a> Last modified: Jun 01, 2006<hr noshade><p>
<font color="#ff0000" size="+2">以下のプログラムのサポートは終了しました。自己責任でお使い下さい。</font>
<script language="JavaScript">
<!--
//-->JavaScript がサポートされていないブラウザですか?
</script>
<hr noshade>
<font size="+2">母平均の検定</font> <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Average/Mean1.html">手法の解説</a>
<table border=1>
<tr>
<td nowrap align=right valign=top bgcolor="#ccccee">
<table border=0>
<caption><font color="#aa5555"><b>母分散が未知の場合</b></font></caption>
<tr>
<td nowrap align=right>
<form name="mean3">
標本サイズ <input name="n" value=31 size=10><br>
標本平均 <input name="mean" value=157.8 size=10><br>
標本不偏分散 <input name="variance" value=24.6 size=10><br>
母平均 <input name="mu" value=156.2 size=10><br>
<input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.mean.value=this.form.variance.value=this.form.mu.value=this.form.t.value=this.form.df.value=this.form.p.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="calc3(this.form)"><br>
t 値 <input name="t" value="" size=10><br>
自由度 <input name="df" value="" size=10><br>
P 値 <input name="p" value="" size=10><br>
</form>
</td>
</tr>
</table>
</td>
<td nowrap align=right valign=top bgcolor="#eecccc">
<table border=0>
<caption><font color="#5555aa"><b>母分散が既知の場合</b></font></caption>
<tr>
<td nowrap align=right>
<form name="mean4">
標本サイズ <input name="n" value=31 size=10><br>
標本平均 <input name="mean" value=157.8 size=10><br>
母分散 <input name="variance" value=25.5 size=10><br>
母平均 <input name="mu" value=156.2 size=10><br>
<input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.mean.value=this.form.variance.value=this.form.mu.value=this.form.z.value=this.form.p.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="calc4(this.form)"><br>
Z 値 <input name="z" value="" size=10><br>
P 値 <input name="p" value="" size=10><br>
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
<p>
<font size="+2">母平均の推定</font> <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Average/Mean2.html">手法の解説</a>
<table border=1>
<tr>
<td nowrap align=right valign=top bgcolor="#ccccee">
<table border=0>
<caption><font color="#aa5555"><b>母分散が未知の場合</b></font></caption>
<tr>
<td nowrap align=right>
<form name="mean1">
標本サイズ <input name="n" value=31 size=10><br>
標本平均 <input name="mean" value=157.8 size=10><br>
標本不偏分散 <input name="variance" value=24.6 size=10><br>
信頼率 <input name="conf" value=0.95 size=10><br>
<input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.mean.value=this.form.variance.value=this.form.conf.value=this.form.upper.value=this.form.lower.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="calc(this.form)"><br>
上側信頼限界 <input name="upper" value="" size=10><br>
下側信頼限界 <input name="lower" value="" size=10><br>
</form>
</td>
</tr>
</table>
</td>
<td nowrap align=right valign=top bgcolor="#eecccc">
<table border=0>
<caption><font color="#5555aa"><b>母分散が既知の場合</b></font></caption>
<tr>
<td nowrap align=right>
<form name="mean2">
標本サイズ <input name="n" value=31 size=10><br>
標本平均 <input name="mean" value=157.8 size=10><br>
母分散 <input name="variance" value=25.5 size=10><br>
信頼率 <input name="conf" value=0.95 size=10><br>
<input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.mean.value=this.form.variance.value=this.form.conf.value=this.form.upper.value=this.form.lower.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="calc2(this.form)"><br>
上側信頼限界 <input name="upper" value="" size=10><br>
下側信頼限界 <input name="lower" value="" size=10><br>
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
<p><hr noshade>
<img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="javascript:history.go(-1)">直前のページへ戻る</A> <img src="../gra/button3.png" width=9 height=9 alt="・"> <a href="../mail.html">E-mail to Shigenobu AOKI</a>
<p><center><IMG SRC="../gra/ume5.png" width=121 height=37 ALT="Made with Macintosh"></center>
</body>
</html>
サブ gxp.js Last modified: Mar 25, 2004
サブ txp.js Last modified: Mar 25, 2004
サブ pxg.js Last modified: Mar 25, 2004
サブ fixed.js Last modified: Mar 25, 2004
サブ out_pvalue.js Last modified: Mar 25, 2004
直前のページへ戻る E-mail to Shigenobu AOKI