Calculate the Critical Chi-Square value within Knime

Hi everyone,

I have noticed that for calculate the Chi-Square value Knime provides the crosstab validation node. Can someone provide me a quick example workflow?

There are some other nodes that can also calculate the Critical Chi-Square value? Cause I need it for make a comparison between the Chi-Square value and the Critical Chi-Square value. Cause actually this relationship underlines if some nominal values are correlated or not.

Thanks in advance.
~gujo

Hi gujodm,

Just connect the Crosstab node to your data and choose two columns with categorical values you want to create a contingency table for. Check the Cross tabulation View for the contingency table view and the nodes outputs for the cross table in list form and the table with the statistics.

You can copy critical Chi-Square values for your degree of freedom and predefined p-value for example from here and copy them to a Table Creator or save as a CSV file and read it with the File Reader node.

Best,
Anna

2 Likes

Hi all,

I see there is the “weight” field to configure in this node.
What is the purpose of it when compared with Chi-square formula in R?

I noticed that only when setting ‘null’ for weight in Knime, it matches the result from below R formula:

contingency_table <- table(newData$Property, newData$Housing)
contingency_table
chisq.test(contingency_table)