Below is a script that create the summary output table you stated was what you wanted. The script goes from the JMP data table you provided, through to it's completion. About 80% of the script was actually created by running the steps interactively in JMP, and then just having JMP save the script it used for the interactive processing to a script window. All of the steps and functions used in the script are documented in the Scripting Guide and Scripting Index
Names Default To Here( 1 ); dt = Current Data Table(); // Correct the data table using the JMP table imported from the Excel file For( i = 2, i <= N Cols( dt ), i++, Column( dt, i ) << set name( Word( 1, Column( dt, i ) << get name, " " ) || " " || Column( dt, i ) ) ); dt << delete rows( 1 ); For( i = 2, i <= N Cols( dt ), i++, Column( dt, i ) << data type( numeric ) << modeling type( continuous ) ); // Change the name of the first column to H(Oe) Column( dt, 1 ) << set name( "H(Oe)" ); // Create a list of all numeric column names colNamesList = dt << get column names( numeric ); // Summarize the data dtSum = dt << Summary( Mean( Eval( colNamesList ) ), Freq( "None" ), Weight( "None" ), statistics column name format( "column" ), Link to original data table( 0 ) ); // Create final table and sort it in alphabetical order // First delete the unneeded column N Rows dtSum << delete columns( "N Rows" ); dtFinal = dtSum << Transpose( columns( Eval( colNamesList ) ), Label column name( "Column" ), Output Table( "Summary " ) ); // Change the name of the "Row 1" column to "Mean" dtFinal:Row 1 << set name( "Mean" ); // Sort the data table dtFinal = dtFinal << sort( by( Column ), order( Ascending ), Replace Table( 1 ) );
I still can't output in a journal. I am trying this right now, but no luck.
jrn = New Window( "Reports", <<Journal );
jrn << Append( H List Box( (dtFinal << Report) ) ) ;
jrn <<Save Journal(("C:\!Destination!\Output.jrn") ) ;
The excel sheet I am using and recieving has six tabs and I want to consildate all the data into one journal so I can send it off or do more analysis. Thanks!
There are no labels assigned to this post.