メイン tests2.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="gxp.js">document.write("gxp.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="fixed.js">document.write("fixed.js ファイルが見つかりません??<br>")</script>
<script src="out_pvalue.js">document.write("out_pvalue.js ファイルが見つかりません??<br>")</script>

<script language="JavaScript">
<!--

function fis(r)
{
  return 0.5*Math.log((1+r)/(1-r))
}

function rev(z)
{
  return (Math.exp(2*z)-1)/(Math.exp(2*z)+1)
}

function f_soukan1(form)
{
  form.stat.value = form.t.value = form.nam.value = form.df.value = form.p.value = ""
  var n, r, t, df, r0, z
  if (isNaN(n = parseInt(form.n.value)) || n <= 2 || isNaN(r = parseFloat(form.r.value)) || r <= -1 || r >= 1 || isNaN(r0 = parseFloat(form.r0.value)) || r0 <= -1 || r0 >= 1) return
  if (r0 == 0) {
    df = n-2
    t = Math.abs(r)*Math.sqrt(df)/Math.sqrt(1-r*r)
    form.stat.value = "t0"
    form.t.value = fixed(t, 5)
    form.nam.value = "自由度"
    form.df.value = df
    form.p.value = out_pvalue(txp(t, df))
  }
  else {
    if (n <= 3) return
    z = Math.abs(fis(r)-fis(r0))*Math.sqrt(n-3)
    form.stat.value = "z0"
    form.t.value = fixed(z, 5)
    form.nam.value = ""
    form.p.value = out_pvalue(gxp(z)*2)
  }
}

function f_soukan3(form)
{
  form.z.value = form.p.value = ""
  var n, r, z
  if (isNaN(n = parseInt(form.n.value)) || n <= 2 || isNaN(r = parseFloat(form.r.value)) || r <= -1 || r >= 1) return
  z = Math.abs(r)/Math.sqrt((4*n+10)/(9*n*(n-1)))
  form.z.value = fixed(z, 5)
  form.p.value = out_pvalue(gxp(z)*2)
}

function f_soukan2(form)
{
  form.lcl.value = form.ucl.value = ""
  var n, r, conf
  if (isNaN(n = parseInt(form.n.value)) || n <= 3 || isNaN(r = parseFloat(form.r.value)) || r <= -1 || r >= 1 || isNaN(conf = parseFloat(form.conf.value)) || conf <= 0 || conf >= 1) return
  form.ucl.value = fixed(rev(fis(r)+pxg((1-conf)/2)/Math.sqrt(n-3)), 5)
  form.lcl.value = fixed(rev(fis(r)-pxg((1-conf)/2)/Math.sqrt(n-3)), 5)
}
//-->
</script>
</head>

<body bgcolor="#ffffff">
<font size="+2"><b>相関係数の検定・推定</b></font> <a  href="src/tests2.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>
<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="soukan1">
      標本サイズ <input name="n" value=24 size=10><br>
      標本相関係数 <input name="r" value=0.476 size=10><br>
      母相関係数 <input name="r0" value=0 size=10><br>
      <input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.r.value=this.form.r0.value=this.form.stat.value=this.form.nam.value=this.form.t.value=this.form.df.value=this.form.p.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="f_soukan1(this.form)"><br>
      <input name="stat" value="t0" size=2> <input name="t" value="" size=10><br>
      <input name="nam" value="自由度" size=6> <input name="df" value="" size=10><br>
      P 値 <input name="p" value="" size=10><br>
      </form>
      <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Corr/corr.html">手法の解説(1)</a><br>
      <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Corr/corr2.html">手法の解説(2)</a><br>
    </td>
    </tr>
    </table>
  </td>

  <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="soukan2">
      標本サイズ <input name="n" value=24 size=10><br>
      標本相関係数 <input name="r" value=0.476 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.r.value=this.form.conf.value=this.form.lcl.value=this.form.ucl.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="f_soukan2(this.form)"><br>
      下側信頼限界 <input name="lcl" value="" size=10><br>
      上側信頼限界 <input name="ucl" value="" size=10><br>
      </form>
      <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Corr/corr3.html">手法の解説</a><br>
    </td>
    </tr>
    </table>
  </td>

  <td nowrap align=right valign=top bgcolor="#ccccee">
    <table border=0>
    <caption><font color="#aa5555"><b>母相関係数の検定<br>ケンドールの順位相関係数</b></font></caption>
    <tr>
    <td nowrap align=right>
      <form name="soukan3">
      標本サイズ <input name="n" value=24 size=10><br>
         標本相関係数 <input name="r" value=0.493 size=10><br>
      <input type="button" name="clear" value="初期化" onClick="this.form.n.value=this.form.r.value=this.form.z.value=this.form.p.value=''"> <input type="button" name="calcurate" value="計算開始" onClick="f_soukan3(this.form)"><br>
      z<sub>0</sub> <input name="z" value="" size=10><br>
      P 値 <input name="p" value="" size=10><br>
      </form>
      <img src="../gra/button3.png" width=9 height=9 alt="・"> <A HREF="../lecture/Corr/kendall-corr.html">手法の解説</a><br>
    </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

Made with Macintosh