Question

In: Computer Science

construct a bitmap index for the color column. Please please show steps or explain what you...

construct a bitmap index for the color column.

Please please show steps or explain what you did as i really want to learn how to do this.

RecordID Date Color Part Number
1 30-03-2014 Tiger stripes WTL-538
2 29-09-2014 Blue LER-137
3 04-05-2014 Green UGN-537
4 18-03-2014 Tiger stripes GBD-403
5 10-10-2014 Green IAJ-568
6 18-12-2014 Red HOE-123
7 05-04-2014 Tiger stripes LFT-811
8 16-01-2014 Tiger stripes XAV-564
9 11-12-2014 Red OHJ-400
10 07-04-2014 Blue BKX-628
11 27-11-2014 Green FZX-549
12 04-04-2014 Blue SJM-622
13 15-08-2014 Red XVC-474
14 14-03-2014 Tiger stripes UQR-421
15 20-04-2014 Tiger stripes CFT-658
16 31-07-2014 Green EUV-759
17 05-06-2014 Tiger stripes XSG-479
18 19-03-2014 Blue ODD-953
19 25-05-2014 Green YDS-862
20 10-09-2014 Red LTP-337
21 11-09-2014 Tiger stripes BTL-198
22 25-04-2014 Blue ZNO-843
23 24-03-2014 Green TOX-402
24 28-08-2014 Red FKL-572
25 10-11-2014 Red PVT-512
26 15-03-2014 Tiger stripes ZLM-790
27 14-06-2014 Tiger stripes PER-701
28 07-11-2014 Green CLU-499
29 23-04-2014 Red YJV-990
30 19-11-2014 Blue JQR-979
31 02-02-2014 Green HZK-103
32 04-08-2014 Green PRK-631
33 25-06-2014 Red XBL-745
34 03-09-2014 Green NXK-247
35 06-03-2014 Blue PDJ-970
36 22-04-2014 Green TUM-443
37 19-11-2014 Red LZP-290
38 10-11-2014 Red WJQ-620
39 09-11-2014 Red OZF-584
40 01-12-2014 Blue ALF-413
41 08-06-2014 Red IIV-220
42 09-04-2014 Red CNW-296
43 25-10-2014 Tiger stripes YKB-311
44 30-05-2014 Tiger stripes ACA-257
45 15-02-2014 Red TXE-796
46 22-03-2014 Tiger stripes ONN-909
47 18-12-2014 Red VHQ-888
48 09-02-2014 Green DOL-764
49 22-09-2014 Tiger stripes KKI-825
50 03-07-2014 Red BPE-622

Solutions

Expert Solution

Bitmap indices are used for columns with low cardinality. Here for each unique column entry, we'll store 1 at positions where that entry exists and in the rest positions put 0.

Uniques values of Color are:

Color
Tiger stripes
Blue
Green
Red

The positions where each of these colors exists is:

TIGER STRIPES:

1
4
7
8
14
15
17
21
26
27
43
44
46
49

BLUE:

2
10
12
18
22
30
35
40

GREEN:

3
5
11
16
19
23
28
31
32
34
36
48

RED:

6
9
13
20
24
25
29
33
37
38
39
41
42
45
47
50

Now, make the bitmaps by placing 1's and 0's.

RecordID Blue Green Red Tiger Stripes
1 0 0 0 1
2 1 0 0 0
3 0 1 0 0
4 0 0 0 1
5 0 1 0 0
6 0 0 1 0
7 0 0 0 1
8 0 0 0 1
9 0 0 1 0
10 1 0 0 0
11 0 1 0 0
12 1 0 0 0
13 0 0 1 0
14 0 0 0 1
15 0 0 0 1
16 0 1 0 0
17 0 0 0 1
18 1 0 0 0
19 0 1 0 0
20 0 0 1 0
21 0 0 0 1
22 1 0 0 0
23 0 1 0 0
24 0 0 1 0
25 0 0 1 0
26 0 0 0 1
27 0 0 0 1
28 0 1 0 0
29 0 0 1 0
30 1 0 0 0
31 0 1 0 0
32 0 1 0 0
33 0 0 1 0
34 0 1 0 0
35 1 0 0 0
36 0 1 0 0
37 0 0 1 0
38 0 0 1 0
39 0 0 1 0
40 1 0 0 0
41 0 0 1 0
42 0 0 1 0
43 0 0 0 1
44 0 0 0 1
45 0 0 1 0
46 0 0 0 1
47 0 0 1 0
48 0 1 0 0
49 0 0 0 1
50 0 0 1 0

Related Solutions

*will someone please explain/show the steps in this process for me? Thank you so much! Amy...
*will someone please explain/show the steps in this process for me? Thank you so much! Amy company produces and sells a toy for $205 per unit. In the first year of operations, 100,000 units were produced and 75,000 were sold. other information for the year includes: direct materials $31 per unit direct manufacturing labor $3 per unit variable manufacturing overhead costs $4 per unit sales selling expenses $4 per unit total fixed manufacturing costs $1,250,000 total fixed administrative expenses $950,000...
Please show the steps to find answers. A) What are expenses if stockholders'equity at the beginning...
Please show the steps to find answers. A) What are expenses if stockholders'equity at the beginning of the period is $ 820, Revenues is $ 12,000, Stockholders' Equity at the end of the period is $ 2,400, Dividends is $ 2,600, and Additional Investments is 38,700? b) V Company purchases merchandise on account for $6,775 from C Company with credit terms of 3/10, n/30, FOB shipping point. C Company directly pays the shipper $351 cash for freight. What is the...
What is the pH of 0.1 M FeSO4 please show all steps
What is the pH of 0.1 M FeSO4 please show all steps
Please show all steps: What is the economic life of an asset that was purchased for...
Please show all steps: What is the economic life of an asset that was purchased for $12,000. O&M costs are $3000 for the first year and increase $1500/yr each year after that. Assume a 7% interest rate.
You construct a price-weighted index of 55 stocks. At the beginning of the day, the index...
You construct a price-weighted index of 55 stocks. At the beginning of the day, the index is 8,710.44. During the day, 54 stock prices remain the same, and 1 stock price increases $5.40. At the end of the day, your index value is 8,757.89. What is the divisor on your index?
PLEASE SHOW CALCULATOR STEPS INCLUDING WHAT YOU INPUT FOR THE TESTS Just before the 2004 Democratic...
PLEASE SHOW CALCULATOR STEPS INCLUDING WHAT YOU INPUT FOR THE TESTS Just before the 2004 Democratic convention, Rasmussen Reports polled 1500 likely voters at random and found that 705 favored John Kerry. Just after the convention, they took another random sample of 1500 likely voters and found that 735 favored Kerry. Did Kerry’s favorability rating increase after the national convention? Use a significance level of a = 0.05. a) Give the name of the hypothesis test that would be appropriate...
Please show steps in the calculation. Please make sure you include checking conditions for using the...
Please show steps in the calculation. Please make sure you include checking conditions for using the CLT. Only Answer Question 3 and 4 The Human Resources (HR) Department of a certain college has asked all employees who were employed in 2018 to fill out a survey in December 2018. Three items on the survey were: “Your dental expense in 2018”, “Are you in a family with at least three other family members?”, and “Your medical expenses in 2018”. The manager...
Please show steps in the calculation. Please make sure you include checking conditions for using the...
Please show steps in the calculation. Please make sure you include checking conditions for using the CLT. The Human Resources (HR) Department of a certain college has asked all employees who were employed in 2018 to fill out a survey in December 2018. Three items on the survey were: “Your dental expense in 2018”, “Are you in a family with at least three other family members?”, and “Your medical expenses in 2018”. The manager of HR has randomly selected a...
Please if you could do each problem, and show steps for excel! Thank you! You will...
Please if you could do each problem, and show steps for excel! Thank you! You will graduate in a few years and start working and it’s never too early to start planning for your retirement and other financial events. Let’s fast forward to the beginning of your career. Here’s some assumptions to help you get started. Your starting annual salary will be $60,000. You plan to work for 43 years before retiring. You expect your salary to grow at an...
*Please show work and explain steps* Assume Y1, ... , Yn are IID continuous variables with...
*Please show work and explain steps* Assume Y1, ... , Yn are IID continuous variables with PDF f(yi; θ), where f is dependent on a parameter θ. Complete the following: a) Derive the likelihood, L(θ), and the log-likelihood, l(θ), in terms of the function f. b) Find dl/d(theta) in terms of f(yi; θ) and df/d(theta). Note that dl/d(θ) is usually referred to as the score function. c) Show that E[dl/d(θ)]= 0. Hint: you can use without proof the following: ∫...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT