Select your font size 
 
about us products & services consulting & support news & events contact us
Paul Meagher gives an example of calculating conditional probability using the set enumeration method.

Conditional probability - New Mexico

print this article 
 
1

A conditional probability refers to the probability of observing an event A given that you have observed a separate event B. The mathematical shorthand for expressing this idea is:

P(A | B)

Imagine that A refers to "customer buys product A" and B refers to "customer buys product B". P(A | B) would then read as the "probability that a customer will buy product A given that they have bought product B." If A tends to occur when B occurs, then knowing that B has occurred allows you to assign a higher probability to A's occurrence than in a situation in which you did not know that B occurred.

More generally, if A and B systematically co-vary in some way, then P(A | B) will not be equal to P(A). Conversely, if A and B are independent events, then P(A | B) would be expected to equal P(A).

The need to compute a conditional probability thus arises any time you think the occurence of some event has a bearing on the probability of another event's occurring.

The most basic and intuitive method for computing P(A | B) is the set enumeration method. Using this method, P(A | B) can be computed by counting the number of times A and B occur together {A & B} and dividing by the number of times B occurs :

P(A | B) = {A & B} /

If you observe that 12 customers to date bought product B and of those 12, 10 also bought product A, then P(A | B) would be estimated at 10/12 or 0.833. In other words, the probability of a customer buying product A given that they have purchased product B can be estimated at 83 percent by using a method that involves enumerating relative frequencies of A and B events from the data gathered to date.

You can compute a conditional probability using the set enumeration method with the following PHP code:

Listing 1. Computing conditional probability using set enumeration


Page: 1 2 3 4 5 6 7 8 9 10 11 Next Page: Learning from experience

 

The content shown in this page was first published by IBM developerWorks and is reprinted with permission from Paul Meagher (www.datavore.com)

 


Most Recent Website and Regional Updates

 Transparen Toronto Office Locations
Addresses of Transparen Corporation offices in Toronto, Ontario.

 
 High Scalability - Large Systems Optimization
Transparen Corporation lends its expertise to clients experiencing rapid and sudden growth in traffic or server utilization, bottlenecks, systems instability, downtime during peak traffic, or which would like to plan to avoid such issues.

 
 Throughput (or Bandwidth) vs. Latency
This document uses the example of Bill Gates purchasing Google to explain the difference between bandwidth (or throughput) and latency.

 
 Emergency Management Services
The prototypical emergency involves a shutdown of essential services for a finite period of time. What will your organization do when a world-wide financial crisis strikes?

 
 Fast RAID Server Data Recovery Service
Transparen's Vancouver International Response Team provides the option in Canada and USA to get a raid server back running in hours - eliminating costly waiting associated with typical RAID recoveries.

 
 Data Recovery Service
Have you deleted a mission critical file? Accidentally dropped a computer, or formatted a hard drive? No recent backup? Mistakes can happen, but the data might still be there.

 

Google
 
Web transparen.com

Contact Information

Related Information

 
   
 
E C M | © 2003-2007 Transparen Corp.      

Standardized Services: Data Recovery Service / Creative Services / Premium Web Hosting Services / System Administration Tech Support Services
Recent Projects: Full-Service Mortgage and Financing Company / System to manage flights from Vancouver to Tofino / Photo exchange verification service
Our Vancouver BC Server Proudly Hosts: automated parking and revenue control systems, leafside lane at southlands, cost effective alternative power sources, Higher Grade Learning Centres, pacific forage bag supply, sunburst medical, neosonic design, roger mahler photography - passionate, intriguing, desirable, the connection between east and west, affordable flights to victoria and tofino, low interest mortgage brokers in vancouver, richmond, surrey, toronto, Toronto Calgary and Vancouver IT staffing and talent search
* Alamogordo * Albuquerque * Artesia * Aztec * Bayard * Belen * Bloomfield * Carlsbad * Clovis * Deming * Elephant Butte * Espanola * Eunice * Farmington * Gallup * Grants * Hobbs * Jal * Las Cruces * Las Vegas * Lordsburg * Lovington * Moriarty * Portales * Raton * Rio Rancho * Roswell * Santa Fe * Santa Rosa * Socorro * Sunland Park * Texico * Truth or Consequences * Tucumcari * Bernalillo * Carrizozo * Clayton * Dexter * Edgewood * Elida * Estancia * Hagerman * Hurley * Lake Arthur * Mesilla * Mountainair * Red River * Silver City * Springer * Taos * Tatum * Vaughn * Angel Fire * Bosque Farms * Capitan * Causey * Chama * Cimarron * Cloudcroft * Columbus * Corona * Corrales * Cuba * Des Moines * Dora * Eagle Nest * Encino * Floyd * Folsom * Fort Sumner * Grady * Grenville * Hatch * Hope * House * Jemez Springs * Logan * Los Lunas * Los Ranchos de Albuquerque * Loving * Magdalena * Maxwell * Melrose * Milan * Mosquero * Pecos * Questa * Reserve * Roy * Ruidoso * Ruidoso Downs * San Jon * Santa Clara * San Ysidro * Taos Ski Valley * Tijeras * Tularosa * Virden * Wagon Mound * Willard * Williamsburg