index.php
来自「PHP NaiveBayes源代码」· PHP 代码 · 共 109 行
PHP
109 行
<html><head> <title>Implementing Bayesian inference using PHP: Part 1</title></head><body><p><b>Implementing Bayesian inference using PHP: Part 1</b>, <a href='http://www.ibm.com/developerworks/'>IBM developerWorks</a>, March 2004.</p><p>Conditional probability -- the probability of observing one event given that you have observed another event -- is a potentially important factor in designing intelligent Web applications. Paul Meagher introduces Bayesian inference by discussing the basic mathematical concepts involved and demonstrating how to implement the underlying conditional probability calculations using PHP. In this article, the author discusses how Bayesian inference can be used to build an online PHP-based wizard that guides a user through the process making a medical diagnosis. This three-part series features interesting applications designed to help you appreciate the power and potential of Bayesian inference concepts.</p><p><i>Last updated: Feb 27, 2004 - 4:30 PM AST</i></p><hr /><p>Demos:</p><?php $book = "http://www.dartmouth.edu/~chance/teaching_aids/books_articles/probability_book/book.html";?> <ul> <li> <a href='getConditionalProbability.php'>getConditionalProbability.php</a> - frequency-based method for computing conditional probability using smoking and cancer example </li> <li> <a href='test_bayes.php'>test_bayes.php</a> - compare to Grinstead & Snell, <a href='<?php echo $book ?>'>Introduction to Probability</a>, p. 147 </li> <li> <a href='bayes_wizard.php'>bayes_wizard.php</a> - the featured Web application </li> </ul><a name='listing'><p>Source code listing:</p><ul> <li><a href='<?php echo "$PHP_SELF?id=0#source"; ?>'>getConditionalProbability.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=1#source"; ?>'>Bayes</a></li> <li><a href='<?php echo "$PHP_SELF?id=2#source"; ?>'>test_bayes.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=3#source"; ?>'>bayes_wizard.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=4#source"; ?>'>bayes_wizard_step1.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=5#source"; ?>'>bayes_wizard_step2.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=6#source"; ?>'>bayes_wizard_step3.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=7#source"; ?>'>bayes_wizard_step4.php</a></li> <li><a href='<?php echo "$PHP_SELF?id=8#source"; ?>'>bayes_wizard_step5.php</a></li> </ul><a name='source'><?phpif (isset($id)) { ?> <hr /> <br /> <?php switch($id) { case 0: highlight_file("getConditionalProbability.php"); break; case 1: highlight_file("Bayes.php"); break; case 2: highlight_file("test_bayes.php"); break; case 3: highlight_file("bayes_wizard.php"); break; case 4: highlight_file("bayes_wizard_step1.php"); break; case 5: highlight_file("bayes_wizard_step2.php"); break; case 6: highlight_file("bayes_wizard_step3.php"); break; case 7: highlight_file("bayes_wizard_step4.php"); break; case 8: highlight_file("bayes_wizard_step5.php"); break; case 9: highlight_file("index.php"); break; } ?> <br /> <hr /> <br /> <a href='<?php echo "$PHP_SELF?id=$id#listing"; ?>'>Back to source code listing</a> <?php}?> </body></html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?