Subscribe Bookmark RSS Feed

how to output random table from prediction profiler in fit model

WHTseng

Occasional Contributor

Joined:

May 19, 2017

Hi JMPers,

 

I used the standard least squares of fit model, and tried to output a random data table based on the prediction profilers.

It is easy to right click manually the red triangle of Prediction Profilers, and select "Output random table".

But how to make this small action into script?

Here is what I tried but failed. Thank you for any reply in advanced.

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );
obj = Fit Model(
Y( :ABRASION, :HARDNESS ),
Effects( :SILICA, :SILANE, :SULFUR ),
Personality( Standard Least Squares ),
Emphasis( Minimal Report ),
Run

);
obj << Profiler( 1 );

obj << Output Random Table( 1000 );

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson

Super User

Joined:

Jun 22, 2012

Solution

Here is a method that does what you want:

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );
obj = Fit Model(
	Y( :ABRASION, :HARDNESS ),
	Effects( :SILICA, :SILANE, :SULFUR ),
	Personality( Standard Least Squares ),
	Emphasis( Minimal Report ),
	Run
);
obj << prediction formula;
newobj = dt << Profiler(
	Y(
		:Name("Pred Formula ABRASION 2"),
		:Name("Pred Formula HARDNESS 2")
	)
);
newobj << Output Random Table( 1000 );
Jim
3 REPLIES
txnelson

Super User

Joined:

Jun 22, 2012

Solution

Here is a method that does what you want:

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );
obj = Fit Model(
	Y( :ABRASION, :HARDNESS ),
	Effects( :SILICA, :SILANE, :SULFUR ),
	Personality( Standard Least Squares ),
	Emphasis( Minimal Report ),
	Run
);
obj << prediction formula;
newobj = dt << Profiler(
	Y(
		:Name("Pred Formula ABRASION 2"),
		:Name("Pred Formula HARDNESS 2")
	)
);
newobj << Output Random Table( 1000 );
Jim
WHTseng

Occasional Contributor

Joined:

May 19, 2017

Thank you Jim.
I think the key point is " << prediction formula;".

Just out of curiosity, is there a way to generate random table directly from fit model instead of using "<<Prediction formula" ?
txnelson

Super User

Joined:

Jun 22, 2012

I am not aware of anyway to do that.

Jim