What is Probability?  Hit probabilities  Damage probabilities  Personality (e.g. chance of attack, run, etc.)  ???  Probabilities are used to add.

Slides:



Advertisements
Similar presentations
Introduction to Probability
Advertisements

Decision Making Under Risk Continued: Bayes’Theorem and Posterior Probabilities MGS Chapter 8 Slides 8c.
Copyright © 2010, 2007, 2004 Pearson Education, Inc. Chapter 14 From Randomness to Probability.
Section 7A: Fundamentals of Probability Section Objectives Define outcomes and event Construct a probability distribution Define subjective and empirical.
Introduction to probability BSAD 30 Dave Novak Source: Anderson et al., 2013 Quantitative Methods for Business 12 th edition – some slides are directly.
Business Statistics: A Decision-Making Approach, 6e © 2005 Prentice-Hall, Inc. Chap 4-1 Business Statistics: A Decision-Making Approach 6 th Edition Chapter.
Sherlock Holmes once observed that men are insoluble puzzles except in the aggregate, where they become mathematical certainties.
BCOR 1020 Business Statistics Lecture 6 – February 5, 2007.
1 BASIC NOTIONS OF PROBABILITY THEORY. NLE 2 What probability theory is for Suppose that we have a fair dice, with six faces, and that we keep throwing.
Copyright © 2005 Brooks/Cole, a division of Thomson Learning, Inc. 6.1 Chapter Six Probability.
Chapter 4 Probability.
Probability (cont.). Assigning Probabilities A probability is a value between 0 and 1 and is written either as a fraction or as a proportion. For the.
1 Basic Probability Statistics 515 Lecture Importance of Probability Modeling randomness and measuring uncertainty Describing the distributions.
CEEN-2131 Business Statistics: A Decision-Making Approach CEEN-2130/31/32 Using Probability and Probability Distributions.
Copyright © 2010, 2007, 2004 Pearson Education, Inc. Chapter 14 From Randomness to Probability.
Chapter 4 Probability Copyright © 2014 by The McGraw-Hill Companies, Inc. All rights reserved.McGraw-Hill/Irwin.
Basic Concepts and Approaches
Probability.
© 2016 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license.
QA in Finance/ Ch 3 Probability in Finance Probability.
1-1 Copyright © 2015, 2010, 2007 Pearson Education, Inc. Chapter 13, Slide 1 Chapter 13 From Randomness to Probability.
Chapter 8 Probability Section R Review. 2 Barnett/Ziegler/Byleen Finite Mathematics 12e Review for Chapter 8 Important Terms, Symbols, Concepts  8.1.
Sullivan – Fundamentals of Statistics – 2 nd Edition – Chapter 5 Section 1 – Slide 1 of 33 Chapter 5 Section 1 Probability Rules.
Dr. Gary Blau, Sean HanMonday, Aug 13, 2007 Statistical Design of Experiments SECTION I Probability Theory Review.
Copyright © 2010 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Chapter 4 Probability.
LECTURE 15 THURSDAY, 15 OCTOBER STA 291 Fall
Uses of Statistics: 1)Descriptive : To describe or summarize a collection of data points The data set in hand = the population of interest 2)Inferential.
Worked examples and exercises are in the text STROUD PROGRAMME 28 PROBABILITY.
1 1 Slide © 2016 Cengage Learning. All Rights Reserved. Probability is a numerical measure of the likelihood Probability is a numerical measure of the.
LECTURE 14 TUESDAY, 13 OCTOBER STA 291 Fall
Bayesian vs. frequentist inference frequentist: 1) Deductive hypothesis testing of Popper--ruling out alternative explanations Falsification: can prove.
Chapter 4 Probability ©. Sample Space sample space.S The possible outcomes of a random experiment are called the basic outcomes, and the set of all basic.
Introduction to Probability
1 Chapter 4 – Probability An Introduction. 2 Chapter Outline – Part 1  Experiments, Counting Rules, and Assigning Probabilities  Events and Their Probability.
Making sense of randomness
NLP. Introduction to NLP Very important for language processing Example in speech recognition: –“recognize speech” vs “wreck a nice beach” Example in.
Lesson Probability Rules. Objectives Understand the rules of probabilities Compute and interpret probabilities using the empirical method Compute.
From Randomness to Probability Chapter 14. Dealing with Random Phenomena A random phenomenon is a situation in which we know what outcomes could happen,
Sections 5.1 and 5.2 Review and Preview and Random Variables.
Probability You’ll probably like it!. Probability Definitions Probability assignment Complement, union, intersection of events Conditional probability.
1 1 Slide © 2007 Thomson South-Western. All Rights Reserved Chapter 4 Introduction to Probability Experiments, Counting Rules, and Assigning Probabilities.
Copyright © 2014 by McGraw-Hill Higher Education. All rights reserved. Essentials of Business Statistics: Communicating with Numbers By Sanjiv Jaggia and.
Fall 2002Biostat Probability Probability - meaning 1) classical 2) frequentist 3) subjective (personal) Sample space, events Mutually exclusive,
BIA 2610 – Statistical Methods
Introduction to Probability – Experimental Probability.
+ Chapter 5 Overview 5.1 Introducing Probability 5.2 Combining Events 5.3 Conditional Probability 5.4 Counting Methods 1.
PROBABILITY AND BAYES THEOREM 1. 2 POPULATION SAMPLE PROBABILITY STATISTICAL INFERENCE.
1 Probability- Basic Concepts and Approaches Dr. Jerrell T. Stracener, SAE Fellow Leadership in Engineering EMIS 7370/5370 STAT 5340 : PROBABILITY AND.
Econ 3790: Business and Economics Statistics Instructor: Yogesh Uppal
Lecture 2 Probability By Aziza Munir. Summary of last lecture Why QBA What is a model? Why to develop a model Types of models Flow chart of transformation.
Copyright © 2010 Pearson Education, Inc. Chapter 14 From Randomness to Probability.
Copyright © 2011 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Chapter 4 Probability.
Copyright © 2009 Pearson Education, Inc. Chapter 11 Understanding Randomness.
Chap 4-1 Chapter 4 Using Probability and Probability Distributions.
1 Copyright © 2014, 2012, 2009 Pearson Education, Inc. Chapter 9 Understanding Randomness.
PROBABILITY 1. Basic Terminology 2 Probability 3  Probability is the numerical measure of the likelihood that an event will occur  The probability.
AP Statistics From Randomness to Probability Chapter 14.
Chapter 2 Probability. Motivation We need concept of probability to make judgments about our hypotheses in the scientific method. Is the data consistent.
Chapter 4 - Introduction to Probability
From Randomness to Probability
Chapter 3 Probability.
From Randomness to Probability
From Randomness to Probability
From Randomness to Probability
Probability Probability underlies statistical inference - the drawing of conclusions from a sample of data. If samples are drawn at random, their characteristics.
Honors Statistics From Randomness to Probability
CS 594: Empirical Methods in HCC Introduction to Bayesian Analysis
6.1 Sample space, events, probability
Chapter 5 – Probability Rules
A random experiment gives rise to possible outcomes, but any particular outcome is uncertain – “random”. For example, tossing a coin… we know H or T will.
Presentation transcript:

What is Probability?

 Hit probabilities  Damage probabilities  Personality (e.g. chance of attack, run, etc.)  ???  Probabilities are used to add a little uncertainty into the game AI in terms of decision making (most of the time), strategy and tactics, and even spawn occurrences  We look at some examples…

 Generation of random numbers  Common practice  Seeding random numbers  Random numbers can be fed into various game AI – movement, decision-making, strategy to provide a sense of randomness  May not reflect behaviors intelligently

 Representing a character’s chances of hitting and opponent in combat or battle  Typically, a game developer defines several probabilities (RPG game e.g.) ◦ Moderate dexterity – 60% prob. of striking with knife in melee ◦ High dexterity – 90% prob. of striking with knife  Probabilities can be adjusted given other factors (High dex e.g.) ◦ 95% -- in possession of “Dagger of Speed” ◦ 85% -- opponent has magic armour

 Design hit probability tables to calculate the appropriate probability given the occurrence or non-occurrence of any number of events or conditions

 Define abilities of character classes using probabilities AbilityWizardFighterRougeRanger Use magic Wield sword Harvest wood Pick locks Find traps Read map ……………

 In practice, these probabilities can be further conditioned on the overall class level ◦ A first-level wizard might have only 10% chance of using magic ◦ The idea here is that as the player earns levels, his proficiency in the craft increases (reflected by the probabilities)  On the computer-side of the game AI, other characters in the world can have their own set of probability tables…

 Combine probabilities with state transitions in a FSM

 Instead of deterministically selecting a state to move to, assign certain probabilities to each transition ◦ 50% chance of attacking, 20% chance of fleeing, 10% chance of hiding  For even more variability, assign different probabilities to different types of characters, making some more aggressive than others, etc.  A step further  distinct personalities?

 How do we implement this efficiently?

 Update certain game probabilities as the game is played to facilitate computer- controlled AI learning and adapting (Non- deterministic AI) ◦ E.g. Collect statistics on the number and outcome of fights between different characters ◦ Probability of encounters resulting in a win (or death) can be calculated real-time ◦ Use this change of probabilities to make future decisions on whether to engage in battle or avoid certain characters or flee battle, etc.

 3 common interpretations of probability ◦ Classical Probability ◦ Frequency Interpretation ◦ Subjective Interpretation

 Refers to events and possibilities, or possible outcomes  Given an event E, which can occur in n ways out of a total of N possible outcomes, the probability p of occurrence of the event is: p = P(E) = n/N  P(E): Probability of success of the event  Probability of failure of the event: 1-P(E)

 E.g. Rolling a six-sided dice, the probability that a 4 would show up is…?  Consider two six-sided dice, both rolled at the same time, what is the probability that the sum of the numbers that show up equal to 5?

 Also known as relative frequency or objective probability  Considers events and samples or experiments  If an experiment is conducted N times and some event E occurs n times, the probability of E occurring is: P(E) = n/N as N    For finite number of experiments, the resulting probability will be approximate or empirical  derived statistically

 Frequentist approach: Coin tossed 1000 times ◦ Experimentally, the results could come to getting heads 510 times (e.g.), so the probability of getting heads is P(heads) = 0.51 or 51%  Should “approach” 0.5 if number of experiments increase…  Approximation by experiment

 A measure, on a scale from zero to one, of a person’s degree of belief that a particular event will occur given their knowledge, experience or judgment.  Useful when the event in question is not repeatable (therefore, can’t use frequentist approach)

 “It probably will rain tomorrow”, “I have a good chance of passing this subject”  More empirical e.g. “I have a 75% chance of passing this subject” ◦ If you later did better in the next homework/assignment, you might revise you belief that you have a 90% chance of passing the subject  Bayesian theory ◦ Allows us to update our belief of some event given the availability of new information

Odds ◦ Common in betting scenarios ◦ If we say the odds in favour of success of some event E, are “a to b” (3 to 1 odds, e.g.), the probability of success of that event, P(E) P(E) = a / (a+b) ◦ Can work the opposite direction, given the probability  work out the odds

Expectation ◦ Expected value of some discrete random variable X that can take on any values, x 0, x 1,…x n with probabilities p 0, p 1,…p n can be determined as: ◦ For such a distribution, you can think of expectation as an average value ◦ Measure of central tendency, measure of payoff

Expectation ◦ E.g. Online RPG – monitoring the number of players who gather at a local tavern/inn each evening – collecting intelligence ◦ Table shows the probabilities of no. of players each evening ◦ In this case, what is the expected number of players in the tavern in the evening? ◦ What use is this information? # PlayersProbability

 Difficult to pin down subjective probabilities to a specific method or number  Fine-tuning or “hacks” can be used

 When events are not independent, they are “conditional” ◦ E.g. if you find your lawn wet, what is the probability that it rained while you were at work? Is it possible that someone turned on your sprinklers while you were at work? ◦ Outcome of your grass being wet is “conditional” upon whether it rained, or whether someone turned on your sprinkler. ◦ Bayesian analysis

◦ If event A depends on whether event B occurred, we can’t use typical probability calculations P(A|B) ◦ Probability of A occurring given B has occurred: P(A|B) ◦ Probability of B occurring given A has occurred: P(B|A) P(A|B)  P(B|A)

◦ To find the compound probability of both A and B occurring, we say P(A  B) = P(A) P(B|A) ◦ But usually we are interested in the probability of an event given some other event has occurred P(B|A) = P(A  B)/P(A) = P(B) P(A|B) / P(A) ◦ Posterior = likelihood * prior marginal likelihood

 Example 1: A melee attack by a wizard character, with additional magical aid ◦ To determine the probability of a melee hit given magical aid P(hit) = 0.9, P(~hit) = 0.1 P(magic|hit) = 0.85 P(magic|~hit) = 0.15 P(hit|magic) = (0.9)(0.85) / [(0.9)(0.85)+(0.1)(0.15)] = 0.765/0.78 = Indicating stronger probability of hitting given magical aid

 Example 2: A 1-on-1 fight between a warrior (fighting ability) and a wizard (magic ability)  To determine the attacking (hit) probability of the warrior given the wizard’s magical ward defense C1: P(A) = 0.8, P(~A) = 0.2 C2: P(D|A) = 0.3 P(D|~A) = 0.7 P(A|D) = (0.8)(0.3) / [(0.8)(0.3)+(0.2)(0.7)] = 0.24/0.38 = Indicating weaker warrior attack probability given magic defense from wizard

 Bayesian inference, Bayesian networks for adding uncertainty to decision making (refer to textbook Chapter 13)