Dwdm File

download Dwdm File

of 36

Transcript of Dwdm File

  • 7/27/2019 Dwdm File

    1/36

  • 7/27/2019 Dwdm File

    2/36

  • 7/27/2019 Dwdm File

    3/36

    PRACTICAL No. 02

    AIM:What are relations? How can you create in any RDBMS?Ans: The case in which data in one table is related to the data inanother table. This connection between two tables is called a relation.

    We can create relations in any RDB MS such that when there is such arelation between two tables, these tables will be connected by insertingthe Primary Key of one table into the corresponding row of the othertable. The field such a way to connect the two tables is known as

    Foreign Key.

    These relations exists as follows: One-to-one One-to-many Many-to-one Many-t- many

    a) Write a query for table creation in any DBMS and create a tableaccordingly having minimum seven fields and 10 records.

    Query:

    CREATE TABLE STUDENT_INFO(First_Name nvarchar(25) Not Null,Middle_Name nvarchar(10),Last_Name nvarchar(25),Enrollment_No numeric(18,0) not null,Gender char(1) not null,Date_of_Birth nchar(15) not null,Mobile numeric(20),Address nvarchar(50));

    Prerana Tokas MCA-II | 02016204411 3

  • 7/27/2019 Dwdm File

    4/36

    b) Insert data in the above created table.

    Query:

    INSERT INTO STUDENT_INFO VALUES('Shweta','U','Singh',00416204411,,F,'16-April-1991',9711512707,'Subroto Park');

    INSERT INTO STUDENT_INFO VALUES('Prerana','A','Tokas',00516204411,,F,'04-Feb-1991',9711512787,'Munirka');

    INSERT INTO STUDENT_INFO VALUES('Jyoti','P','Yadav',00716204411,,F,'21-Nov-1994',8654512707,'Subroto Park');

    c) Retrieve the data stored in the table on various criteria.

    Query:

    i. Select * from STUDENT_INFO;

    ii. Select Count(*) as 'Total Records in the table' fromSTUDENT_INFO;

    iii. Select * from STUDENT_INFO WHEREEnrollment_No='00416204411';

    iv. Select First_Name, Moblie_No from STUDENT_INFOWHERE Address='Subroto Park';

    d) Create any appropriate view based on that table.

    Query:

    CREATE VIEW STUDENT_VIEW ASSELECT First_Name, Enrollment_NoFROM STUDENT_INFOWHERE Gender='F';

    Prerana Tokas MCA-II | 02016204411 4

  • 7/27/2019 Dwdm File

    5/36

    MS-Excel

    Prerana Tokas MCA-II | 02016204411 5

  • 7/27/2019 Dwdm File

    6/36

    PRACTICAL No. 03

    Create a pivot table of OLAP technology using MS-Excel.

    Open->MS ExcelGo to Data Import Database Select ColumnsInsert Pivot table

    Prerana Tokas MCA-II | 02016204411 6

  • 7/27/2019 Dwdm File

    7/36

    PRACTICAL No. 04

    Demonstrate Slice-and-Dice concept of OLAP technology.

    Open->MS ExcelGo to Data Import Database Select ColumnsInsert Pivot table

    Prerana Tokas MCA-II | 02016204411 7

  • 7/27/2019 Dwdm File

    8/36

    PRACTICAL No. 05

    Demonstrate Drill-down and Roll-up concept of OLAP technologyusing MS-Excel.

    Drill Down:

    Prerana Tokas MCA-II | 02016204411 8

  • 7/27/2019 Dwdm File

    9/36

    Rollup

    Prerana Tokas MCA-II | 02016204411 9

  • 7/27/2019 Dwdm File

    10/36

    PRACTICAL No. 06

    Demonstrate rotation concept of OLAP technology using pivot table in

    MS-Excel.

    Prerana Tokas MCA-II | 02016204411 10

  • 7/27/2019 Dwdm File

    11/36

    PRACTICAL No. 07

    Demonstrate scenario manager in MS-Excel.

    Select a data fieldGo to Data menu Click What-if Analysis Open Scenario Manager Make changes in the data field using Scenario Manager and displaysummary.

    Values of the data field after change.

    Prerana Tokas MCA-II | 02016204411 11

  • 7/27/2019 Dwdm File

    12/36

    Scenario Summary:

    Prerana Tokas MCA-II | 02016204411 12

  • 7/27/2019 Dwdm File

    13/36

    PRACTICAL No. 08

    Demonstrate goal seek in MS-Excel.

    Select a cell Create a formulaGo to Data menu Click What-if Analysis Open Goal Seeker Observe the goals that are achieved after using Goal Seeker

    Sheet with formula:

    Prerana Tokas MCA-II | 02016204411 13

  • 7/27/2019 Dwdm File

    14/36

    Goal achieved by Goal-Seeker

    Prerana Tokas MCA-II | 02016204411 14

  • 7/27/2019 Dwdm File

    15/36

    WEKA 3.6

    Prerana Tokas MCA-II | 02016204411 15

  • 7/27/2019 Dwdm File

    16/36

    PRACTICAL No. 09

    We are going to work with the Data provided in Weka. We are going to work withAgrawal database.

    Prerana Tokas MCA-II | 02016204411 16

  • 7/27/2019 Dwdm File

    17/36

    Perform classification task of data mining using Weka Explorer.

    Choose ClassifySelect classifier as Decision Table and start generating the classifications as per age:

    The screenshot is shown below:

    Prerana Tokas MCA-II | 02016204411 17

  • 7/27/2019 Dwdm File

    18/36

    Prerana Tokas MCA-II | 02016204411 18

  • 7/27/2019 Dwdm File

    19/36

    PRACTICAL No. 10

    Perform clustering task of data mining using Weka Explorer.

    Choose-> Cluster Choose Clusterer as HierarchicalClustererSelect Classes to cluster evaluation as groups

    Prerana Tokas MCA-II | 02016204411 19

  • 7/27/2019 Dwdm File

    20/36

    PRACTICAL No. 11

    Perform Association task of data mining using Weka Explorer.

    Choose AssociateSelect Associator as FilteredAssociator

    Prerana Tokas MCA-II | 02016204411 20

  • 7/27/2019 Dwdm File

    21/36

    PRACTICAL No. 12

    Perform classification task of data mining using Weka Knowledge Flow.

    Open KnowledgeFlow Load DataSourceConnect various componentsStart loading

    Prerana Tokas MCA-II | 02016204411 21

  • 7/27/2019 Dwdm File

    22/36

    Classification result using Decision Tree:

    PRACTICAL No. 13

    Prerana Tokas MCA-II | 02016204411 22

  • 7/27/2019 Dwdm File

    23/36

  • 7/27/2019 Dwdm File

    24/36

    Perform Association task of data mining using Weka Knowledge Flow.

    Prerana Tokas MCA-II | 02016204411 24

  • 7/27/2019 Dwdm File

    25/36

    MATLAB

    PRACTICAL No. 15

    Prerana Tokas MCA-II | 02016204411 25

  • 7/27/2019 Dwdm File

    26/36

    Show the computation of A*b, a+b, b-5, A*a'

    A*b:

    a+b

    Prerana Tokas MCA-II | 02016204411 26

  • 7/27/2019 Dwdm File

    27/36

  • 7/27/2019 Dwdm File

    28/36

    PRACTICAL No. 16

    Prerana Tokas MCA-II | 02016204411 28

  • 7/27/2019 Dwdm File

    29/36

    Create a MATLAB program to display the table of the num entered bythe user.

    PRACTICAL No. 17

    Prerana Tokas MCA-II | 02016204411 29

  • 7/27/2019 Dwdm File

    30/36

    Create a MATLAB program to display the factorial of the numentered by the user.

    PRACTICAL No. 18

    Prerana Tokas MCA-II | 02016204411 30

  • 7/27/2019 Dwdm File

    31/36

    Create a MATLAB program to display the odd num within limitentered by the user.

    PRACTICAL No. 19

    Prerana Tokas MCA-II | 02016204411 31

  • 7/27/2019 Dwdm File

    32/36

    Create a graph using MATLAB built in functions.

    plot:

    Prerana Tokas MCA-II | 02016204411 32

  • 7/27/2019 Dwdm File

    33/36

    ezplot:

    fplot with grid:

    Prerana Tokas MCA-II | 02016204411 33

  • 7/27/2019 Dwdm File

    34/36

    PRACTICAL No. 20

    Perform classification in MATLAB.

    Prerana Tokas MCA-II | 02016204411 34

  • 7/27/2019 Dwdm File

    35/36

    Classification

    Suppose we have a data set containing observations with measurements on differentvariables (called predictors) and their known class labels. If we obtain predictor valuesfor new observations, could we determine to which classes those observations probably

    belong? This is the problem of classification. This illustrates how to perform someclassification algorithms in MATLAB by applying them to Fisher's iris data.

    Contents:

    Fisher's Iris Data Linear and Quadratic Discriminant Analysis NaiveBayes Classifier Decision Tree

    Code:load fisheririsgscatter(meas(:,1), meas(:,2), species,'rgb','osd');xlabel('Sepal length');ylabel('Sepal width');

    N = size(meas,1);

    PRACTICAL No. 21

    Perform clustering in MATLAB.

    Prerana Tokas MCA-II | 02016204411 35

    http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#1http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#3http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#15http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#19http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#3http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#15http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#19http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/classdemo.html#1
  • 7/27/2019 Dwdm File

    36/36

    Cluster Analysis

    Cluster analysis is a way to examine similarities and dissimilarities of observations or objects. Data often fall naturally into groups, or clusters, of observations, where thecharacteristics of objects in the same cluster are similar and the characteristics of objectsin different clusters are dissimilar.

    Contents:

    K-Means and Hierarchical Clustering Fisher's Iris Data Clustering Fisher's Iris Data Using K-Means Clustering Clustering Fisher's Iris Data Using Hierarchical Clustering

    Code:load fisheriris[cidx2,cmeans2] = kmeans(meas,2,'dist','sqeuclidean');[silh2,h] = silhouette(meas,cidx2,'sqeuclidean');

    http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#1http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#3http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#4http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#17http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#1http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#3http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#4http://www.mathworks.in/products/statistics/examples.html?file=/products/demos/shipping/stats/clusterdemo.html#17