~l3on/ubuntu/precise/rkward/rebuild1

« back to all changes in this revision

Viewing changes to rkward/plugins/distributions/plot_poisson_distribution.js

  • Committer: Bazaar Package Importer
  • Author(s): Thomas Friedrichsmeier
  • Date: 2009-10-26 14:30:00 UTC
  • mfrom: (1.1.13 upstream) (6.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20091026143000-wzwt6cryjnwce23k
Tags: 0.5.2-1
* new upstream release
  closes: #551306 (added support for the new dynamic help system)
* Add "DM-Upload-Allowed: yes" in control
* bump standards version to 3.8.3 (no changes needed)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// globals
 
2
var options;
 
3
 
 
4
include ("plot_dist_common.php");
 
5
 
 
6
function getParameters () {
 
7
        options['mean'] = getValue ("mean");
 
8
        getDiscontRangeParameters();
 
9
 
 
10
        if (options['is_density']) {
 
11
                options['fun'] = "dpois";
 
12
        } else {
 
13
                options['fun'] = "ppois";
 
14
        }
 
15
}
 
16
 
 
17
function doHeader () {
 
18
        echo ('rk.header ("Poisson ' + options['label'] + ' function", list ("Lower quantile", "' + options['min'] + '", "Upper quantile", "' + options['max'] + '", "Mean", "' + options['mean'] + '"' + options['log_label'] + options['tail_label'] + ', "Function", "' + options['fun'] + '"));' + "\n");
 
19
}
 
20
 
 
21
function doFunCall () {
 
22
        echo (options['fun'] + '(x, lambda=' + options['mean'] + options['log_option'] + options['tail_option'] + ')');
 
23
}
 
24