Presentation is loading. Please wait.

Presentation is loading. Please wait.

Confidential1 Tree Diagrams. Confidential2 Warm Up Find the lower and upper quartiles of the following data sets 1.23, 25, 27, 29, 31, 33, 35 2. 49, 51,

Similar presentations


Presentation on theme: "Confidential1 Tree Diagrams. Confidential2 Warm Up Find the lower and upper quartiles of the following data sets 1.23, 25, 27, 29, 31, 33, 35 2. 49, 51,"— Presentation transcript:

1 Confidential1 Tree Diagrams

2 Confidential2 Warm Up Find the lower and upper quartiles of the following data sets 1.23, 25, 27, 29, 31, 33, 35 2. 49, 51, 53, 55, 57, 59, 61 Find the mean, median and mode for the data sets 3. 3000, 3100, 300, 3000, 3300 4. 3.8, 4.2, 4.0, 4.2, 4.2

3 Confidential3 Warm Up Make a back-to-back stem-and-leaf plot to compare the birth dates of Mrs. Jenson’s students. Boys- 22, 18, 9, 3, 5, 28, 11 Girls- 9, 3, 8, 27, 15, 6, 31 5.

4 Confidential4 1. In the raw data, there can be repetitions of observations. The number of times a particular observation repeats itself is called its frequency. 2. When the number of observation is limited, Tally Marks are used to find the frequencies. Tallies are usually marked in bunches of five for ease in Counting 3. When the number of observations is very large, the data is usually organized into groups called class intervals and the data obtained is called the grouped data. 4. A Stem and Leaf Plot is a type of graph that summarizes the shape of a set of data (the distribution) and provides extra detail regarding individual values. Lets recap our last lesson

5 Confidential5 1.Graphs are pictorial representation for a set of data ranges. 2.Graphs can be of different types - Line graph and Bar graph 3. Data Representation on the Graph is Labels Mean - The average of a group of numbers is called the mean Median- It is the number present in the middle when the numbers in a set of data are arranged in ascending or descending order Mode-The number that appears the most often in a listing of number

6 Confidential6  A box and whisker plot is used to display a set of data.  To create this plot we first find out median, first quartile and second quartile.  Plot the given data set on a number line.  Mark the highest and lowest data points with connected black circles and make a box between the quartiles and a line through the median. Box-and-whisker plots and Circle Graphs

7 Confidential7 1) Sampling is the art of learning about a very large group of people by getting information from a small set of people. 2) Population is the entire set of individuals, events, units with specified characteristics. 3) Parameter is a summary description of a particular aspect of the entire population. 4) Sample is the subset of the population from which data is collected and used as a basis for making statements about the entire population.

8 Confidential8 Nodes A node may contain a value or a condition or represents a separate data structure or a tree of its own. Each node in a tree has zero or more child nodes, which are below it in the tree Let us start We use Tree diagrams to count the possible outcomes of any problem of probability, as well as analyze games of choice.

9 Confidential9 More on Nodes A node that has a child is called the child's Parent node (or ancestor node, or superior). A node has at most one parent. The height of a node is the length of the longest downward path to a leaf from that node. The height of the root is the height of the tree. The depth of a node is the length of the path to its root.

10 Confidential10 Root nodes The topmost node in a tree is called the root node. Being the topmost node, the root node will not have parents. It is the node at which operations on the tree commonly begin. Every node in a tree can be seen as the root node of the sub-tree rooted at that node.

11 Confidential11 Leaf nodes Nodes at the bottommost level of the tree are called leaf nodes. Since they are at the bottommost level, they do not have any children.

12 Confidential12 Internal nodes An internal node or inner node is any node of a tree that has child nodes and is thus not a leaf node

13 Confidential13 Sub tree A Sub tree is a portion of a tree data structure that can be viewed as a complete tree in itself. Any node in a tree T, together with all the nodes below it, comprise a Sub tree of T.

14 Confidential14 More on Sub Tree The Sub tree corresponding to the root node is the entire tree. The Sub tree corresponding to any other node is called a Proper Sub tree

15 Confidential15 Tree ordering There are two basic types of trees.  Unordered Tree  Ordered Tree

16 Confidential16 Unordered Tree  In an unordered tree, a tree is a tree in a purely structural sense —  that is to say, given a node, there is no order for the children of that node.

17 Confidential17 Ordered Tree A tree on which an order is imposed — ordered Tree. for example, by assigning different natural numbers to each edge leading to a node's children — is called an edge-labeled tree or an ordered tree.

18 Confidential18 Forest A Forest is an ordered set of ordered trees. In order, preorder and post order traversals are defined recursively for forest

19 Confidential19 Let us Study Traversal of Trees  In order  Preorder  Post order

20 Confidential20 In order Traverse in-order the forest formed by the sub-trees of the first tree in the forest, if any. Visit the root of the first tree. Traverse in-order the forest formed by the remaining trees in the forest, if any.

21 Confidential21 Preorder Visit the root of the first tree. Traverse preorder the forest formed by the sub trees of the first tree in the forest, if any. Traverse preorder the forest formed by the remaining trees in the forest, if any.

22 Confidential22 Post order Traverse post order the forest formed by the sub trees of the first tree in the forest, if any. Traverse post order the forest formed by the remaining trees in the forest, if any. Visit the root of the first tree.

23 Confidential23 Tree representations Common representations represent the nodes as records allocated on the heap with pointers to their children, their parents, or both, or as items in an array, with relationships between them determined by their positions in the array (e.g., binary heap).

24 Confidential24 Trees as graphs In graph theory, a tree is a connected acyclic graph. A rooted tree is such a graph with a vertex singled out as the root. In this case, any two vertices connected by an edge inherit a parent-child relationship. An acyclic graph with multiple connected components or a set of rooted trees is sometimes called a forest.

25 Confidential25 Traversal methods Stepping through the items of a tree, by means of the connections between parents and children, is called walking the tree, and the action is a walk of the tree. Often, an operation might be performed when a pointer arrives at a particular node.

26 Confidential26 Preorder And Post order Walk A walk in which each parent node is traversed before its children is called a pre-order walk; A walk in which the children are traversed before their respective parents are traversed is called a post- order walk.

27 Confidential27 Common operations Enumerating all the items Searching for an item Adding a new item at a certain position on the tree Deleting an item Removing a whole section of a tree (called pruning) Adding a whole section to a tree (called grafting) Finding the root for any node

28 Confidential28 A family has three children. How many outcomes are in the sample space that indicates the sex of the children? Assume that the probability of male (M) and the probability of female (F) are each 1/2. Sample space: { MMF MFM MFF FMM FMF FFMFFF MMM } There are 8 outcomes in the sample space. The probability of each outcome is 1/2 1/2 1/2 = 1/8. Example

29 Confidential29 Tree diagram

30 Confidential30 1.Draw tree structure for Alphabets from A to I Assessment

31 Confidential31 2. Implement sub tree for tree. 3. Mention the tree is ordered or not.

32 Confidential32 4. Mention preorder traversal. 5. Mention post order traversal. 6. Mention in order traversal.

33 Confidential33 7.Find leaf nodes 8.Find the preorder walk of the tree

34 Confidential34 9. Find post order walk of the tree. 10 Mention level order sequencing

35 Confidential35 1. Make a tree diagram and list the outcomes. 1 2 3 A B C Spinning the spinner and choosing a card

36 Confidential36 2. Show the sample space for tossing one penny and rolling one die. (H = heads, T = tails)

37 Confidential37 3. Draw A tree Structure in implementing the hierarchy of developing triangle hint : figure…polygon…triangle …… types of triangle

38 Confidential38 Lets recap what we have learned in this lesson There are two basic types of trees. Unordered Tree Ordered Tree In an unordered tree, a tree is a tree in a purely structural sense A tree on which an order is imposed — ordered Tree A node may contain a value or a condition or represents a separate data structure or a tree of its own. Each node in a tree has zero or more child nodes, which are below it in the tree

39 Confidential39 A Sub tree is a portion of a tree data structure that can be viewed as a complete tree in itself A Forest is an ordered set of ordered trees Traversal of Trees In order Preorder Post order In graph theory, a tree is a connected acyclic graph.

40 Confidential40 Preorder And Post order Walk A walk in which each parent node is traversed before its children is called a pre-order walk; A walk in which the children are traversed before their respective parents are traversed is called a post-order walk.

41 Confidential41


Download ppt "Confidential1 Tree Diagrams. Confidential2 Warm Up Find the lower and upper quartiles of the following data sets 1.23, 25, 27, 29, 31, 33, 35 2. 49, 51,"

Similar presentations


Ads by Google