1/22
Looks like no tags are added yet.
How to test of the significance of a hypothesis
State the null and alternative hypothesis
calculate the value of the test statistic
find the p-value of the data
state a conclusion using either the p-value or the test statistic
null and alternative hypothesis
Null: also known as H0 is a statement of no effect, implying that there is no relationship between the means of the variables
often that the mean or difference between means = 0
Alternative: also known as H alpha, is the statement of an effect or that there is a relationship between two variables
either mean or difference is not 0 or is in fact a particular variable
what is a test statistic
A standardised measure of how different data is, with values closer to zero indicating that the null hypothesis can be retained
TS = sample mean - hypothesised value/standard error of estimate
can also be a measure of difference between means
what is the p-value
The probability that when H0 is assumed to be true, you get results that are not consistent with H0
the smaller the p-valeu the weak the evidnce against the null hypothesis
what are the ranges for the p-value
0.05 to 0.1 = weak evidence
0.01 to 0.05 = string evidence
less than 0.01 = very string evidence
how to determine significance of results
involves determining whether the strength of the evidnce is enough to reject the null hypothesis
done by comparing the significance level, often 5% or 0.05, to the p-value
if p-value is lower than the significance level, reject the null hypothesis
if p-value is grater than the null hypothesis then we retain the null hypothesis ( aka fail to reject)
what is a two sample t-test
A test that determines if there is a significant difference between the population means of tw idenpendent groups from different populations
can either be two groups experiencing two treatments, or two differently characterised groups experiencing the sample treatment
what are the assumptions for a two sample t-test
Simple random sampling was used
the samples are independent of one another in terms of random sampling and allocation
Both populations are normally distributed (or can comply with the Central Limit Theorem) - can be checked using a q-qplot
each group comes from distinct population (either 1 sample split into and treatment and a control or 2 samples from two populations)
what are the hypotheses for a two-sample t-test
in a two-sample t-test this involves comparing the means of each sample
can either be that the first mean minus the secound does(H0) or doesn’t(H alpha) equal 0
of can be that the mean are the same(H0) or not he same(H alpha)
how is a test statistic calculated in a two sample t-test
uses a t-distribution with whatever is small between n1 - 1 or n2 - 1
involves us subtracting the point estmate of each sample and dividing it by the square root of ecah sample SD/ sample size added together
how is a p-value calculated in a two sample t-test
calculated by R using a t-distribution with a degree of freedom of whatever is smaller between n1-1 pr n2-1
how are confidence intervals calculated in a t-test
Calculated using a t-distribution, not a normal distribution, meaning the critical value is now t*
is calculating the general range of differences between the means of each sample
the margin of error is also calculated with the t*
what are the 2 ways to calculate two sample t-test using RStudio
The first way uses the calculations above and assumes that the variance between the populations is different
the second way is used when the variances are the same and uses different formulas
How to interpret the results confidence of a t-test
if the intervals of confidence include zero or the null value, then we can retain the null hypothesis, as there is a possibility that the population mean is 0/the null value
what is a matched pair test
Involves comparing the difference between either a before-and-after test where one group receives both conditions, or comparing the results of two individuals who are linked together across groups and assigned to different treatments
we are looking specifically at the difference between groups
in before and afters subjects are used as their own control group
what are the assumption need for a match pair test
You have a simple random sample
the 2 samples are dependent and are naturally or selectively linked in some way
each subject only does to one group ( no true before and after)
the sampling distribution of the sample means is or close to being normally distributed
What are the hypotheses used for a matched pair test
since we are look at the difference between two treatment/induviduals the hypothesis are
null: the mean different between the samples is 0
alternate: the mean difference between the sample is not 0
how is a matched pair t-test done in r-studio
Need to create a new data set with the differences between the samples, and they do a t-test using that data set
Technically gives you the results you would get if doing a one-sample test
how do the formula for a matched pair test differ to a two-sample
The test statistic is the mean difference between the samples / the SD of the differences / the square root of the combined sample size
The p-value is calculated using a t-distribution with a df of n-1
confidence intervals also using t* and are used to calculate an interval that contains the true population mean of differences
What is a one-sample t-test
Determines the difference between the population mean and a certain null value
Used when the population standard deviation is unknown
caluclations done the same as matched pair but we are calulationg the diference between the sample and the null value
what are the assumptions for a one-sample t-test
The sampling method is simple and random
the samples are independent
the sampling distribution is normal or complies with the central limit theorem
what are the hypothesis for a one sample t-test
null: the mean of the population = the null value
alternative: the mean of the population doesn’t = the null value
how can the presence of an outlier affect the results of a one-sample t-test
It can invalidate the results of the test
If it is a real measurement, then a non-parametric hypothesis test can be used
if it is an error then it can be removed along with proper justification