DATA Step, Macro, Functions and more

seed? proc mi ?

Reply
Contributor
Posts: 22

seed? proc mi ?

proc mi data=auto2 seed=???out=auto_nomiss nimpute=1;
class doors cylinders fuel_type;
fcs reg(nlosses bore stroke horsepower peak_rpm/details) logistic(doors=cylinders fuel_type cylinders*fuel_type) ;
var  nlosses  bore stroke horsepower peak_rpm doors cylinders fuel_type;
run;

where is seed ? 

Super User
Posts: 24,012

Re: seed? proc mi ?

Posted in reply to michshoot

You didn't specify it, so there's no seed. I'm confused as to the question here.

Seed = ????

SEED=number

specifies a positive integer to start the pseudo-random number generator. The default is a value generated from reading the time of day from the computer’s clock. However, in order to duplicate the results under identical situations, you must use the same value of the seed explicitly in subsequent runs of the MI procedure.

The seed information is displayed in the "Model Information" table so that the results can be reproduced by specifying this seed with the SEED= option. You need to specify the same seed number in the future to reproduce the results.

 

This is any number you choose, there's no specific requirement for it to be anything. The purpose is to allow you to replicate the results to test as you go through. It's hard to test code with random results if they're constantly changing. 

 


@michshoot wrote:
proc mi data=auto2 seed=???out=auto_nomiss nimpute=1;
class doors cylinders fuel_type;
fcs reg(nlosses bore stroke horsepower peak_rpm/details) logistic(doors=cylinders fuel_type cylinders*fuel_type) ;
var  nlosses  bore stroke horsepower peak_rpm doors cylinders fuel_type;
run;

where is seed ? 


 

 

SAS Super FREQ
Posts: 4,275

Re: seed? proc mi ?

Posted in reply to michshoot

You can specify  any integer between 1 and 2 billion, such as

seed=12345

or

seed=<your telephone  number>

or

seed=938324751

 

For details, see "How to choose a seed for generating random numbers"

Ask a Question
Discussion stats
  • 2 replies
  • 140 views
  • 0 likes
  • 3 in conversation