Page 265 - AI Computer 10
P. 265

Descriptive Statistics

        Descriptive Statistics is a branch of statistics that aims to summarise and organise data in such a way that it
        provides a clear overview of its main characteristics. This fundamental aspect of data analysis allows researchers
        and analysts to understand the underlying patterns within the data without making predictions or inferences
        about the population from which the data was drawn.
        Statistical measurers such as Mean, Median, Mode, Standard Deviation, and Variance, are generally used to
        analyse data. Let us learn more about these terms in detail.
         u Mean: The mean is the average or the most common value in a collection of numbers. It is denoted by x bar
             (x). You should remember that all data is given equal importance in mean. We can use the following formula
             to calculate the mean of the given values:





             where:

             •  x =  mean
               x
             •     =  individual values
                i
                n
             •     =  total number of elements
        To calculate mean in Python:
              import statistics
              num = [10,20,30,40,50,60,70,80]
              m = statistics.mean(num)
              print(“The mean value is:”,round(m,2))

              Output:
              The mean value is: 45
         u Median: The median is the middle value in the set of given numbers. In order to calculate the median, the
             data must first be ranked (sorted in ascending order). We can use the following formula to calculate the
             median:









                                                                                                             131
                                                                                                             131
   260   261   262   263   264   265   266   267   268   269   270