 We are now going to introduce couple of definitions. Suppose some alpha is given to you which is between 0, 1. Now, a test with power function B of theta, we are going to be call it as a size alpha test, if its maximum value over my null hypothesis is alpha. You understand what I am talking about. So, what is this? When I look beta of theta over theta which is coming from null hypothesis this is going to give me what? Type 1 error. So, basically when I say a test is size alpha test that means, it is type 1 error, maximum value of type 1 error is alpha ok. A little generalization of this definition is suppose I have alpha between 0, 1 and I have a test with power function beta of theta, I am going to call this test level alpha test if its maximum value over my null hypothesis is less than or equals to alpha ok. Basically I am saying that type 1 error has to be less than or equals to alpha. Now, if I give you a test which is level alpha is it also size alpha? Yes, we do not know right like when I say level alpha it is less than or equals to alpha. It is not exactly alpha, but on the other way if I give a test which is size alpha will it be level alpha test that is true right ok. Now, here because these are related to the type 1 errors by fixing my alpha I am only controlling type 1 errors in this definitions for the test ok. There is nothing I am talking about type 2 errors in this definitions. Is the definition of size and level of a test clear to you? Now, I am going to talk about one more test. We talked about unbiased estimators. Now, let us talk about unbiased test. We are going to say that a test with power function B of theta is unbiased ok. So, to understand this let us talk about a picture. So, I am taking simple real line let us say this is my theta naught. This when theta is less than or equals to this theta naught let us say this is my null hypothesis and when theta is greater than this theta naught let us call this a alternate hypothesis. Choose theta prime from this region and choose theta double prime from this region or alternate way I am I swapped it. Choose theta prime coming from an alternate hypothesis and choose theta double prime coming from null hypothesis. Now, if you have a test let us say if sample is coming from this theta prime that is alternate hypothesis and it is or another possibility that sample is coming from this null hypothesis under which parameter that your rejection probability should be higher. The rejection probability should be higher when it is coming from alternate hypothesis right. You do not want to accept it belonging to the null hypothesis when the underlying parameter is already theta prime it should be higher. On the contrary like if it is parameter from theta prime it being rejection should be smaller. So, that is exactly the unbiased net properties time to capture. It is saying that the probability of rejection of a sample that is coming from alternate hypothesis should be larger than probability of rejection of a sample that is coming from null hypothesis. If that is the case that means basically what it is saying is your test is such that it has more tendencies tendency to reject samples which are generated from the alternate hypothesis parameters that is what you you expect your test should be. If that is the case then you are going to call it as unbiased test ok. So, let us see whether the test we found for the Gaussian samples was unbiased or not. So, in the Gaussian samples which are coming from some parameter theta sigma square where as usual we assume theta is known and theta square is not known. For that your power function was this the LRT we constructed right. So, the LRT the LRT we constructed has a rejection region like this right what was that x bar minus theta divided by sigma square root n being large that was theta naught being greater than or equals to 0. We had something like that which get translated to this power function which we calculated in the couple of slides back. So, this is the power function we have. Now, let us try to see that if I have a power function I should be able to say whether it is a biased or unbiased test. Can you check whether this is an unbiased test? Apply this definition and check why is that yeah 1 minus 1 minus 5 no I am I have to tell this in terms of my beta function right power function. For my test here I have given you my power function and using this I need to tell whether it is a biased or unbiased test. So, that definition only requires you to use a power function nothing else. So, if theta increases here beta theta is increasing how does that conclude this is happening this is not our text this is about the thetas parameters yeah why is that. See now I have to check. So, I will take two values let us say I take theta prime double prime from here which is a smaller than theta theta naught and I take theta prime which is larger than theta. Since this b now I know that theta prime is less than or equals to theta naught and this is less than or equals to theta prime right. Now, if beta is monotonically increasing it must be the case that beta of theta double prime must be less than or equals to beta of theta less than or equals to beta of agree if beta is monotonically increasing that is it we proved we have shown that beta of theta prime is greater than or equals to beta of theta double prime. So, the test we had for the Gaussian samples based on our likelihood ratio test is indeed unbiased and notice that this is this holds only for some c and n value or any c and n value it holds for any c and n value right to all we want is monotonicity irrespective what is c and n this beta of theta function is monotonous ok. Now, this leads us to further look for the most powerful tests ok. So, again if you have to draw analogy with your estimators how did we do estimators first we started we are look for estimator which were unbiased and among the unbiased estimator what we were trying to look the one with minimum variance we wanted someone with a minimum variance maybe that kind of analogy can also be here right like of course, we want want a test which is unbiased, but now the variance analogy is now captured through our type 2 error and type 1 error now ok. Now, let us say we have a class of level alpha test I have many tests which are like level alpha their type 1 error is alpha nothing more than that. So, we know that for level alpha type 1 error is at most theta ok. Now, first of all if you have a level alpha test I know that my type 1 error is not going to be more than alpha, but now among the level alpha test I want to consider a test to be good which has a smallest type 2 error among them ok. So, that leads to the definition of uniformly most powerful class which we define as follows. Suppose we have a test like this is we have a test where theta is high I mean we have this as usual null hypothesis and we have this alternate hypothesis and let us say we have some c is a class of tests for this hypothesis and we are going to call this c to be uniformly most powerful if you take any beta that is you take any test in c now every test we are associating them with their power function right you take any test with power function beta of prime of theta in c if ok we say ok wait a minute I have to rephrase this. Now, we say some beta of theta belonging to c is uniformly more powerful test in c provided if you take this beta of c it should be equals to beta prime of theta for theta belongs to theta c component. What does that mean? This has a higher probability of rejection than any test in that class when my theta is coming from my alternate hypothesis. What it is saying that the whenever theta is coming from alternate hypothesis my probability of rejection is the highest in my class that guy is called uniformly most powerful test in that class ok. So, if you have a bunch of test and you give it a sample which is generated from an alternate hypothesis if some tested rejects it it did a good job because it is coming from your alternate hypothesis. But that UMP if this guy has rejected that is also likely very likely that it will also reject ok because the probability of rejection is higher than probability of rejecting reject probability of rejection of this guy the test we have selected ok in that way that is good in my set and that is why I am going to call it as most uniformly most powerful not only most powerful, but it is uniformly most powerful test. Now, the question comes fine this is all good I like unbiased tests I like powerful tests I like sorry I like uniformly most powerful test by the way did we decide yeah we just decided discuss unbiased test then we talked about most powerful test and now is there in a way what we are looking is a good test in my class of test that is my most powerful test or rather like uniformly most powerful test. Now, the question is such a test always exist ok see. So, is it possible that you can come up with multiple tests level alpha test ok just let us briefly discuss suppose let us say I have this I have this right z greater than or equals to c plus what was that theta minus theta sigma by square root n this was my I can choose from c and n and I will get some test let us say if you fix everything let us now focus on c itself let us take c equals to 0 and whatever this guy gives me wrote let us call for c equals to 0 let us call this as some alpha itself let us call alpha for c equals to 0. Now, if I going to increase this c now I will make c greater than 0 what will happen to this probability it is going to be less than alpha now right. So, what I can do is by just choosing different different c I can come up with so many tests right like if my c's are only allowed to be positive numbers I know by setting 0 I am going to get some value type 1 error let us call let us call this alpha and by choosing any c greater than 0 they are going to be all the tests are going to be less than alpha. So, all of them are going to be in can I call them they are belonging to a class with size level alpha by choosing different different c now I can construct a set class of tests which are level alpha test. Now, what I am looking is among them which is the one which is most powerful right. Now, this Neyman Pearson's lemma is something which tells us when one can expect a most powerful test to exist exists and how does it look like ok. So, here is a simple version of the Neyman Pearson lemma which only considers two simple hypothesis it only tries to distinguish whether my parameter theta 0 or theta 1 when it is theta 0 it is my null hypothesis when theta 1 is alternate hypothesis I just need to distinguish. If your hypothesis test is there and suppose let us say your rejection region is such that whenever your sample x has a higher probability under theta 1 then under parameter theta 0 I am talking probability, but it is also density when it is a continuous case then I am going to reject otherwise I am going to accept. But there is some constant here which is let us say some constant. So, you have defined your rejection region now in terms of the pdf or the probability mass function whichever is applicable and now let us under this rejection region I am going to define my alpha to be probability that my sample is going to be rejected under my parameter theta 0 that is it is my type 1 error ok. So, type 1 error I am going to call it as alpha. Now it says that any test which is with the above rejection region is going to be a uniformly most powerful test. If you are going to have a rejection region like this then that is going to be uniformly more sorry most powerful test it is not just that it is uniformly most powerful level alpha test. So, this is like a necessary condition. On the other hand it says that if you have a uniformly most powerful level alpha test or like it is saying that every uniformly most powerful level alpha test what if you can come up with one it has to be like look like this its structure has to look like this ok. So, it is basically saying how to construct an uniformly most powerful test and it is also telling you if somebody gives you a uniformly most powerful test how it will look like ok. And this is why this is a simple setting, but it is giving you a very nice characterization ok. So, here this constant factor is missing, but if you can come up with a constant factor and have a rejection region like this then it is going to be uniformly most powerful test, but under this simple case that you have just two parameter to test in your hypothesis testing setup ok. So, any questions on this or whatever we discussed so far about this most powerful test and this unbiased test. So, do you think anything else should be considered when we are looking into this test because these are properties right unbiased is a property uniform most powerful being a property is there any other property that you think one should consider when we are defining such test ok. Now, just briefly discuss the next topic that we will cover in the next lecture called interval estimations ok. Now, let us say you have these samples let us say they are all coming from Gaussian distribution with parameter theta and sigma square. So, what is the best estimator for theta? So, the best estimator for theta is sample me. Now, what is the probability that theta hat is equals to theta that your estimated value is exactly equals to the true value what is the probability what is this is it 0 why is that. So, what is the distribution of theta hat normal with what parameters mu and sigma square by n right. So, theta hat itself is a random variable which is continuous and continuous random variable taking any particular value we know that is going to be 0. So, when you estimate your value theta to be theta hat the confidence that you have that is going to be the exact value is how much you have 0 confidence in this because theta hat being exactly equals to being theta is 0. On the other hand, if I say theta hat or I will just say theta now belongs to theta hat let us say minus epsilon to theta hat plus epsilon. Can we calculate this probability? How? Ok, let us compute this. So, what we are basically asking is probability that theta is going to be less than or equals to theta hat plus epsilon and theta hat minus epsilon right and I know that this probability is simply summation of xi by n minus epsilon theta this is summation of xi by n plus epsilon. Or maybe I should have done something better instead of this I will get theta hat in between. So, this is fine right I am basically asking theta to be between theta hat minus epsilon and upper bounded by theta hat. Now, I want to write so, what is the random quantity in this? theta hat is the random quantity. Is theta is random quantity? No, that is a fixed parameter right. So, now, let us try to write. So, now, I know that this theta hat from this quantity is going to be less than theta by epsilon and this is going to be theta plus epsilon I can do this ok. And let us do this probability that theta minus epsilon what is this and I can further take this theta hat is summation xi by n or maybe before this I will do one more step. Probability that minus epsilon greater than or equals to theta hat minus theta less than or equals to epsilon. For time being let us take only n equals to 4 samples ok and sigma square to be 1 unit variance ok. Now, minus epsilon x bar is basically xi i 1 to 4 divided by 4 minus theta minus epsilon ok. Now, what I will do is probability that minus epsilon that is ok this is simply x bar minus theta divided by I am going to do 1 by 4 minus epsilon 1 by 4 and plus 1 by square root of 4. So, I have basically this quantity I have written as x bar and everything else I have divided by square root of 1 by 4. So, what is square root of 1 by 4 here? It is equivalent to sigma square by or like sigma by square root n right which I want. Now, because of that what I can say about this that is now I can write it as probability that minus epsilon this is going to be 2 epsilon this is now z this is going to be plus 2 epsilon right. Now, z is a standard normal I should be able to compute this probability. So, this is basically minus 2 epsilon 2 epsilon 1 upon 2 pi exponential this is a 0 thing right minus x square by 2. Now, will this be positive quantity? This is going to be positive quantity right. So, this is not going to be 0 like this. Earlier when you are asking exactly that to be theta you are 0, but now instead of that you are asking whether it will be in this interval you are going to get some positive quantity and now we are going to study that instead of asking exactly this value we want your estimation to be lie in some interval and see that with that our confidence will be any better. Here our confidence was 0, but here we see that already our confidence can be positive ok. So, let us stop here we will continue this interval estimations or confidence interval settings in the next class.