cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP will suspend normal business operations for our Winter Holiday beginning on Wednesday, Dec. 24, 2025, at 5:00 p.m. ET (2:00 p.m. ET for JMP Accounts Receivable).
    Regular business hours will resume at 9:00 a.m. ET on Friday, Jan. 2, 2026.
  • We’re retiring the File Exchange at the end of this year. The JMP Marketplace is now your destination for add-ins and extensions.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
RA899
Level IV

Test Time measurement

Hi all, 

I'm not 100% sure, but I think I have seen a function that stores the run time. I need a function that captures the test time from the moment I click run until the analysis is complete. I'm using JSL. Thanks

2 ACCEPTED SOLUTIONS

Accepted Solutions
mmarchandTSI
Level V

Re: Test Time measurement

I think most people use the Today() function for this.  For instance,

 

Names Default To Here( 1 );
starttime = Today();
pl = {};
For( i = 1, i <= 10000000, i++,
	Insert Into( pl, i )
);
endtime = Today();
Print( "Execution took " || Char( endtime - starttime ) || " seconds." );

I like to use HP Time(), which works just like Today(), but it's in microseconds.

 

Names Default To Here( 1 );
starttime = HP Time();
pl = {};
For( i = 1, i <= 10000000, i++,
	Insert Into( pl, i )
);
endtime = HP Time();
Print( "Execution took " || Char( endtime - starttime ) || " microseconds." );

View solution in original post

txnelson
Super User

Re: Test Time measurement

There is also a function called Tick Seconds() that can be used

Names Default To Here( 1 );
t1 = Tick Seconds();
Open( "$SAMPLE_DATA/Big Class.jmp" );
t2 = Tick Seconds();
Round( t2 - t1, 3 );

 

Jim

View solution in original post

3 REPLIES 3
mmarchandTSI
Level V

Re: Test Time measurement

I think most people use the Today() function for this.  For instance,

 

Names Default To Here( 1 );
starttime = Today();
pl = {};
For( i = 1, i <= 10000000, i++,
	Insert Into( pl, i )
);
endtime = Today();
Print( "Execution took " || Char( endtime - starttime ) || " seconds." );

I like to use HP Time(), which works just like Today(), but it's in microseconds.

 

Names Default To Here( 1 );
starttime = HP Time();
pl = {};
For( i = 1, i <= 10000000, i++,
	Insert Into( pl, i )
);
endtime = HP Time();
Print( "Execution took " || Char( endtime - starttime ) || " microseconds." );
txnelson
Super User

Re: Test Time measurement

There is also a function called Tick Seconds() that can be used

Names Default To Here( 1 );
t1 = Tick Seconds();
Open( "$SAMPLE_DATA/Big Class.jmp" );
t2 = Tick Seconds();
Round( t2 - t1, 3 );

 

Jim
RA899
Level IV

Re: Test Time measurement

Thank you both! Both solutions are helpful and does the job. 

Recommended Articles