{"id":156,"date":"2018-03-04T14:47:00","date_gmt":"2018-03-04T13:47:00","guid":{"rendered":"https:\/\/kindsonthegenius.com\/blog\/2018\/03\/04\/hypothesis-testing-problem-quesion-7-test-wether-cars-get-better-mileage\/"},"modified":"2020-11-05T13:46:01","modified_gmt":"2020-11-05T12:46:01","slug":"hypothesis-testing-problem-quesion-7-test-wether-cars-get-better-mileage","status":"publish","type":"post","link":"https:\/\/kindsonthegenius.com\/blog\/hypothesis-testing-problem-quesion-7-test-wether-cars-get-better-mileage\/","title":{"rendered":"Hypothesis Testing Problem &#8211; Quesion 7 (Test wether cars get better mileage&#8230;)"},"content":{"rendered":"<p><span style=\"color: #990000;\"><span style=\"font-size: large;\"><b>Question 7<\/b><\/span><\/span><br \/>\nA study was performed to test wether cars get better mileage on premium gas than on regular gas. Each of 10 cars was first filled with regular or premium gas, decided by a coin toss, and the mileage for the tank was recorded. The mileage was recorded again for the same cars using other kind of gasoline.<br \/>\nDetermine wether cars get significantly better mileage with premium gas.<\/p>\n<p>Mileage with regular gas: 16,20,21,22,23,22,27,25,27,28<br \/>\nMileage with premium gas: 19, 22,24,24,25,25,26,26,28,32<\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"https:\/\/youtu.be\/mUXIZHUSQXg\" target=\"_blank\" rel=\"noopener noreferrer\">Click here to watch to see how to transfer this data to excel (using transpose) without typing them.<\/a><\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #274e13;\"><span style=\"font-size: large;\"><b>Solution Steps<\/b><\/span><\/span><br \/>\nSo let&#8217;s go through the steps again to solve this problem<\/p>\n<p>Step 1: Set up your null and alternate hypothesis<br \/>\n<b>H<sub>0<\/sub>:<\/b> \u03bc<sub>2<\/sub> = \u03bc<sub>1<\/sub><br \/>\n<b>H<sub>a<\/sub><\/b>: \u03bc<sub>2<\/sub> \u2260 \u03bc<sub>1<\/sub><\/p>\n<p>&nbsp;<\/p>\n<p><b>Step 2: Create the table to calculate difference<\/b><br \/>\nIf you have entered the data and the formula correctly, you will have the table below<\/p>\n<p>&nbsp;<\/p>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/2.bp.blogspot.com\/-O47jaqWpdc8\/Wpv8uXVnj2I\/AAAAAAAABCQ\/i_68jp5c1QgS1Dcr-uw56ScEaxnoWuXPgCLcBGAs\/s1600\/Mileage%2Btable%2Bfor%2Bt-test.jpg\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/2.bp.blogspot.com\/-O47jaqWpdc8\/Wpv8uXVnj2I\/AAAAAAAABCQ\/i_68jp5c1QgS1Dcr-uw56ScEaxnoWuXPgCLcBGAs\/s320\/Mileage%2Btable%2Bfor%2Bt-test.jpg\" width=\"320\" height=\"277\" border=\"0\" data-original-height=\"498\" data-original-width=\"573\" \/><\/a><\/div>\n<p>Notice that in the table, there is mean and and standard deviation.<\/p>\n<p><a href=\"https:\/\/youtu.be\/mUXIZHUSQXg\" target=\"_blank\" rel=\"noopener noreferrer\">Watch the video to learn how to do this in excel<\/a><br \/>\nThe symbol like a D in the table is actually a D with a bar on top.<\/p>\n<p>&nbsp;<\/p>\n<p><b>Step 3: Calculate the mean of the difference from the table<\/b><br \/>\nFrom the table the mean difference is 2<\/p>\n<p>&nbsp;<\/p>\n<p><b>Step 4: Calculate the standard deviation of the differences<\/b><br \/>\nThis can be gotten using excel very easily. But in this example, we calculate it using the formular and we can see that it corresponds to the one in the excel sheet.<\/p>\n<p>Using the formular<\/p>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/2.bp.blogspot.com\/-0uxH9TedxYM\/Wpv_uhKgMRI\/AAAAAAAABCc\/swRRcwLBUTYMr5A4lDLXZg5JiKcBndE_wCLcBGAs\/s1600\/Standard-deviation-formular%2Bfor%2Bpaired%2Bsample.jpg\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/2.bp.blogspot.com\/-0uxH9TedxYM\/Wpv_uhKgMRI\/AAAAAAAABCc\/swRRcwLBUTYMr5A4lDLXZg5JiKcBndE_wCLcBGAs\/s200\/Standard-deviation-formular%2Bfor%2Bpaired%2Bsample.jpg\" width=\"200\" height=\"52\" border=\"0\" data-original-height=\"113\" data-original-width=\"430\" \/><\/a><\/div>\n<p>&nbsp;<\/p>\n<p>We have the<\/p>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/1.bp.blogspot.com\/-b1FlNTG8Fow\/WpwA7EdjwQI\/AAAAAAAABCo\/xZKF0be9YNYz35T0UXnqbVJmoOXUVRz2gCLcBGAs\/s1600\/Calculating%2BStandard%2BDeviation.jpg\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/1.bp.blogspot.com\/-b1FlNTG8Fow\/WpwA7EdjwQI\/AAAAAAAABCo\/xZKF0be9YNYz35T0UXnqbVJmoOXUVRz2gCLcBGAs\/s320\/Calculating%2BStandard%2BDeviation.jpg\" width=\"233\" height=\"320\" border=\"0\" data-original-height=\"366\" data-original-width=\"269\" \/><\/a><\/div>\n<p>&nbsp;<\/p>\n<p><b>Step 5: Calculate the Standard Error<\/b><br \/>\nYou can calculate the standard error using the formular<\/p>\n<p>&nbsp;<\/p>\n<div style=\"clear: both; text-align: center;\"><\/div>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/2.bp.blogspot.com\/-caxV6Q9nXJ0\/WpwD2L9zU3I\/AAAAAAAABDI\/eRP9KwWF6bQ5tzQvQSPAai8hHmizxzAhwCLcBGAs\/s1600\/Calculating%2BStandard%2BError.jpg\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/2.bp.blogspot.com\/-caxV6Q9nXJ0\/WpwD2L9zU3I\/AAAAAAAABDI\/eRP9KwWF6bQ5tzQvQSPAai8hHmizxzAhwCLcBGAs\/s320\/Calculating%2BStandard%2BError.jpg\" width=\"244\" height=\"320\" border=\"0\" data-original-height=\"406\" data-original-width=\"311\" \/><\/a><\/div>\n<p>&nbsp;<\/p>\n<p><b>Step 6: Calculate the t statistic<\/b><br \/>\nWe calculate t statistic using the formular<\/p>\n<p>&nbsp;<\/p>\n<div style=\"clear: both; text-align: center;\"><a style=\"margin-left: 1em; margin-right: 1em;\" href=\"https:\/\/3.bp.blogspot.com\/-GxuqzOqfYCg\/WpwEmKGPh9I\/AAAAAAAABDQ\/5Nbni9CWXjYNat-VZue18Stcvqe3gWSJwCLcBGAs\/s1600\/Calculating%2Bt-%2BStatistic.jpg\"><img decoding=\"async\" loading=\"lazy\" src=\"https:\/\/3.bp.blogspot.com\/-GxuqzOqfYCg\/WpwEmKGPh9I\/AAAAAAAABDQ\/5Nbni9CWXjYNat-VZue18Stcvqe3gWSJwCLcBGAs\/s200\/Calculating%2Bt-%2BStatistic.jpg\" width=\"200\" height=\"112\" border=\"0\" data-original-height=\"180\" data-original-width=\"320\" \/><\/a><\/div>\n<p>&nbsp;<\/p>\n<p><b>Step 7: Look up the t statistic from the table of t-distribution<\/b><br \/>\n<a href=\"https:\/\/kindsonthegenius.com\/blog\/statistical-tables\/\" target=\"_blank\" rel=\"noopener noreferrer\">Get a statistical table from here.<\/a><br \/>\nFrom the table of t-distribution we find t usind (n-1) = 9 degrees of freedom and 0.05 significance<br \/>\nThat gives us 2.262.<\/p>\n<p>&nbsp;<\/p>\n<p><b>Step 8: Conpare tabulated value and calculated value and draw conclusion<\/b><br \/>\nWe see that the calculated value of t is greater than the critical value of t. This means that there is significant difference in the means of the two samples. Therefore we reject the null hypothesis that states that the two means are equal.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Question 7 A study was performed to test wether cars get better mileage on premium gas than on regular gas. Each of 10 cars was &hellip; <\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0},"categories":[223],"tags":[544],"_links":{"self":[{"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/posts\/156"}],"collection":[{"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/comments?post=156"}],"version-history":[{"count":3,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/posts\/156\/revisions"}],"predecessor-version":[{"id":1705,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/posts\/156\/revisions\/1705"}],"wp:attachment":[{"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/media?parent=156"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/categories?post=156"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kindsonthegenius.com\/blog\/wp-json\/wp\/v2\/tags?post=156"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}