MinPValue = Min( arrPValues<<Get Values ) ītnNormalLevels << Set Icon(nsICONS:FAIL_ICON)ītnNormalLevels << Set Icon(nsICONS:PASS_ICON) The revisions are highlighted below:ĪrrPValues = Test Normal Each Level(dt,圜olName,xColName) To use the function the same pattern of code is used as for the tests described in the last two posts. Now that the test is implemented in code and saved within the Analysis Components JSL file, it is available for use within the main code ( step5.jsl) of the oneway advisor. The Min function identifies the smallest item in this list which is stored in the variable pValue The variable lstPValues created in line 18 is a list.Line 18 gets a list of p-values from the column referenced by cbPValue. Line 16 creates a variable cbPValuethat references the “Prob > F” column if the number of levels is not 2.Line 14 creates a variable cbPValuethat references the p-value column in the results table, if the number of levels is 2.Line 12 gets a reference to the table containing the results.Line 11 gets a reference to the outline box containing the tabulated results.Line 10 creates the variable rep which is a reference to the window containing the Oneway results.Line 8 is the code equivalent of selecting Unequal Variance option found under the red triangle.Lines 3 and 4 contain the code illustrated earlier for determining the number of levels in the x-variable.There are a lot of interesting ways to implement this in code and we could go on quite a tangent exploring all the methods – but to keep the discussion focussed I’m just going to state the following code without too much justification, other than it works: Given that the output differs based on the number of levels within the grouping variable we’ll need some code to find the number of levels. If the grouping variable has more than two levels then the p-Value column takes the label “Prob > F” as illustrated below:.The above table is contained within an outline box called “Tests that the Variances are Equal”.I’m going to choose to implement the third option.Ī couple of points that will become relevant to the code implementation: look at all the tests and select the lowest p-value use the Bartlett test if the data have been demonstrated to be normally distributed, otherwise use the Levene test e.g Levene and only look at the p-value associated with this test It seems that our professors of statistics can’t quite agree on how to perform this test! I can think of three ways of dealing with this table of information: This test is performed in JMP by selecting the Unequal Variance option from the red triangle option within the Oneway platform. In this step a test will be performed to assess whether the data within each level of the grouping variable have equal variance. The advisor automates four tests associated with the assumptions of a oneway analysis of variance. This is the sixth and penultimate step in constructing the oneway advisor.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |