The Altair Community is migrating to a new platform to provide a better experience for you. The RapidMiner Community will merge with the Altair Community at the same time. In preparation for the migration, both communities are on read-only mode from July 15th - July 24th, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here.
Options

Generate a Random Number (New Number With Each Instance)

roman_toblerroman_tobler Member Posts: 2 Contributor I
edited November 2018 in Help

Hi there

 

I'm working on a process that creates two random numbers. The following ways have been tested already:

  • I used the "Generate Data" operator and tried to use both the attributes as well the label
  • I used the "Generate Attributes" rand()

I got to a positive result with each scenario. My result is showing me two numbers the way I want, alright. However, if I run the process a second time the numbers do not change (no random new number is generated) - the same numbers are the output of every new instance of the process.

What operator or work-around is to be used in order to get new random numbers for each time I run the process anew?

 

Many thanks in advance!

Roman

Answers

  • Options
    Thomas_OttThomas_Ott RapidMiner Certified Analyst, RapidMiner Certified Expert, Member Posts: 1,761 Unicorn

    @roman_tobler i believe the random number generation is tied to the seed that RapidMiner generates at startup. I would change the seed to generate a different random number sequence. 

  • Options
    roman_toblerroman_tobler Member Posts: 2 Contributor I

    Hi Thomas

    Many thanks for your answer. The solution was to set the Random Seed as "-1" on the process level (global) and not on the operator itself.

    Cheers

    Roman

Sign In or Register to comment.