Introduction
To help introduce the basic concepts we start with the following example.
Example 1: A new fertilizer has been developed to increase the yield on crops, and the makers of the fertilizer want to better understand which of the three formulations (blends) of this fertilizer are most effective for wheat, corn, soybeans and rice (crops). They test each of the three blends on one sample of each of the four types of crops. The crop yields for the 12 combinations are as shown in Figure 1.
Figure 1 – Data for Example 1
We interrupt the analysis of this example to give some background, after which we will resume the analysis.
Definitions
Definition 1: We define the structural model as follows.
A factor is an independent variable. A k factor ANOVA addresses k factors.
A level is some aspect of a factor; these are what we called groups or treatments in the one-factor analysis discussed in Basic Concepts for ANOVA.
In Example 1 there are two factors: blends and crops. The blend factor has 3 levels and the crop factor has 4 levels.
In general, suppose we have two factors A and B. Factor A has r levels and factor B has c levels. We organize the levels for factor A as rows and the levels for factor B as columns. We use the index i for the rows (i.e. factor A) and the index j for the columns (i.e. factor B). Thus we use an r × c table where the entries in the table are
We use terms such as x̄i (or x̄i.) as an abbreviation for the mean of {xij: 1 ≤ j ≤ c}. Similarly, we use terms such as x̄j (or x̄.j) as an abbreviation for the mean of {xij: 1 ≤ i ≤ r}.
We estimate the level means from the total mean for factor A by μi = μ + αi where αi denotes the effect of the ith level for factor A (i.e. the departure of the ith level mean μi for factor A from the total mean μ). We have a similar estimate for the sample of x̄i = x̄ + ai.
Note that
Similarly, we estimate the level means from the total mean for factor B by μj = μ + βj where βj denotes the effect of the jth level for factor B (i.e. the departure of the jth level mean μj for factor B from the total mean μ). We have a similar estimate for the sample of x̄j = x̄ + bj.
As for factor A,
Null Hypotheses
The two-way ANOVA will either test for the main effects of factor A or factor B, namely
H0: μ1. = μ2. =⋯= μr. (Factor A)
or
H0: μ.1 = μ.2 =⋯= μ.c (Factor B)
If testing for factor A, the null hypothesis is equivalent to
H0: αi = 0 for all i
If testing for factor B, the null hypothesis is equivalent to
H0: βj = 0 for all j
Finally, we can represent each element in the sample as xij = μ + αi + βj + εij where εij denotes the error (or unexplained amount). As before we have the sample version xij = x̄ + ai + bj + eij where eij is the counterpart to εij in the sample.
Observation
Since
Definition 2: Using the terminology of Definition 1, define
Properties
Property 1:
Proof: Clearly
If we square both sides of the equation, sum over i, j and then simplify (with various terms equal to zero as in the proof of Property 2 of Basic Concepts for ANOVA), we get the first result. For the second,
Property 2: If a sample is made as described in Definition 1, with the xij independently and normally distributed and with all (or ) equal, then
Proof: The proof is similar to that of Property 1 of Basic Concepts for ANOVA.
Property 3: Suppose a sample is made as described in Definitions 1 and 2, with the xij independently and normally distributed.
If all μi are equal and all are equal then
If all μj are equal and all are equal then
Proof: The result follows from Property 2 and Property 1 of F Distribution.
Property 4:
Test Assumptions
We use the following tests:
Recall that the assumptions for using these tests are:
- All samples are drawn from normally distributed populations
- These samples were drawn independently from each other
- All populations have a common variance
- Within each sample, the observations were sampled randomly and independently of each other
We should also use Tukey’s Test for Additivity to make sure that the interaction between the two factors is not significant.
Example
We now return to Example 1 and show how to conduct the required analysis using Excel’s Anova: Two-factor Without Replication data analysis tool.
Example 1 (continued): The output from the data analysis tool is shown in Figure 2.
Figure 2 – Two factor ANOVA w/o replication data analysis tool
There are two null hypotheses: one for the rows and the other for the columns. Let’s look first at the rows:
H0: there is no significant difference in yield between the (population) means of the blends
Since the p-value for the rows = .0068 < .05 = α (or F = 12.83 > 5.14 = F-crit) we reject the null hypothesis, and so at the 95% level of confidence we conclude there is significant difference in the yields produced by the three blends.
The null hypothesis for the columns is
H0: there is no significant difference in yield between the (population) means for the crop types
Since the p-value for the columns = .1446 > .05 = α (or F = 2.63 < 4.76 = F-crit) we can’t reject the null hypothesis, and so at 95% level of confidence we conclude there is no significant difference in the yields for the four crops studied.
Worksheet Formulas
Although the analysis in Figure 2 was produced automatically by Excel’s data analysis tool, the same result can be produced using Excel formulas, just as we were able to do in Basic Concepts of ANOVA for one-way ANOVA. The most interesting cells are the ones corresponding to the four sum squares. We show how to calculate the values for each of those cells in Figure 3.
Figure 3 – Key formulas for analysis from Figure 2
The formulas for calculating SSRow and SSCol in Definition 2 involve taking squared deviations of the group means. E.g. SSRow can be calculated via the formula =DEVSQ(I6:I8)/H6. Alternatively, we can take squared deviations from the sums of each group, as is done in Figure 3.
Real Statistics Capabilities
The Real Statistics Resource Pack contains a number of functions and the Two Factor ANOVA data analysis tool that support Two Factor ANOVA without Replication. You can get more information about these in Two Factor ANOVA with Replication.
References
Psychological scales (2023) Is ANOVA with or without replication different?
https://scales.arabpsychology.com/stats/is-anova-with-or-without-replication-different/
Zar. J. H. (2010) Biostatistical analysis 5th Ed. Pearson
Hi Charles.
I have 1 group with 5 participants both receiving without treatment and without treatment. first, we test it without treatment, after a while, we apply treatment. what tool should we use?
It depends on what hypothesis you are trying to test, but it is likely that you will use a paired t test.
Charles
Hi Charles,
I want to compare one dependent variable resulting from two independent variables 1) A value obtained on different days and 2) this value obtained for samples indoors and outdoors. I have three samples (rows) for indoor samples on each day but four samples (rows) for outdoor samples on each day. I think I want to do a two way ANOVA in excel but the without replication option doesn’t seem to account for different numbers of rows being grouped into each of the two categories (either indoor or outdoor). I cannot seem to do a two-way ANOVA with replication because there isn’t the same number of samples for indoor or outdoor over time. What am I missing?
Hello Kritsen,
Because the sample sizes are different (an unbalanced model), you need to use the Regression option.
Since you are looking at the same subject on different days Day is a repeated measures factor and so you should use a repeated measures model. See
https://real-statistics.com/anova-repeated-measures/repeated-measures-anova-using-regression/mixed-repeated-measures-anova-using-regression/
Charles
That worked great Charles, I greatly appreciate your help! (and your software!)
Kristen
Hi Charles,
I have a data set where the variable is influenced by two factors. The means of the rows are quite different but the means of the columns are quite nearby. When I perform two factor ANOVA without replication, I am getting very low p value across both columns and rows. But when I perform single factor ANOVA in excel, the p value across the columns is quite high which seems realistic. In such cases, how do we judge which approach is more realistic?
If you are not interested in testing the rows, then you should use the single factor ANOVA.
Charles
Thanks Charles.
Hii sir , in my greenhouse experiments , there are two factor one is main factor and other is sub factor. in main factor there are three three treatments and also three treatments in the sub factor and number of replications is 3(three). than what types of statistical design is carried out in my experiments for the giving best results??
A nice article, Sir. But I want to ask if I have a mixed model anova with 2 factor, the first factor is about the cognitive style (between factor) that consist of 2 level (verbal vs visual). The second factor is media (within factor) consist of 2 level (text vs video). And I have 20 subject (10 visual 10 verbal) who did 1 task with text and 1 task with video. They exactly did the task once for each media. Is it a no replication anova type? can I use know about the interaction effect with that kind of design experiment? Thankyou
Hi Salsa,
See One between subjects and one within subjects factor.
Charles
Dear Salsa,
What you are describing is a repeated measures ANOVA with one between subject effect and one within subjects effect. See the following webpage for more information about this design:
One between subjects factor and one within subjects factor
Charles
Hi Charles
I want to ask difference between Anova two factor with replication and without replication?
Hi Saida,
Suppose that you have two factors A and B and A has 3 levels and B has 5 levels. If each combination of levels (3 x 5 = 15 in all) has exactly one sample value, then you have Anova without replication. If there are more than one then you have Anova with replication.
Charles
Charles,
Many thanks for your excellent website.
I am in need for your help. I am a plant nutrition researcher and dealing with different fertilizer experiments. There is one experiment of 3 main fertilizer treatments( say, A, B, and C) in three column and in each and every three column, want to incorporate three set of another different fertilizer treatments(say, X, Y, and Z) to find out their interaction effect. So, now it would look like 3*3. Now, the problem is there are no replications. can I feet it to any proper statistical design? if yes, then kindly elaborate. LSD may be the option but treatment is here less. Need your guidance pls.
Shubhadip,
Does this mean that you have 9 samples, one for each of the 3 x 3 = 9 combinations of treatments? If so, then Two factor ANOVA without Replication could be used. There is no interaction effect since there are no interactions.
Charles
Dear Charles,
Thanks for the reply. Actually, I want to set up an agricultural experiment where there are three main fertilizer experiments (main plot) and in three micronutrient fertilizer as the subplot in each main plot? then is it split plot or strip plot design or LSD?
Is it must for replication of main plot as well as for subplot to make it statistically significant (5% level) with less df?
Waiting 4 your kind response.
Hi Charles,
Thanks for this article. I’m wondering how this would work if the levels of Factor B were proportions/percentages and all levels in Factor B summed to 1 (or 100%). Surely these cannot be independent as they are constrained to be between 0 and 1.
I am looking at removing specific antibodies from a sample and measuring the proportion of different types of bacteria killed. From this I can determine the proportion of bacteria type killed by each antibody. To illustrate, for bacteria type A1, I may have results of B1=15%, B2=60%, B3=20% and B4=5%. So level 2 of Factor B kills the most bacteria of type 1.
I want to quantify the amount of killing attributed to each level of B so I can say ‘level c of B kills the most bacteria across all types’, or more likely, ‘level c of B kills significantly more of type r, while another level c of B kills significantly more of another type r’.
Hope that makes sense
Kieran,
This sounds like a chi-square test of independence. See
Independence Testing
BTW, if you leave out the last level for each factor the others won’t sum to 100%
Charles
Thanks Charles,
Of course, thank you!
Kieran
Dear Charles, I have to compare three treatments (A, B, C) over time (T0, t15, t30, t45, t60, t 75 and t90). Is it right to apply a two-ways ANOVA for the statistical analysis? Using Excel, I obtain the effects due to treatment and to time factors. To obtain also the interaction time x treatment which analysis or software should be more appropriate to be applied? Many thanks for your kind support
Gabriella,
The time measurements are not independent, and so this approach isn’t correct. You could use repeated measures ANOVA (probably with one between subjects factor and one within subjects factor). See the following webpage:
Repeated Measures ANOVA
Charles
You have confirmed what I supposed, thanks a lot!
Hi, Sir Charles!
I just need some help with my data. I have done two-way ANOVA with replication on my data wherein, briefly, I am trying to compare the length of shoots of corn and anuang after application of mimosine extract. Based on the anova, the sample, the column and the interactions all yielded Pvalue<0.05. I am quite confused what follow up test should i use to determine where exactly the difference is. What should I do?
Ecarg,
There are many possible tests, but the most commonly used are contrasts and Tukey’s HSD. These are both supported in the Real Statistics website and software. See the following webpages:
https://real-statistics.com/two-way-anova/follow-up-analyses-for-two-factor-anova/tukey-hsd-after-two-factor-anova/
https://real-statistics.com/two-way-anova/follow-up-analyses-for-two-factor-anova/contrasts-two-factor-anova/
Since you have a significant result for the interaction, you should probably start by using Tukey’s HSD on the interaction.
Charles
If i want to detect the presence of a single contaminant in biscuits taken from nine towns of a city. from each town, 6 samples of biscuits would be collected. in this case whether a one – way or a two-way anova should be applied?
Sorry, but I don’t understand your scenario. It doesn’t appear that you are testing a hypothesis, which is what ANOVA is used for.
Charles
Nice post! I have a small question. Suppose I want to perform a factorial analysis with three independent factors (Time: 24 and 48 hours; Temperature: 27, 35 and 43 degrees; and Concentration: 0.6, 0.8, 1.0, 1.2 and 1.4). This is a model without replication, so I get 30 observations. I ran an ANOVA specifying the model and I got some order two interactions significant. How is the homogeneity of variance assumption tested in this car? As you say, I have only one observation per cell so Levene’s test for example won’t say anything. Can I still trust the outputs from the ANOVA tests?
Thank you.
Alvaro,
With no replications, there is only one observation for the three factor interaction, but there are more than one observations for the pairwise interactions, and so you can use Levene’s test (or other approaches to determine homogeneity of variances). You can see this better by looking at Figure 2 of the following webpage
https://real-statistics.com/two-way-anova/three-factor-anova-without-replication/
Charles
Charles,
Thank you for the quick answer. But Levene’s test in my case doesn’t return any p-value. I have only, as I explained, three factors and two interactions between 2 factors. When running the homogeneity test (in SPSS), the output says that the degrees of freedom of the Levene’s test statistic are 29 and 0 and hence not returning any value. How is that possible? Should then I run the test several times, for two factors and their interactions?
Alvaro
Alvaro,
If you don’t have any interaction terms (i.e. one cell per interaction), then you can’t analyze interactions using ANOVA. With two interactions, you can calculate variances and so can see whether homogeneity of variances holds. You won’t be able to use Levene’s test though. You can see whether the largest variance is fairly similar to the smallest variance. Usually a ratio of 3 or 4 to 1 is acceptable, but I am not sure whether this is so with such a small sample.
Charles
I am very curious to know, how to read the final result table for Two Way ANOVA with / without replication, in Excel.
For One Way ANOVA, as it is very clear if all the factors have same population mean or not, what is the simplest interpretation for Two Way ANOVA (With / Without replication).
Please guide.
Vivek,
The interpretation is similar to that for one-way ANOVA except that now you can test the significance of factor A and factor B. There is no interaction factor.
Charles
Hello again Charles,
Very good refresher! It is always surprising to see how we can make inferences with very small samples…
Why aren’t we looking at interactions in the case of ANOVA without replication?
Thanks!
Fred
Fred,
In ANOVA without replications there are no interactions to analyze.
Charles
OK, I need to get my head around as to why interactions are not considered in this case, will do that later 🙂
Going back to sample sizes, can the ANOVA assumptions of normality and equal population variances be verified when there is only 3 or 4 values per level?
Thanks again Charles,
Fred
Fred,
1. In the case of ANOVA without replication, there is only one value for each interaction. You can’t even calculate a variance in this case.
2. Yes, you can verify the ANOVA assumptions, but with such small samples I would be cautious about any conclusions reached. In any case, the statistical power of such tests will be very low.
Charles
But where variance is used to estimate the interaction effect?
There is no interaction effect in the case of two factor ANOVA without replication.
Charles
Ho Charles
If I have one factor with 4 levels and without replication. How can I do my statistical analysis ? And also I need to compare the mean of 4 levels of this factor between them. Thank you for your collaboration.
Mohamed,
If you don’t have any replications, then you only have 4 data elements, one for each level. The mean of each level is therefore the same as the single data element for that level. You can’t do much with this, and certainly not ANOVA.
Charles
Thank you very much for your reply
I need to clarify something. I have 8 observations for each level.
Mohamed,
You can use one-way ANOVA. See
https://real-statistics.com/one-way-analysis-of-variance-anova/
Charles
Hi
I really appreciate if you can help me resolve the following issue. In my wood preservation study, I have two independent variables which are the duration of treatment (3, 7 and 21 days) and the acetic acid concentration (0.5, 1, 1.5 and 2.0 Molar). I also had a control (untreated) in which I did not expose to acid. I have tested these two factors and recorded the mass loss of wood after fungal decay. How do I perform two-way ANOVA to describe if there is any significant difference among the two factors in relation to control?
Syazwan Azmi,
If I understand correctly, you have one fixed factor Concentration (with levels 0, .5, 1.0, 1.5, 2.0) and one repeated measures factor Duration (3, 7, 21). If so, you can use the mixed repeated measures version of ANOVA, as described on the following webpage:
https://real-statistics.com/anova-repeated-measures/one-between-subjects-factor-and-one-within-subjects-factor/
Charles
can we made this data or any 2 way anova without replication its self in SPSS?
Sorry, but I don’t understand your question.
Charles
I have done experiment studying microclimate variables as influenced by planting density ( 4 levels) and pruning ( 2 levels) along with a control ( open)- forming a (4 x 2)+1 experiment. There are no replications. But I have data collected for 52 weeks. What would be the ideal method of analysis here
Santhosh,
What hypotheses are you trying to test?
Charles
Hi Charles,
The table in property 3 in the row “Effect of factor A” suggests statistical test “MS(A)/MS(W) ~ F(df(A),df(E))”. What is MS(W)? Shouldn’t it be MS(E) instead? Same applies for the “Effect of factor B”…
Thanks,
Vitali
Vitali,
Yes, you are correct. I have now changed the table on the webpage. Thanks for your help in improving the Real Statistics website.
Charles
Hi Charles,
Thank you so much for this clear and concise explanation.
I have a set of biodiversity data with two independent variables – distance (continuous) and location (categorical). For example, at 10 metres, the mean biodiversity is 0.2 at Location A and 0.5 at Location B. I would like to find out if the there is a significant difference between the two locations, and if the distance is a factor. Would the Anova Two Factor Analysis be suitable?
Anna,
I would need more information to say for sure, but it does seem like two factor Anova is suitable.
Charles
I have two variable independent and one dependent variable. should i use Anova: Two-factor Without Replication to find the significant of the variable?
Linda,
Whether you use ANOVA or some other test depends on what you are trying to test. I am not sure what you mean by “find the significan[ce] of the variable”.
Whether you use the Two Factor ANOVA with Replications or without Replications depends on whether you have replications.
Charles
Is it possible to perform single factor ANOVA without replication?
Manvik,
That would mean that you have only one sample element for each group. No you can’t use ANOVA in this case.
Charles
Hi. I was looking for how to’s on 2 way anova and ended on your site. But I’m still having trouble with my data. I have 7 categories of problems on shipment and their frequency for 2015 and 2016. Will this suit my hypothesis that says there is no significant difference in the commpon problems of 2015 and 2016?
Meliza,
I need more information to answer your question. It might be that you need to use Hotelling’s T-square test since you have multiple categories.
Charles
Hello sir,
I have 3 Inputs(independent variables) and 1 output(Dependent variables). Using ANOVA I have to determine 2 things here:
1) Which of the 3 inputs is dominantly affecting the output.
2) What in the uncertainty in the output value due to input values.
Can u please suggest me the procedure to do so.
Thanks.
Hi,
I have 2 IV (blue and red paper)and 2DV(anxiety and stress). The Dv’s are conducted pre and post the IV. I have been advised to conduct a 2×2 ANOVA . Would I start by adding the anxiety before and after looking at the coloured papers together or would I add the anxiety scores before looking at the paper and then add the scores for after and do this also for stress? And then how would I put this in SPSS because don’t i need to only add one DV for a ANOVA?.
Any help will be appreciated
Thanks
HH,
Sorry, but I don’t have a sufficiently clear idea of your situation to be able to give you an answer.
Charles
Hi there Charles! I’m presently having my thesis. I’m quite confused on what to do, tried to search over the internet then ended on your excellent site. Anyway, I’m doing a correlational study on self-concept, job satisfaction and perceived organizational support. I have two moderating variables, work tenure and length of professional experience. For the latter (length of professional experience), I have categorized it into 5 groups so I was advised to use ANOVA and the queries start their. Should I use the two factor ANOVA with replication or the one without? How should I do this? Thanks and more power!
This depends on whether or not you have data from multiple sources for each intersection cell.
More specifically, compare Figure 1 from the referenced webpage with Figure 1 from the following webpage
https://real-statistics.com/two-way-anova/two-factor-anova-with-replication/
Charles
Hi Charles,
I’m bit confusing, I’d appreciate your advice about this study.
I’m having a drug group and a placebo group, and I’m measuring lab parameters on two time points; at baseline and after two month. It’s an RCT.
Data are normally distributed, so I used an independent t-test to compare between groups.
I’ve been advised to perform a 2-way ANOVA ! after searching, it was revealed that such analysis needed a 2 categorical independent variables.
I’ve thought they maybe considered a one-factor repeated measure ANOVA?!
I’ve done it with time (2 level) and a Group as a fixed variable, and there was no sig. on between groups test, although the results from both ANCOVA (with pre-tests values as covariates) and independent t-test were significant between groups.
I’ve read that ANCOVA is considered better in pre-post treatment analysis especially in RCTs.
Can I even perform a 2-way ANOVA ? and if No, what Can I argue with? I’m sending it a reviewer who asked me to use a 2-way ANOVA.
Sorry for disturbing .
Mona,
If I have understood the situation correctly, you have two factors: a fixed factor Treatment (drug, placebo) and a repeated measures factor Time (baseline and 2 months later). I described this type of test on the following webpage:
https://real-statistics.com/anova-repeated-measures/one-between-subjects-factor-and-one-within-subjects-factor/
Charles
Hi again,
thank you very much for your reply. I do appreciate the help.
I’ve just tried to make it, it seems that ANOVA with replication needs same nember of samples, I have the treatment group 28 and the control group 29.
what should I do ?
thank you in advance,
Mona
See Unbalanced ANOVA
Charles
How do i interpret this :
ANOVA
Source of Variation SS df MS F P-value F crit
Rows 185.2422414 57 3.249863884 6.740541094 2.41869E-41 1.339297472
Columns 190.9956897 19 10.05240472 20.84968772 1.0899E-60 1.596133621
Error 522.1543103 1083 0.482136944
Total 898.3922414 1159
0.851643958
Since the p-values are almost zero, this means that there is a significant result for both the Rows and Columns factor.
Charles
Hi Charles
thanks for your amazing explanation.
I am doing my thesis and a bit confuse about analyse part.
Here is summary:
I have two different wheat varities(D and R ). each varitie went under three different level of fertilizer(1.2. 1.5 1.7) and then treatment R and D with the rate of 1.2 and 1.5 got three replicants and treatment R and D with the rate of 1.7 got four replicants.
here is my questation can I use Anova two way test with replicants or not???
Thanks a lot
Azin,
Yes, you can use two way ANOVA with replications. Since the number of replications differs, you need to use the regression version of the analysis. See
Unbalanced Anova
Charles
Could you tell me how i can determine my analyse method for my experiment, i have 9 chemicals materials every one was divided to three concentrations (50, 100 and 150%), if you can help me using SPSS or Excel
without replications number 10 without chemical materials (just one value)
Gh,
Sorry, but I don’t understand.
Charles
Gh,
What do you want to test?
Charles
i have 9 factors: every one has three levels without interactions among factors and the tenth factor without levels, what is the best method to analyse this experiment? thank you
Hi Charles, I want to know if which two ANOVA is appropriate to calculate the significant difference in the means of some data with two treatments across three different age groups
Ajibola,
You have 2 levels for the Treatment factor and 3 levels for the Age factor. Now the question for you is how many subjects do you have for each of the 6 combinations of Treatment x Age? If one then you need Two Factor ANOVA without Replication. If more than one then you need Two Factor ANOVA with Replication.
Charles
Hello,
Thank you for your great addin. I have been working with your Gage R&R feature. The way that I understand the number of categories is that it is the (stddev(part)/stddev(gage))*sqrt(2). Your Gage R&R report uses (stddev(part)/stddev(total))*sqrt(2). Am I misunderstanding a variable, or should the top formula be used?
Thanks
Neil,
I believe that I am using the formula with gage and not total variation.
Charles
Hi Charles
I have done carried out a biofilm assay with two different nanoparticles with 6 different concentrations (0, 100, 200,300,400,500) without replication. Please let me know whether I can use two way ANOVA without replication for this dataset. I find significant difference betwee the two types of nanoparticles when I do the test. However, there is no significant differences between different concentrations. What I am confused is that the difference between columns (diff concentrations) is for both types of nanoparticles. However, when I replicate and do t-test assuming equal variance between control and different concentrations of nanoparticles, I find there is a significant difference. Please let me know which method and analysis is appropriate .
Niluka,
If I understand your scenario correctly, it seems that you can use Two Factor ANOVA without replication. The differences between the columns is for both types of nanoparticles (combined).
I don’t understand what you mean by “when I replicate and do t-test”. If you like, you can send me an Excel file with this data and analysis so that I can better understand what you are trying to do.
Charles
I’m using the Two Factor Anova data analysis tool and just noticed that the means for each of the categories in the two factors (the categorical “total” means as opposed to the means at each intersection of variables, if you will) are calculated by averaging the corresponding cells in the matrix of means, as opposed to either calculating them directly from the data or using a weighted average. This seems to be producing inaccurate results.
Madison,
The Two Factor Anova supports two input data formats: Excel format and standard (i.e. stacked) format. When Excel format is used, I believe that marginal means are based on the original data, but when standard format is used then the marginal means are the average of the group means, as you have observed.
For balanced models (when all interactions have the same number of elements), both approaches yield the same result. This is not the case for unbalanced models. For unbalanced models, you should choose the Regression option on the Two Factor Anova dialog box. This will use the standard format approach to calculating the marginal means. This is the preferred approach as described on the following webpage:
Unbalance Approach to Two Factor Anova
Charles
The distinction between balanced and unbalanced models was what I was missing, thank you! Your site is an excellent resource, and it is very much appreciated!
Charles,
Which test can I use when the assumptions for using a Two Factor Anova, especially the one of a common variance, are not met? I understand that the Kruskal Willis test can only be used in place of a One Way Anova.
Thank you again,
Erik
Erik,
You can use Scheirer-Ray-Hare as a substitute for Two Factor ANOVA with Replication. This test has limited power, but it is a possible approach.
Charles
Hello Mr Charles.
Can you please tell me why I get a p value 2.76E-08 while performing Two way ANOVA without replication between Season and Species Density?
Thank you
Have A Nice Day
Anila Ajayan
Anila,
A p value of 2.76E-08 is a small value which is equal to .0000000276. This value is written in what is called scientific notation.
Charles
can u do anova for me….if yes , then reply to me at santoshpandey511@gmail.com
No. You will need to do this yourself. I am providing you the tools and explanations, but you need to do the work.
Charles
I am attempting to perform this ANOVA, but my variance results column has #DIV/0! for all values, leading to #NUM in my P-value and F-crit value boxes. What is the problem with my data?
Hilary,
If you send me an Excel file with your data and calculations and I will try to figure out what is going on. You can get my email address on the webpage
Contact Us
Charles
I’m experiencing a similar problem. This time, I can’t do the Tukey HSD test follow-up for two factor anova because the variances has #DIV/0! for all values. Hope you can assist as well.
You need to fill in the contrast column (labeled c) in the output with 1 for one group and -1 for another group. In this way you compare two groups.
Charles
Hi Charles,
I have the same problem. Since my data doesn’t have replication, the variance of response in every interaction of the factors cannot be calculated.. so it resulted #DIV/0!. Could you please give me any suggestion?
Thank you
Regards,
Zahra
Hi Zahra,
Sorry, but when you say that you “have the same problem”, whom are you referring to?
In the case where there is no replication, there is no interaction factor, and so you cannot analyze it. You can, however, analyze the two main factors, as described on the referenced webpage.
Charles
Which post hoc test should I use in the excel toolpack when I find significance in the results of the two factor anova without replication?
Thanks
Kelly,
You can use the usual post hoc tests for ANOVA with replication, except those that test the interaction (since you are assuming there is no interaction). Probably most useful are contrasts and Tukey’s HSD. An example of the Tukey’s HSD is given on the following webpage:
Question (3) of the Spring 2005 exam from http://www.math.utah.edu/~treiberg/M3081Finalsamplesoln.pdf
Charles
hi I m doing two way anova with replication but results for P and F value are not coming normal. My data is having 6 columns and 24 rows for each column. I am confuse what is happening.
Please explain better what you mean by “P and F value are not coming normal”.
Charles
HI Charles
Many thanks for your excellent website.
I am having trouble finding the ‘ANOVA: two factor without replication’ tool in the data analysis toolkit. I go to the ‘analysis of variance section’ and check the the ‘Anova: two factors’ box but there is then no option for ‘without replication’. Hence I cannot understand how to arrive at the output for this example. (similarly with the example for Anova: 2 factor with replication).
I hope you can help.
Regards
Hi Sean,
For ANOVA without replication choose the Anova: two factors option. Then in the dialog box that appears insert 1 in the Number of Rows per Sample field.
Charles
How can I do multiple comparison like LSD, DMRT between treatment by this two way annova without replecation.
I don’t support these follow up tests at present. I don’t support LSD because I find other tests are better.
Charles
Can you tell me, name of some others test? Which one is better to draw conclusions.Thank You.
Which follow up test is best depends on a number of things (equal sampler size or not, homogeneity of variances or not, etc.). Generally I use Tukey’s HSD post-hoc test for ANOVA with replication. See the following webpage:
Unplanned Comparisons
I have not thought about what sort of post-hoc tests are appropriate for ANOVA without replication.
Charles
Because the degree freedom of error is equal to zero when trying to calculate the interaction effect,so we can conclude that their are no interaction effects in this case? Is that right?
Thank you
There are no interaction effects in two factor ANOVA without replication.
Charles
what does it mean by error values that come out in ANOVA table (2 way without replication)…how to interpret it?
Like any error value, the lower the value the better the fit of the model.
Charles
Nice work and thanks.
You have written:
rows = .0068 < 05 = α
It ought to be:
rows = .0068 05 = α
should be:
columns = .1446 > 0.05 = α
(Or you could write 0.05 as .05, same thing)
Thanks again.
Posting the above comment also dropped the decimal on my first example for the correction. Must be something in the way the HTML is conveyed.
Test:
05 needs to be written either 0.05, or .05.
Strange!
Dave,
Thanks for catching this typo and for helping improve the accuracy of the website. I have now revised the webpage to include the decimal point.
Charles
I use Analysis of variance-two factors Appear number of rows per sample must be a positive integer. what is this please teach me thanks.
In a Two factor ANOVA there are two factors, which I will call Row and Column. Suppose the Row factor has 3 levels and the Column factor has 4 levels. If say there are 240 elements in the sample, with 20 elements in each combination of Row and Column levels (3 x 4 x 20 = 240). The value for number of rows per sample = 20.
Charles
The math here is not correct, possible typo on the greater than sign>
(or F = 2.63 > 4.76 = F-crit)
Chris,
Thanks for catching this typo. It should indeed state (or F = 2.63 < 4.76 = F-crit). I have now corrected this mistake on the referenced webpage. Thanks again for bringing this to my attention. Charles
Should the Figure 2 labels read without replication?
Jeff,
Yes, you are correct. The caption for Fiure 2 should read “without replication”. Thanks for catching this typing mistake. I have now corrected the caption on the webpage.
Charles
Could you please define two factor anova without replication.
This defined on the referenced webpage.
Charles
I want a correlation/comparison of yields(dependent variable) of brand of marketed tea with different temperature and power combination of ultrasonic machine as independent variable. How i can arranged may data for ANOVA. Kindly help me
Mohammed,
You haven’t provided enough information for me to answer your question.
Charles
very nice website! It is good to learn Stats with easy-to-use samples.