How to go about Hypothesis testing when mean and standard errors are calculated from different samples of the same population

I have to test a hypothesis of difference between two means.

I have hospital discharges data. There are 36484846 discharges and mean length of stay is calculated from these number of discharges.

I have also been given the standard errors of the data but the standard errors table mentions that the standard errors of the mean length of stay have been calculated using only 290747 discharges.

I am confused about how will I use such data for hypothesis testing for difference between mean length of stay between two hospitals. Also, which hypothesis test will be most suitable to use?

• You can't combine means from one dataset and standard errors from another (such as a subset of the full data, which is what it sounds like you have). In order to calculate a sensible comparison of the groups, you need to be able to calculate the means and SEs on the exact same data. – Rose Hartman Dec 25 '16 at 6:03
• Yes, I think about it as a subset of the all observations on which SEs have been calculated. In my knowledge as well, I have never done this that I calculated SEs on smaller number of observations. My question is - Is there any case where we can use smaller number of observations to calculate SEs or Is there anything like we call some observations not good to calculate SEs using those? Your help will be much appreciated. – Safdar Ahmad Wani Dec 25 '16 at 6:08
• I think there is missing information here. Are the 36484846 discharges from 1 hospital or a combination of both? Do you have sample means and standard errors for both hospitals along with separate sample sizes for each? In any case I suspect that the sample sizes are so large that the sample means and standard errors are close to what you would get for a normal distribution if the length of stay distribution satisfies the properties for the central limit theorem to apply to the sample means. – Michael Chernick Dec 25 '16 at 6:10
• If you are looking at estimates of the population standard deviation the smaller sample size may be so large that it almost converging to the population mean and the estimate based on the larger sample. will not be much different from the one for the smaller sample. The standard errors should decrease at a rate of 1/sqrt(n) where n is the sample size. So both SEs could be very small. – Michael Chernick Dec 25 '16 at 6:19
• There are total 36484846 observations. There are three kinds of hospitals- rural,urban non teaching and urban teaching. For rural- 4142560 , for urban non teaching- 13736270 and for urban teaching-18606016 observations. These three numbers total to 36484846. Mean length of stay has been calculated using the corresponding number of observations but I am puzzled that SEs have been calculated using different number of observations for each hospital like they have used 96981 for rural, 160403 for urban non teaching and 222260 for urban teaching. How to proceed with this data now? – Safdar Ahmad Wani Dec 25 '16 at 6:23