we'll see how long it actually takes to catch'em all! You are given a file data/pokemon.txt...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
we'll see how long it actually takes to "catch'em all"! You are given a file data/pokemon.txt which contains information about several (fictional) Pokemon, such as their encounter rate and catch rate. The data for this problem follows the following format. Col 1: pokemon id: A unique identifier for the Pokemon. Col 2: is legendary: A 1 if the Pokemon is legendary, and 0 otherwise. Col 3: height: The height of the Pokemon in meters. Col 4: weight: The weight of the Pokemon in kilograms. Col 5: encounter prob: The probability of encountering this Pokemon in the wild grass. Note the sum of this entire column is 1, since when you make an encounter, exactly one of these Pokemon appears. Col 6: catch prob: Once you have encountered a Pokemon, the probability you catch it. (Ignore any mechanics of the actual game if you've played a Pokemon game in the past.) code for the following parts in the provided file: pokemon py You'll need to implement the following functions: part a: Compute the proportion of Pokemon that are legendary, the average height, the average weight, the average encounter prob, and average catch prob. part b: Compute the proportion of Pokemon that are legendary, the average height, the average weight, the average encounter prob, and average catch prob OF ONLY those Pokemon STRICTLY heavier than the median weight. part c: Suppose you are walking around the wild grass, and you wonder: how many encounters do you expect to make until you ENCOUNTER each Pokemon (at least) once? part d: Suppose you are walking around the wild grass, and you wonder: how many encounters do you expect to make until you CATCH each Pokemon (at least) once? - For part c and part d, you need to consider that the probability to encounter/catch each pokemon is different. - When you need to use random function, use system random function with seed = 1 Data: 00 0 83.5668 10.9318 0.0404 0.7294 01 0 10.9272 19.8540 0.0414 0.7872 02 0 74.5917 1.6116 0.0308 0.7550 03 0 36.3698 8.2771 0.0320 0.9591 04 0 36.2514 1.7335 0.0551 0.8247 051 61.1192 1.8982 0.0353 0.8299 06 0 39.6811 1.0984 0.0526 0.4059 07 0 41.2027 2.2682 0.0323 0.6624 08 0 51.2353 6.0732 0.0314 0.9112 09 0 71.1597 15.8267 0.0366 0.3455 10 0 96.0724 46.9102 0.0363 0.4553 we'll see how long it actually takes to "catch'em all"! You are given a file data/pokemon.txt which contains information about several (fictional) Pokemon, such as their encounter rate and catch rate. The data for this problem follows the following format. Col 1: pokemon id: A unique identifier for the Pokemon. Col 2: is legendary: A 1 if the Pokemon is legendary, and 0 otherwise. Col 3: height: The height of the Pokemon in meters. Col 4: weight: The weight of the Pokemon in kilograms. Col 5: encounter prob: The probability of encountering this Pokemon in the wild grass. Note the sum of this entire column is 1, since when you make an encounter, exactly one of these Pokemon appears. Col 6: catch prob: Once you have encountered a Pokemon, the probability you catch it. (Ignore any mechanics of the actual game if you've played a Pokemon game in the past.) code for the following parts in the provided file: pokemon py You'll need to implement the following functions: part a: Compute the proportion of Pokemon that are legendary, the average height, the average weight, the average encounter prob, and average catch prob. part b: Compute the proportion of Pokemon that are legendary, the average height, the average weight, the average encounter prob, and average catch prob OF ONLY those Pokemon STRICTLY heavier than the median weight. part c: Suppose you are walking around the wild grass, and you wonder: how many encounters do you expect to make until you ENCOUNTER each Pokemon (at least) once? part d: Suppose you are walking around the wild grass, and you wonder: how many encounters do you expect to make until you CATCH each Pokemon (at least) once? - For part c and part d, you need to consider that the probability to encounter/catch each pokemon is different. - When you need to use random function, use system random function with seed = 1 Data: 00 0 83.5668 10.9318 0.0404 0.7294 01 0 10.9272 19.8540 0.0414 0.7872 02 0 74.5917 1.6116 0.0308 0.7550 03 0 36.3698 8.2771 0.0320 0.9591 04 0 36.2514 1.7335 0.0551 0.8247 051 61.1192 1.8982 0.0353 0.8299 06 0 39.6811 1.0984 0.0526 0.4059 07 0 41.2027 2.2682 0.0323 0.6624 08 0 51.2353 6.0732 0.0314 0.9112 09 0 71.1597 15.8267 0.0366 0.3455 10 0 96.0724 46.9102 0.0363 0.4553
Expert Answer:
Answer rating: 100% (QA)
Part A Question Explain the code in parta and how it computes various statistics The parta function computes several statistics for Pokmon data Proportion of Legendary Pokmon Average Height Average We... View the full answer
Related Book For
Management Accounting Information for Decision-Making and Strategy Execution
ISBN: 978-0137024971
6th Edition
Authors: Anthony A. Atkinson, Robert S. Kaplan, Ella Mae Matsumura, S. Mark Young
Posted Date:
Students also viewed these programming questions
-
You are evaluating a project that will cost $500,000, but is expected to produce cash flows of $125,000 per year for 10 years, with the first cash flow in one year. Your cost of capital is 11% and...
-
This assignment reviews object-oriented programming concepts such as classes, methods, constructors, accessor methods, and access modifiers. It makes use of an array of objects as a class data...
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
Which of the following would be least important in the pursuit of a time-based strategy? A) flexible technology B) operational agility C) reduced complaint resolution times D) quick changeover times...
-
Using a method of your choice, verify each of the equivalences inFigure. (a AB) = (BA a) commutativity of A (a v B) = (B V a) commutativity of v ((a ^ 3) A7) = (a^ (BA)) associativity of A ((a V B) v...
-
Define additional paid-in capital.
-
Hi-Cloud, Inc., is a start-up tech company. It is seeking a substantial line of credit from a federally insured commercial bank. Among other questions, the loan application requires disclosure of the...
-
Corizon Company's balance sheet and income statement are shown below (in millions of dollars). Corizon and its creditors have agreed upon a voluntary reorganization plan. In this plan, each share of...
-
1.Which of the following is an advantage of implementing just-in-time inventory management? Pick 1 option The frequency of raw materials deliveries is reduced Monthly finance costs incurred in...
-
Robert takes loan of $14k to buy a truck and seller is offering a uniform series of payment at 6.5% interest for 5 years. Calculate the monthly payment that Robert has to pay to buy that truck
-
Find the: Force exerted by left scale ( N ) Horizontal component ( N ) Vertical component ( N ) Force exerted by right scale ( N ) Horizontal component ( N ) Vertical component ( N ) Difference...
-
What do we mean by people-centred change techniques in organizational development?
-
Assess the usefulness of EAPs.
-
Define the following terms: (a) action research; (b) group inertia; (c) co-optation; (d) change agent; and (e) cycle of coping.
-
Distinguish between power, politics, and confect in organizations.
-
Comment on issues related to an evaluation of organizational development.
-
Reste - O b. Seleccione una: 7 O a. 4 C. 12 O d. 2 5 21 ( 1 1 -3 -2 3 3 5 5 - - 8 17 8 3 - -5 0 -5 3 - - -5 -4 3)-(:( 2 1)) 8 4-2 5 0 7-10 3 -21 8 15 8 7 8 9 4 -1 4 (3) 3 8 2 25 8 -2 3 3
-
In Exercises 15 through 30, find the derivative dy/dx. In some of these problems, you may need to use implicit differentiation or logarithmic differentiation. y ex + et -2x 1 + e
-
According to this chapter, the target costing and traditional cost reduction methods approach the relationships among cost, selling price, and profit margin quite differently. Required Write an essay...
-
Identify an organization with the low-total-cost value proposition and suggest at least two possible measures within each of the four Balanced Scorecard perspectives.
-
Organizations in the public and nonprofit sector, such as government agencies and charitable social service entities, have financial systems that budget expenses and monitor and control actual...
-
Why do most computer systems use memory-mapped I/O?
-
Write a simple loop that lets you exercise the cache. By changing the number of statements in the loop body, you can vary the cache hit rate of the loop as it executes. If your microprocessor fetches...
-
Draw a timing diagram for a burst write operation that writes four locations.
Study smarter with the SolutionInn App