Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Hi JMP users,
I would like to run Goodman-Kruskal gamma coefficient (or correlation) for measuring relative accuracy in Psychology field using JMP, but it seems JMP doesn't contain it on its stats package. The Goodman-Kruskal gamma coefficient is one of the most common measures of association in Statistics.
In R, I found the function GKgamma () in the packages "vcd" and "vcdExtra".
Thank you.
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?The JMP to R interface allows for a JMP script to pass to R JMP data tables, lists, matrices, etc. along with R programming statments, to R for porcessing and then retrieve the results back to JMP once the R processing has been completed.
See:
Help==>Books==Scripting Guide==>Working with R
A Bootstrap Sample
See the file JMPtoR_bootstrap.jsl in the sample scripts folder for an example script. This script performs a bootstrap simulation by using the JMP to R Project integration. The script produces a JMP window that asked the user to specify the variable to perform bootstrapping over. Then the user selects a statistic to compute for each bootstrap sample. Finally, the data is sent to R using the R interface in JSL. The boot package in R is used to call the boot() function and the boot.ci() function to calculate the sample statistic for each bootstrap sample and the bootstrap confidence interval. The results are brought back to JMP and displayed using the JMP Distribution platform.
/*
This script performs a bootstrap simulation by using the JMP to R Project integration.
A JMP Dialog is built where the variable you wish to perform bootstrapping over can be specified.
A statistic to compute for each bootstrap sample is chosen and the data are sent to R using new
JSL functionality available in JMP 9.
The boot package in R is used to call the boot() function and the boot.ci() function to
calculate the sample statistic for each bootstrap sample and the bootstrap confidence interval.
The results are brought back to JMP and displayed using the JMP Distribution platform.
*/
Names Default To Here( 1 );
StatList = {"Mean", "20% Trimmed Mean", "Median", "Standard Deviation", "Variance",
"Median Absolute Deviation (MAD)"};
RFunctionList = {"mean", "mean", "median", "sd", "var", "mad"};
//Generate Normal(0,1) data;
zmat = J( 50, 1, Random Normal() );
dt = New Table( "Normal(0,1) Random Data",
New Column( "Normal Data", Numeric, <<SET values=""></SET>
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?When you tell me "run your R code from JMP session under Mac", what do you mean about 'JMP session'? Does it refer to create and run a script? Tnx
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?You are correct. The JMP to R Addin Builder only works in Windows. However, JMP supports an interface to R. So you can run your R code from your JMP session under Mac.
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?The JMP community has a lot of information. Is this JMP Addin can be found in the URL https://community.jmp.com/t5/JMP-Add-Ins/The-JMP-to-R-Add-In-Builder/ta-p/43879 ?
It seems this JMP Add-in runs in Windows only, doesn't it?
Tnx, Jim!
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?There is also a JMP Addin available in the File Exchange "The JMP to R Addin Builder"
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Tnx, Jim!
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?The interface between JMP and R is documented in the Scripting Guide
Help==>Books==>Scripting Index==>Working with R
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Hi @txnelson
How can I run it from JMP, porting over your JMP data table using the JMP to R interface?
I need to learn this integration between JMP and R.
Tnx.
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Hi @bill_worley,
JMP works correctly and provides the same results.
I need to set up the variables as Numeric and Nominal
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?If it is available in R, then just take your R code and run it from JMP, porting over your JMP data table using the JMP to R interface.
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Clicking on that JMP reference page, it directs to the Goodman-Kruskal's work. So I think it is what I am looking for.
Thanks, @bill_worley
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Hi Bill, thank you for your post.
Well, I think it could be the same. I am not sure if there is any other Goodman-Kruskal gamma coefficient (correlation)... smiles...
I'll try to run it.
Best.
Re: Doesn't JMP contain Goodman-Kruskal gamma coefficient (or correlation) on its stats package?Check out the link below. I found it in the JMP 14 online documentation.
Measures of Association
Not sure if it is exactly what you want, but based on the Wikipedia definition it should be pretty close.