cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar
mnamaria
Level I

Combined data table scripting

Hi

 

In monitoring life test data, I create Weibull plots using the Fit Life by X tool. 

This is easy to do and script.

However, within the Weibull Results, I want to use the Custom Estimation to give an Estimate Probability combined data table at a specific time.

As I want to script this analysis for repeated use, I saved the script from the combined data table in an attempt to use it.

However when I try it, it provides only an empty table with column names.

The same thing happens when I try to save the Statistics Estimates (alpha, beta, etc.) as a combined data table.

Any suggestions are welcome. 

(JMP 16.0.0)

 

New Table( "Untitled 1038",
	Add Rows( 1 ),
	New Script(
		"Make Combined Data Table",
		Names Default To Here( 1 );
		platform = Data Table( "sample_data" ) <<
		Fit Life by X(
			Distribution( Weibull ),
			Nested Model Tests( Location and Scale ),
			Y( :Time ),
			X( :Test ),
			Censor( :Failure ),
			Censor Code( 0 ),
			<<Fit Weibull,
			<<Confidence Level( 0.85 ),
			<<Confidence Level( 0.85 ),
			Use Transformation Scale( 0 ),
			Show Overlay by Levels( 1 ),
			<<Set Scale(
				Weibull,
				Simultaneous,
				Show Nonparametric CI( 0 ),
				Show Parametric CI( 1 )
			),
			<<Set Scriptables(
				{Distribution Comparisons(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 104, Lock( 0 ), Show( 1 ) )
						)
					)
				), Quantile Comparisons(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Probability( 0.5, Lock( 0 ), Show( 1 ) )
						)
					)
				), Hazard Comparisons(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.6, Lock( 0 ), Show( 1 ) )
						)
					)
				), Density Comparisons(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.6, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Distribution(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Quantile(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Probability( 0.5, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Hazard(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Density(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Estimate Probability( Wald, {104}, {0} ),
				Scatter Plot Show Distribution(
					Weibull( 0 ),
					Lognormal( 0 ),
					Loglogistic( 0 ),
					Frechet( 0 ),
					Exponential( 0 ),
					SEV( 0 ),
					Normal( 0 ),
					Logistic( 0 ),
					LEV( 0 )
				)}
			),
			Confidence Interval Method( Wald )
		);
		Wait( 0 );
		Report( platform )[Outline Box(
			"Fit Life by X - Time BY Discrete (Test) Location and Scale "
		)][Outline Box( "Results" )][Outline Box( "Weibull Results" )][
		Outline Box( "Estimate Probability" )][Table Box( 2 )] <<
		Make Combined Data Table;
		Report( platform ) << Close Window;
	),
	New Column( "Table", Character, "Nominal" ),
	New Column( "Time", Numeric, "Continuous", Format( "Fixed Dec", 12, 5 ) ),
	New Column( "Test", Character, "Nominal" ),
	New Column( "Failure Probability",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	),
	New Column( "Failure Probability Lower 85%",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	),
	New Column( "Failure Probability Upper 85%",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	)
)

image.pngimage.pngimage.pngimage.png

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Combined data table scripting

Instead of the red triangle, try right-clicking on the green triangle and choose "Edit":

midt.png

 

Then you can copy and paste that script into a new script window for automation. 

View solution in original post

4 REPLIES 4

Re: Combined data table scripting

I think you may have grabbed the wrong script. What you posted above looks like the table script obtained from the red triangle of the new table. Instead, try grabbing the script called "Make Combined Data Table" -- right click on the script name or the green triangle, and choose edit. If you copy and rerun that script, I believe you'll get the result you desire.

 

Additionally, it might be better for you to use "Make Into Data Table" rather than "Make Combined Data Table". It looks like you only want to extract the results from a single output section.

mnamaria
Level I

Re: Combined data table scripting

Thanks Jordan.

I have tried the "Make into Data Table" instead of the combined data table.

When the data table pops up, I did indeed copy the script from the red triangle.

I still get an empty table.

Here is the script. If copying from the red triangle is not the correct method, what is?

Take care.

 

New Table( "Untitled 1043",
	Add Rows( 1 ),
	New Script(
		"Make Into Data Table",
		Names Default To Here( 1 );
		platform = Data Table( "sample_data" ) <<
		Fit Life by X(
			Distribution( Weibull ),
			Nested Model Tests( Location and Scale ),
			Y( :Time ),
			X( :Test ),
			Censor( :Failure ),
			Censor Code( 0 ),
			<<Fit Weibull,
			<<Confidence Level( 0.85 ),
			<<Confidence Level( 0.85 ),
			<<Confidence Level( 0.85 ),
			Use Transformation Scale( 0 ),
			Show Overlay by Levels( 1 ),
			<<Set Scale(
				Weibull,
				Simultaneous,
				Show Nonparametric CI( 0 ),
				Show Parametric CI( 1 )
			),
			<<Set Scriptables(
				{Distribution Comparisons(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 104, Lock( 0 ), Show( 1 ) )
						)
					)
				), Quantile Comparisons(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Probability( 0.5, Lock( 0 ), Show( 1 ) )
						)
					)
				), Hazard Comparisons(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.6, Lock( 0 ), Show( 1 ) )
						)
					)
				), Density Comparisons(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.6, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Distribution(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Quantile(
					Profiler(
						1,
						Confidence Intervals( 1 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Probability( 0.5, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Hazard(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Density(
					Profiler(
						1,
						Confidence Intervals( 0 ),
						Term Value(
							Test( "Test", Lock( 0 ), Show( 1 ) ),
							Time( 125.597078279685, Lock( 0 ), Show( 1 ) )
						)
					)
				), Weibull Estimate Probability( Wald, {104}, {0} ),
				Scatter Plot Show Distribution(
					Weibull( 0 ),
					Lognormal( 0 ),
					Loglogistic( 0 ),
					Frechet( 0 ),
					Exponential( 0 ),
					SEV( 0 ),
					Normal( 0 ),
					Logistic( 0 ),
					LEV( 0 )
				)}
			),
			Confidence Interval Method( Wald )
		);
		Wait( 0 );
		Report( platform )[Outline Box(
			"Fit Life by X - Time BY Discrete (Test) Location and Scale "
		)][Outline Box( "Results" )][Outline Box( "Weibull Results" )][
		Outline Box( "Estimate Probability" )][Table Box( 2 )] <<
		Make Into Data Table;
		Report( platform ) << Close Window;
	),
	New Column( "Time", Numeric, "Continuous", Format( "Fixed Dec", 12, 5 ) ),
	New Column( "Test", Character, "Nominal" ),
	New Column( "Failure Probability",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	),
	New Column( "Failure Probability Lower 85%",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	),
	New Column( "Failure Probability Upper 85%",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 8 )
	)
);

Re: Combined data table scripting

Instead of the red triangle, try right-clicking on the green triangle and choose "Edit":

midt.png

 

Then you can copy and paste that script into a new script window for automation. 

mnamaria
Level I

Re: Combined data table scripting

Ah! Very good. Thank you very much!!