2019數(shù)據(jù)與統(tǒng)計分析經(jīng)典原版04olap_第1頁
2019數(shù)據(jù)與統(tǒng)計分析經(jīng)典原版04olap_第2頁
2019數(shù)據(jù)與統(tǒng)計分析經(jīng)典原版04olap_第3頁
2019數(shù)據(jù)與統(tǒng)計分析經(jīng)典原版04olap_第4頁
2019數(shù)據(jù)與統(tǒng)計分析經(jīng)典原版04olap_第5頁
已閱讀5頁,還剩55頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

1、1 1 Data Mining: Concepts and Techniques (3rd ed.) Chapter 4 Jiawei Han, Micheline Kamber, and Jian Pei University of Illinois at Urbana-Champaign week year nSet_grouping hierarchy 1.10 inexpensive 25 Multidimensional Data nSales volume as a function of product, month, and region Product Region Mont

2、h Dimensions: Product, Location, Time Hierarchical summarization paths Industry Region Year Category Country Quarter Product City Month Week Office Day 26 A Sample Data Cube Total annual sales of TVs in U.S.A. Date Product Country sum sum TV VCR PC 1Qtr2Qtr3Qtr 4Qtr U.S.A Canada Mexico sum 27 Cuboid

3、s Corresponding to the Cube all product date country product,dateproduct,countrydate, country product, date, country 0-D (apex) cuboid 1-D cuboids 2-D cuboids 3-D (base) cuboid 28 Typical OLAP Operations nRoll up (drill-up): summarize data nby climbing up hierarchy or by dimension reduction nDrill d

4、own (roll down): reverse of roll-up nfrom higher level summary to lower level summary or detailed data, or introducing new dimensions nSlice and dice: project and select nPivot (rotate): nreorient the cube, visualization, 3D to series of 2D planes nOther operations ndrill across: involving (across)

5、more than one fact table ndrill through: through the bottom level of the cube to its back-end relational tables (using SQL) 29 Fig. 3.10 Typical OLAP Operations 30 A Star-Net Query Model Shipping Method AIR-EXPRESS TRUCK ORDER Customer Orders CONTRACTS Customer Product PRODUCT GROUP PRODUCT LINE PRO

6、DUCT ITEM SALES PERSON DISTRICT DIVISION OrganizationPromotion CITY COUNTRY REGION Location DAILYQTRLYANNUALY Time Each circle is called a footprint 31 Browsing a Data Cube nVisualization nOLAP capabilities nInteractive manipulation 32 Chapter 4: Data Warehousing and On-line Analytical Processing nD

7、ata Warehouse: Basic Concepts nData Warehouse Modeling: Data Cube and OLAP nData Warehouse Design and Usage nData Warehouse Implementation nData Generalization by Attribute-Oriented Induction nSummary 33 Design of Data Warehouse: A Business Analysis Framework nFour views regarding the design of a da

8、ta warehouse nTop-down view nallows selection of the relevant information necessary for the data warehouse nData source view nexposes the information being captured, stored, and managed by operational systems nData warehouse view nconsists of fact tables and dimension tables nBusiness query view nse

9、es the perspectives of data in the warehouse from the view of end-user 34 Data Warehouse Design Process nTop-down, bottom-up approaches or a combination of both nTop-down: Starts with overall design and planning (mature) nBottom-up: Starts with experiments and prototypes (rapid) nFrom software engin

10、eering point of view nWaterfall: structured and systematic analysis at each step before proceeding to the next nSpiral: rapid generation of increasingly functional systems, short turn around time, quick turn around nTypical data warehouse design process nChoose a business process to model, e.g., ord

11、ers, invoices, etc. nChoose the grain (atomic level of data) of the business process nChoose the dimensions that will apply to each fact table record nChoose the measure that will populate each fact table record 35 Data Warehouse Development: A Recommended Approach Define a high-level corporate data

12、 model Data Mart Data Mart Distributed Data Marts Multi-Tier Data Warehouse Enterprise Data Warehouse Model refinementModel refinement 36 Data Warehouse Usage nThree kinds of data warehouse applications nInformation processing nsupports querying, basic statistical analysis, and reporting using cross

13、tabs, tables, charts and graphs nAnalytical processing nmultidimensional analysis of data warehouse data nsupports basic OLAP operations, slice-dice, drilling, pivoting nData mining nknowledge discovery from hidden patterns nsupports associations, constructing analytical models, performing classific

14、ation and prediction, and presenting the mining results using visualization tools 37 From On-Line Analytical Processing (OLAP) to On Line Analytical Mining (OLAM) nWhy online analytical mining? nHigh quality of data in data warehouses nDW contains integrated, consistent, cleaned data nAvailable info

15、rmation processing structure surrounding data warehouses nODBC, OLEDB, Web accessing, service facilities, reporting and OLAP tools nOLAP-based exploratory data analysis nMining with drilling, dicing, pivoting, etc. nOn-line selection of data mining functions nIntegration and swapping of multiple min

16、ing functions, algorithms, and tasks 38 Chapter 4: Data Warehousing and On-line Analytical Processing nData Warehouse: Basic Concepts nData Warehouse Modeling: Data Cube and OLAP nData Warehouse Design and Usage nData Warehouse Implementation nData Generalization by Attribute-Oriented Induction nSum

17、mary 39 Efficient Data Cube Computation nData cube can be viewed as a lattice of cuboids nThe bottom-most cuboid is the base cuboid nThe top-most cuboid (apex) contains only one cell nHow many cuboids in an n-dimensional cube with L levels? nMaterialization of data cube nMaterialize every (cuboid) (

18、full materialization), none (no materialization), or some (partial materialization) nSelection of which cuboids to materialize nBased on size, sharing, access frequency, etc. )1 1 ( n i i LT 40 The “Compute Cube” Operator nCube definition and computation in DMQL define cube sales item, city, year: s

19、um (sales_in_dollars) compute cube sales nTransform it into a SQL-like language (with a new operator cube by, introduced by Gray et al.96) SELECT item, city, year, SUM (amount) FROM SALES CUBE BY item, city, year nNeed compute the following Group-Bys (date, product, customer), (date,product),(date,

20、customer), (product, customer), (date), (product), (customer) () (item)(city) () (year) (city, item)(city, year)(item, year) (city, item, year) 41 Indexing OLAP Data: Bitmap Index nIndex on a particular column nEach value in the column has a bit vector: bit-op is fast nThe length of the bit vector:

21、# of records in the base table nThe i-th bit is set if the i-th row of the base table has the value for the indexed column nnot suitable for high cardinality domains nA recent bit compression technique, Word-Aligned Hybrid (WAH), makes it work for high cardinality domain as well Wu, et al. TODS06 Cu

22、st Region Type C1AsiaRetail C2EuropeDealer C3AsiaDealer C4America Retail C5EuropeDealer RecID Retail Dealer 110 201 301 410 501 RecIDAsia Europe America 1100 2010 3100 4001 5010 Base table Index on RegionIndex on Type 42 Indexing OLAP Data: Join Indices nJoin index: JI(R-id, S-id) where R (R-id, ) S

23、 (S-id, ) nTraditional indices map the values to a list of record ids nIt materializes relational join in JI file and speeds up relational join nIn data warehouses, join index relates the values of the dimensions of a start schema to rows in the fact table. nE.g. fact table: Sales and two dimensions

24、 city and product nA join index on city maintains for each distinct city a list of R-IDs of the tuples recording the Sales in the city nJoin indices can span multiple dimensions 43 Efficient Processing OLAP Queries nDetermine which operations should be performed on the available cuboids nTransform d

25、rill, roll, etc. into corresponding SQL and/or OLAP operations, e.g., dice = selection + projection nDetermine which materialized cuboid(s) should be selected for OLAP op. nLet the query to be processed be on brand, province_or_state with the condition “year = 2004”, and there are 4 materialized cub

26、oids available: 1) year, item_name, city 2) year, brand, country 3) year, brand, province_or_state 4) item_name, province_or_state where year = 2004 Which should be selected to process the query? nExplore indexing structures and compressed vs. dense array structs in MOLAP 44 OLAP Server Architecture

27、s nRelational OLAP (ROLAP) nUse relational or extended-relational DBMS to store and manage warehouse data and OLAP middle ware nInclude optimization of DBMS backend, implementation of aggregation navigation logic, and additional tools and services nGreater scalability nMultidimensional OLAP (MOLAP)

28、nSparse array-based multidimensional storage engine nFast indexing to pre-computed summarized data nHybrid OLAP (HOLAP) (e.g., Microsoft SQLServer) nFlexibility, e.g., low level: relational, high-level: array nSpecialized SQL servers (e.g., Redbricks) nSpecialized support for SQL queries over star/s

29、nowflake schemas 45 Chapter 4: Data Warehousing and On-line Analytical Processing nData Warehouse: Basic Concepts nData Warehouse Modeling: Data Cube and OLAP nData Warehouse Design and Usage nData Warehouse Implementation nData Generalization by Attribute-Oriented Induction nSummary 46 Attribute-Or

30、iented Induction nProposed in 1989 (KDD 89 workshop) nNot confined to categorical data nor particular measures nHow it is done? nCollect the task-relevant data (initial relation) using a relational database query nPerform generalization by attribute removal or attribute generalization nApply aggrega

31、tion by merging identical, generalized tuples and accumulating their respective counts nInteraction with users for knowledge presentation 47 Attribute-Oriented Induction: An Example Example: Describe general characteristics of graduate students in the University database nStep 1. Fetch relevant set

32、of data using an SQL statement, e.g., Select * (i.e., name, gender, major, birth_place, birth_date, residence, phone#, gpa) from student where student_status in “Msc”, “MBA”, “PhD” nStep 2. Perform attribute-oriented induction nStep 3. Present results in generalized relation, cross-tab, or rule form

33、s 48 Class Characterization: An Example NameGenderMajorBirth-PlaceBirth_dateResidencePhone #GPA Jim Woodman M CSVancouver,BC, Canada 8-12-763511 Main St., Richmond 687-45983.67 Scott Lachance M CSMontreal, Que, Canada 28-7-75345 1st Ave., Richmond 253-91063.70 Laura Lee F Physics Seattle, WA, USA 25

34、-8-70 125 Austin Ave., Burnaby 420-5232 3.83 RemovedRetainedSci,Eng, Bus CountryAge rangeCityRemovedExcl, VG,. GenderMajorBirth_regionAge_rangeResidenceGPACount MScience Canada 20-25RichmondVery-good 16 FScience Foreign 25-30BurnabyExcellent 22 Birth_Region Gender CanadaForeignTotal M 16 14 30 F 10

35、22 32 Total 26 36 62 Prime Generalized Relation Initial Relation 49 Basic Principles of Attribute-Oriented Induction nData focusing: task-relevant data, including dimensions, and the result is the initial relation nAttribute-removal: remove attribute A if there is a large set of distinct values for

36、A but (1) there is no generalization operator on A, or (2) As higher level concepts are expressed in terms of other attributes nAttribute-generalization: If there is a large set of distinct values for A, and there exists a set of generalization operators on A, then select an operator and generalize

37、A nAttribute-threshold control: typical 2-8, specified/default nGeneralized relation threshold control: control the final relation/rule size 50 Attribute-Oriented Induction: Basic Algorithm nInitialRel: Query processing of task-relevant data, deriving the initial relation. nPreGen: Based on the anal

38、ysis of the number of distinct values in each attribute, determine generalization plan for each attribute: removal? or how high to generalize? nPrimeGen: Based on the PreGen plan, perform generalization to the right level to derive a “prime generalized relation”, accumulating the counts. nPresentati

39、on: User interaction: (1) adjust levels by drilling, (2) pivoting, (3) mapping into rules, cross tabs, visualization presentations. 51 Presentation of Generalized Results nGeneralized relation: nRelations where some or all attributes are generalized, with counts or other aggregation values accumulat

40、ed. nCross tabulation: nMapping results into cross tabulation form (similar to contingency tables). nVisualization techniques: nPie charts, bar charts, curves, cubes, and other visual forms. nQuantitative characteristic rules: nMapping generalized result into characteristic rules with quantitative i

41、nformation associated with it, e.g., .%47: )(_%53: )(_ )()( tforeignxregionbirthtCanadaxregionbirth xmalexgrad 52 Mining Class Comparisons nComparison: Comparing two or more classes nMethod: nPartition the set of relevant data into the target class and the contrasting class(es) nGeneralize both clas

42、ses to the same high level concepts nCompare tuples with the same high level descriptions nPresent for every tuple its description and two measures nsupport - distribution within single class ncomparison - distribution between classes nHighlight the tuples with strong discriminant features nRelevanc

43、e Analysis: nFind attributes (features) which best distinguish different classes 53 Concept Description vs. Cube-Based OLAP nSimilarity: nData generalization nPresentation of data summarization at multiple levels of abstraction nInteractive drilling, pivoting, slicing and dicing nDifferences: nOLAP

44、has systematic preprocessing, query independent, and can drill down to rather low level nAOI has automated desired level allocation, and may perform dimension relevance analysis/ranking when there are many relevant dimensions nAOI works on the data which are not in relational forms 54 Chapter 4: Dat

45、a Warehousing and On-line Analytical Processing nData Warehouse: Basic Concepts nData Warehouse Modeling: Data Cube and OLAP nData Warehouse Design and Usage nData Warehouse Implementation nData Generalization by Attribute-Oriented Induction nSummary 55 Summary nData warehousing: A multi-dimensional

46、 model of a data warehouse nA data cube consists of dimensions & measures nStar schema, snowflake schema, fact constellations nOLAP operations: drilling, rolling, slicing, dicing and pivoting nData Warehouse Architecture, Design, and Usage nMulti-tiered architecture nBusiness analysis design framewo

47、rk nInformation processing, analytical processing, data mining, OLAM (Online Analytical Mining) nImplementation: Efficient computation of data cubes nPartial vs. full vs. no materialization nIndexing OALP data: Bitmap index and join index nOLAP query processing nOLAP servers: ROLAP, MOLAP, HOLAP nDa

48、ta generalization: Attribute-oriented induction 56 References (I) nS. Agarwal, R. Agrawal, P. M. Deshpande, A. Gupta, J. F. Naughton, R. Ramakrishnan, and S. Sarawagi. On the computation of multidimensional aggregates. VLDB96 nD. Agrawal, A. E. Abbadi, A. Singh, and T. Yurek. Efficient view maintena

49、nce in data warehouses. SIGMOD97 nR. Agrawal, A. Gupta, and S. Sarawagi. Modeling multidimensional databases. ICDE97 nS. Chaudhuri and U. Dayal. An overview of data warehousing and OLAP technology. ACM SIGMOD Record, 26:65-74, 1997 nE. F. Codd, S. B. Codd, and C. T. Salley. Beyond decision support.

50、Computer World, 27, July 1993. nJ. Gray, et al. Data cube: A relational aggregation operator generalizing group-by, cross-tab and sub-totals. Data Mining and Knowledge Discovery, 1:29-54, 1997. nA. Gupta and I. S. Mumick. Materialized Views: Techniques, Implementations, and Applications. MIT Press,

51、1999. nJ. Han. Towards on-line analytical mining in large databases. ACM SIGMOD Record, 27:97-107, 1998. nV. Harinarayan, A. Rajaraman, and J. D. Ullman. Implementing data cubes efficiently. SIGMOD96 57 References (II) nC. Imhoff, N. Galemmo, and J. G. Geiger. Mastering Data Warehouse Design: Relati

52、onal and Dimensional Techniques. John Wiley, 2003 nW. H. Inmon. Building the Data Warehouse. John Wiley, 1996 nR. Kimball and M. Ross. The Data Warehouse Toolkit: The Complete Guide to Dimensional Modeling. 2ed. John Wiley, 2002 nP. ONeil and D. Quass. Improved query performance with variant indexes

53、. SIGMOD97 nMicrosoft. OLEDB for OLAP programmers reference version 1.0. In http:/ 1998 nA. Shoshani. OLAP and statistical databases: Similarities and differences. PODS00. nS. Sarawagi and M. Stonebraker. Efficient organization of large multidimensional arrays. ICDE94 nP. Valduriez. Join indices. AC

54、M Trans. Database Systems, 12:218-246, 1987. nJ. Widom. Research problems in data warehousing. CIKM95. nK. Wu, E. Otoo, and A. Shoshani, Optimal Bitmap Indices with Efficient Compression, ACM Trans. on Database Systems (TODS), 31(1), 2006, pp. 1-38. July 29, 2021Data Mining: Concepts and Techniques58 59 Chapter 4: Data Warehousing and On-line Analytical Processing nData Warehouse: Basic Concepts n(a) What Is a Data Warehouse? n(b) Data Warehouse: A Multi-Tiered Architecture n(c) Three Data Warehouse Models: Enterprise Wa

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論