vendredi 5 avril 2019

Random number grouped per column value in an Excel table?

I'm looking for a way to generate a random number in an Excel table, grouped by one of the column values. In the example table below, each person gets a random number assigned to them. I can't use the RAND() function by itself because that would give each row a random number. How can this be done?

╔════════╦══════╦═════════╗
║ PERSON ║ YEAR ║ RANDOM  ║
╠════════╬══════╬═════════╣
║ Bob    ║ 2017 ║ .012345 ║
╠════════╬══════╬═════════╣
║ Alice  ║ 2017 ║ .444444 ║
╠════════╬══════╬═════════╣
║ Jerry  ║ 2018 ║ .272727 ║
╠════════╬══════╬═════════╣
║ Alice  ║ 2018 ║ .444444 ║
╠════════╬══════╬═════════╣
║ Bob    ║ 2018 ║ .012345 ║
╠════════╬══════╬═════════╣
║ Alice  ║ 2019 ║ .444444 ║
╚════════╩══════╩═════════╝




Aucun commentaire:

Enregistrer un commentaire