Alexa Metrics

How RoboGarden predicted a competition’s scores

cartoon image showing robogarden

RoboGarden celebrated the Football World Cup by making an event about predicting who would win each match. The program used Artificial Intelligence to allow the user to control the inputs and how much each input was weighted.

In this context, weight determines how much a specific input will affect in the result of the match. After the user selects the weight of each input and submits their responses, RoboGarden predicts who will win the next match. The user(s) who had the most correct predictions won the event.

The prediction page

The main page prediction page consists of some pre-defined inputs (checkboxes). These inputs represent the factors that will affect the results: FIFA Rank, home advantage, recent team performance, team strength, etc. The weight of each input is determined by a slider that the user can adjust to determine how much or how little that input is used to determine the result.

When the input is enabled by having its checkbox checked, the attached slider becomes active. The slider can have values from 0% to 100%. For example, the user can choose for the weight of “Home Advantage” to be 90%, the weight of “Recent Team Performance” to be 15%, etc.

The Matches section includes the match(es) that will be played on the current day. If there are no matches on the current day, then the section will include match(es) for the next day, and so on. Each match is represented by the flags and names of the countries that will play together. This section also includes the percentage of prediction of other users of these matches. For example, today there’ll be a match between Brazil and Germany where 80% of users predicted that a win by Germany, 15% predicted a win by Brazil, and 5% predicted a draw.

There is a workspace section for the blocks. When the user enables an input, the selected input’s block will be added automatically to the workspace. Each block represents an enabled input with its weight.

But where is the code?

Finally, the Code Editor section includes equivalent Python code for the blocks. As inputs change, the Python code updates so that remains the equivalent of the enabled inputs.

After you finish working your magic, click the Submit button to submit the chosen inputs and their weights. The user’s data will be sent to an AI algorithm (equation). When the algorithm has run, the results will appear on screen to indicate who will win the upcoming match(es). The user can change the inputs and the weights and re-submit again, keeping in mind that the system will only save the most recent submission for each user.

The code the user submits, called the predictor, is applied to all matches on the same day. If, for example, there are four matches played on one day then the predictor will be applied to all four matches.

Once the first match of the day begins, users can’t update their submission again until all matches are finished. The submit button will be deactivated and disclaimer text will appear below it to notify the user that they cannot submit until all the matches for the current day are finished. Once the day’s matches are done, the Matches section will be updated with the matches that will be played next. At that point, the user can submit another predictor.

After you had had fun, you can share your predictions with your friends on Facebook, Twitter, and Google Plus. Your Score section will include your score, the number of predicted wins, the total number of matches predicted, and your rank among other users.

Who would have thought programming could be this fun? Take a sneak peek today at RoboGarden. Join today and register for free.

RoboGarden events



Do you want to learn coding in less time than possible and without any money, join us on the best platform ever on learning coding as a game for kids?

Canada Flag Privacy Policy Terms of Use
Got an invite