Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Re: What is the valid range of random seed?

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Jun 14, 2019 11:28 AM
(1435 views)

2 ACCEPTED SOLUTIONS

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Hi @vince_faller,

At first, I thought it would be something on the order of 1 to (2^19937)-1, because that's the period of the Mersenne Twister generator JMP uses. But, though some trial and error I discovered it seems to be somewhere in the neighborhood of 1 to a 64bit integer. Below is a script where I fit two neural models with the seed set, and around 9,223,372,036,854,775,295 is where I cross over to the seed not actually being set (i.e., the models don't match since the holdout sets differ). Interestingly it's not always right at 9223372036854775295 that things break down. Sometimes it's 9223372036854775295+1, sometimes it's 9223372036854775295 + 1000. I'm confused by that, and I'm sorry I don't have an explanation for why; hopefully, someone else will!

```
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
seed = 9223372036854775295; //works, i.e., same results for validation
//seed = 9223372036854775295 + 1000; //does not work
Neural(
Y( :sex ), X( :height, :weight ),
Informative Missing( 0 ),
Validation Method( "Holdback", 0.3333 ),
Set Random Seed( seed ),
Fit( NTanH( 3 ) )
);
Neural(
Y( :sex ), X( :height, :weight ),
Informative Missing( 0 ),
Validation Method( "Holdback", 0.3333 ),
Set Random Seed( seed ),
Fit( NTanH( 3 ) )
);
```

I hope this helps a bit!

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

It looks like the internal generator uses integers from 1 to (2^32)-1 for the reset value.

Craige

2 REPLIES 2

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Hi @vince_faller,

At first, I thought it would be something on the order of 1 to (2^19937)-1, because that's the period of the Mersenne Twister generator JMP uses. But, though some trial and error I discovered it seems to be somewhere in the neighborhood of 1 to a 64bit integer. Below is a script where I fit two neural models with the seed set, and around 9,223,372,036,854,775,295 is where I cross over to the seed not actually being set (i.e., the models don't match since the holdout sets differ). Interestingly it's not always right at 9223372036854775295 that things break down. Sometimes it's 9223372036854775295+1, sometimes it's 9223372036854775295 + 1000. I'm confused by that, and I'm sorry I don't have an explanation for why; hopefully, someone else will!

```
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
seed = 9223372036854775295; //works, i.e., same results for validation
//seed = 9223372036854775295 + 1000; //does not work
Neural(
Y( :sex ), X( :height, :weight ),
Informative Missing( 0 ),
Validation Method( "Holdback", 0.3333 ),
Set Random Seed( seed ),
Fit( NTanH( 3 ) )
);
Neural(
Y( :sex ), X( :height, :weight ),
Informative Missing( 0 ),
Validation Method( "Holdback", 0.3333 ),
Set Random Seed( seed ),
Fit( NTanH( 3 ) )
);
```

I hope this helps a bit!

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

It looks like the internal generator uses integers from 1 to (2^32)-1 for the reset value.

Craige