LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

The contingency table vi states that it is a 1-sided test.

Solved!
Go to solution

In LabVIEW 8.6, the contingency table vi manual states that it is a 1-sided test. Output suggests that it is a 2-sided Chi-square without Yates' correction.  Can someone clarify this?

Thanks, Bill

0 Kudos
Message 1 of 10
(3,775 Views)

Bill,

 

I believe the Contingency Table VI is using a Chi-square distribution to compute the one-sided probability of a random variable (from the distribution).

Regards,

Jared Boothe
Staff Hardware Engineer
National Instruments
0 Kudos
Message 2 of 10
(3,742 Views)

Hi Jared:

 

When I check it against the online GraphPad stat calculator, it only matches with the 2-sided Chi-square without Yates' correction. 

 

http://www.graphpad.com/quickcalcs/contingency1.cfm

 

Try, for instance, the attached vi and compare.

 

Thanks, Bill 

0 Kudos
Message 3 of 10
(3,734 Views)

Hi Jared:

 

Can't figure out how to attache a a vi from the Mac OS.  (I'll figure that out.)

See the attached jpg's 

 

Thanks, Bill 

Download All
0 Kudos
Message 4 of 10
(3,733 Views)

Bill,

 

I see exactly what you are seeing.  I'm going to look into this a bit more, but I believe it is probably using Pearson Chi-Squared.  The result from the GraphPad calculator with that method is much more in-line with what LabVIEW generates.  Additionally, using a more sophisticated online Chi-Squared calculator, the results are almost exactly the same as LabVIEWs. 

 

http://www.socr.ucla.edu/htmls/ana/ChiSquareCT_Analysis.html

Regards,

Jared Boothe
Staff Hardware Engineer
National Instruments
0 Kudos
Message 5 of 10
(3,706 Views)

Bill,

 

This was reported to R&D (# 135926) for further investigation.  This is regarding the clarification of the documentation.  I will post back when I receive an update on this.

 

 

Regards,

Jared Boothe
Staff Hardware Engineer
National Instruments
0 Kudos
Message 6 of 10
(3,693 Views)

Jared:

Will look forward to it and thanks for the link,

Bill 

0 Kudos
Message 7 of 10
(3,682 Views)
Solution
Accepted by wjdwyer
Bill,

This function is indeed using Pearson's Chil-Square and does not apply the Yates' correction.  Additionally, the "p-value" for the computed Chi-Square statistic is computer as the Prob (X > x), which is equal to 1.0 - Prob (X <= x).

Little x is the statistic that we computer based on the data in the table, and Prob() is from the Chi-Square distribution function.  Basically the area under the PDF to the right of x is equal to 1 - area under the PDF to the left of x.

Computing the area to the right of x is the one-sided computation.

Hopefully this helps clarify some things!
Regards,

Jared Boothe
Staff Hardware Engineer
National Instruments
Message 8 of 10
(3,602 Views)

Bill,

 

You commented several posts back about the difficulty of attaching files from your Mac.  There is a known issue with Safari and at least one other browser.  The work around is to convert the files to .zip files and attach those.  I think .jpg and .png and perhaps text files can also be attached.   I think there is a thread about this in "Feedback on NI Discussion Forums" board.

 

Lynn 

Message 9 of 10
(3,598 Views)

Jared and Lynn:

 

Thank you both for the information!

 

Bill 

0 Kudos
Message 10 of 10
(3,587 Views)