Subscribe Bookmark RSS Feed

Problems with JSL

crossbill

Community Member

Joined:

Feb 4, 2014

I'm currently trying to play around with the normal probability density function script provided in the Scripting Index of JMP 11.  I was told that you can simply change the values in the examples provided.  I tried this and the graph that is produced using the script provided (see below) is completely blank.  I tried to use this same script in the script window and had the same problem.  The graph is produced just fine when the defaults in the example are kept.  Does anyone have suggestions on what I might be doing wrong?  I've tried to do obvious things like manipulate the scales but nothing is working.

Here is the example given:

Names Default To Here( 1 );

New Window( "Example: Normal Density",

    y = Graph Box(

        Y Scale( 0, 0.45 ),

        X Scale( -4, 4 ),

        XName( "q" ),

        Pen Color( "red" );

        Y Function( Normal Density( q ), q );

    )

);

My manipulated script:

Names Default To Here( 1 );

New Window( "Example: Normal Density",

    y = Graph Box(

        Y Scale( 0, 0.45 ),

        X Scale( -4, 4 ),

        XName( "q" ),

        Pen Color( "red" );

        Y Function( Normal Density( q, 7.4713E-12, 1.103737367));)

   

);

1 REPLY
pmroz

Super User

Joined:

Jun 23, 2011

If you check your log window you'll see the error message:

not enough arguments in access or evaluation of 'Y Function' , Y Function( Normal Density( q, 0.0000000000074713, 1.103737367 ) )

You forgot the 2nd q argument:

Y Function( Normal Density( q, 7.4713E-12, 1.103737367 ), q );