Report
Summary: Creates a report by opening a data table, launching the Fit Model dialog, and generating a report object.
Code:
dt = Open("data_table.jmp");
dlg = dt << Fit Model;
rpt = Report( dlg );
Code Explanation:
- Open data table;
- Launch Fit Model dialog.
- Create report object.
Report using Run Script
Example 1
Summary: Executes three SEM scripts and generates reports for growth comparison, latent growth curve analysis, and conditional growth curve modeling.
Code:
dt = Open("data_table.jmp");
obj3 = dt << Run Script( "SEM: Compare Growth Trajectories" );
rpt3 = obj3 << Report();
obj4 = dt << Run Script( "SEM: LGC with LDF" );
rpt4 = obj4 << Report();
obj5 = dt << Run Script( "SEM: Conditional LGC" );
rpt5 = obj5 << Report();
Code Explanation:
- Open data table.
- Run SEM script for growth comparison.
- Generate report from growth comparison.
- Run SEM script with latent growth curve.
- Generate report from latent growth curve.
- Run SEM script with conditional growth curve.
- Generate report from conditional growth curve.
Example 2
Summary: Generates two SEM reports using different estimators, leveraging the Run Script function to execute the Bollen (1989) and MIIV-2SLS Estimator scripts.
Code:
dt = Open("data_table.jmp");
obj1 = dt << Run Script( "SEM: Bollen (1989)" );
rpt1 = obj1 << Report();
obj2 = dt << Run Script( "SEM: Bollen (1989) MIIV-2SLS Estimator" );
rpt2 = obj2 << Report();
Code Explanation:
- Open table.
- Run SEM script.
- Generate report.
- Run another SEM script.
- Generate another report.
Example 3
Summary: Executes a SEM Bi-Factor Model script and generates a report from the output.
Code:
dt = Open("data_table.jmp");
obj9 = dt << Run Script( "SEM: Bi-Factor Model" );
rpt9 = obj9 << Report();
Code Explanation:
- Open data table.
- Run SEM Bi-Factor Model script.
- Generate report from output.
Example 4
Summary: Executes a Second-Order CFA SEM script and generates a report object, allowing for further analysis and visualization.
Code:
dt = Open("data_table.jmp");
obj10 = dt << Run Script( "SEM: Second-Order CFA" );
rpt9 = obj10 << Report();
Code Explanation:
- Open data table.
- Run SEM script.
- Retrieve report object.
Example 5
Summary: Executes two SEM scripts, Multivariate LGC and Multiple Group Analysis LGC, on a data table and generates reports for each script.
Code:
dt = Open("data_table.jmp");
obj11 = dt << Run Script( "SEM: Multivariate LGC" );
rpt11 = obj11 << Report();
obj12 = dt << Run Script( "SEM: Multiple Group Analysis LGC" );
rpt12 = obj12 << Report();
Code Explanation:
- Open data table;
- Run SEM: Multivariate LGC script.
- Generate report from obj11.
- Run SEM: Multiple Group Analysis LGC script.
- Generate report from obj12.
Example 6
Summary: Executes four SEM scripts to analyze student perceptions, grades, and measurement invariance across groups, generating reports for each analysis.
Code:
dt = Open("data_table.jmp");
obj13 = dt << Run Script( "SEM: Measure Students Perceptions" );
rpt13 = obj13 << Report();
obj14 = dt << Run Script( "SEM: Students Perceptions and Grades" );
rpt14 = obj14 << Report();
obj15 = dt << Run Script( "SEM: Mediation Analysis" );
rpt15 = obj15 << Report();
obj16 = dt << Run Script( "Measurement Invariance Across Groups (Gender)" );
rpt16 = obj16 << Report();
Code Explanation:
- Open data table.
- Run SEM script for student perceptions.
- Extract report from SEM analysis.
- Run SEM script for perceptions and grades.
- Extract report from SEM analysis.
- Run SEM script for mediation analysis.
- Extract report from SEM analysis.
- Run SEM script for measurement invariance.
- Extract report from SEM analysis.
- End script execution.
Example 7
Summary: Executes a Small Sample SEM script and generates a report from the results, utilizing JMP's Run Script and Report functions.
Code:
dt = Open("data_table.jmp");
obj17 = dt << Run Script( "Small Sample SEM MIIV-2SLS" );
rpt17 = obj17 << Report();
Code Explanation:
- Open data table;
- Run Small Sample SEM script.
- Generate report from results.
Example 8
Summary: Runs the reliability growth analysis by running a script, extracting estimates matrices, and updating data table rows.
Code:
dt = Open("data_table.jmp");
rg = dt << Run Script( "Reliability Growth" );
m1 = Report( rg )["Estimates"][Table Box( 1 )] << get as matrix;
dt << Add Rows( 2 );
dt:Hours[14] = 11000;
dt:Hours[15] = 12000;
rg2 = dt << Run Script( "Reliability Growth" );
m2 = Report( rg2 )["Estimates"][Table Box( 1 )] << get as matrix;
Code Explanation:
- Open data table.
- Run reliability growth script.
- Extract estimates matrix.
- Add two rows to table.
- Set Hours for new rows.
- Run reliability growth script again.
- Extract new estimates matrix.
Report using Set Property
Summary: Executes Proportional Hazards scripts on a data table, modifying missing value codes and modeling types to analyze the impact on parameter estimates.
Code:
dt = Open("data_table.jmp");
dt:days << Set Property( "Missing Value Codes", {142, 143, 163, 164} );
ph1 = dt << Run Script( "Proportional Hazards" );
rv1 = Report( ph1 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
dt:days[{1, 2, 4, 5}] = .;
ph2 = dt << Run Script( "Proportional Hazards" );
rv2 = Report( ph2 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
dt = dt << Revert;
dt:Group << Lock( 0 );
dt:Group[1 :: 3] = 3;
dt:Group << Set Property( "Missing Value Codes", 3 );
dt:Group << Set Modeling Type( "Continuous" );
ph1 = dt << Run Script( "Proportional Hazards" );
rv1 = Report( ph1 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
dt:Group[1 :: 3] = .;
ph2 = dt << Run Script( "Proportional Hazards" );
rv2 = Report( ph2 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
dt = dt << Revert;
dt:Censor << Lock( 0 );
dt:Censor[10 :: 15] = 3;
dt:Censor << Set Property( "Missing Value Code", {3} );
ph1 = dt << Run Script( "Proportional Hazards" );
rv1 = Report( ph1 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
dt:Censor[10 :: 15] = .;
ph2 = dt << Run Script( "Proportional Hazards" );
rv2 = Report( ph2 )["Parameter Estimates"][Table Box( 1 )] << get as matrix;
Code Explanation:
- Open data table;
- Set missing value codes for days.
- Run Proportional Hazards script.
- Extract parameter estimates matrix.
- Replace specific days values with missing.
- Run Proportional Hazards script again.
- Extract new parameter estimates matrix.
- Revert dataset changes.
- Lock Group column.
- Modify Group values.
- Set missing value code for Group.
- Change Group modeling type to Continuous.
- Run Proportional Hazards script.
- Extract parameter estimates matrix.
- Replace Group values with missing.
- Run Proportional Hazards script again.
- Extract new parameter estimates matrix.
- Revert dataset changes.
- Lock Censor column.
- Modify Censor values.
- Set missing value code for Censor.
- Run Proportional Hazards script.
- Extract parameter estimates matrix.
- Replace Censor values with missing.
- Run Proportional Hazards script again.
- Extract new parameter estimates matrix.
Report using Chart
Summary: Creates a range chart with multiple series, connecting points and customizing pen style, and sends report settings to frame box.
Code:
dt = Open("data_table.jmp");
obj = Chart(
X( :Date ),
Y( :High, :Low, :Close ),
Range Chart( 1 ),
Y[3] << {Connect Points( 1 ), Pen Style( 1 )},
SendToReport( Dispatch( {}, "Chart", FrameBox, {Frame Size( 868, 207 ), Line Width Scale( 0.5 )} ) )
);
Code Explanation:
- Open data_table data
- Create chart object.
- Set X-axis to Date.
- Add High, Low, Close to Y-axis.
- Enable range chart.
- Connect points for Close series.
- Set pen style for Close series.
- Send report settings.
- Set frame size.
- Adjust line width scale.