AGR 204 · Computer Applications to Agriculture
Our notes
2 min readWhy use a package
Packages compute summaries and tests quickly and without arithmetic slips, handle large data sets, and draw graphs. You must still choose the right test and interpret the output.
Common packages
| Package | Notes |
|---|---|
| Excel / Calc (Data Analysis ToolPak) | Descriptive statistics, t-tests, simple ANOVA and regression |
| SPSS | Menus; common for surveys in social and extension research |
| R (with RStudio) | Free, powerful, uses commands; many agricultural packages |
| GenStat | Designed for agricultural experiments |
| SAS, Stata, Minitab, JASP | Others met in research |
Descriptive statistics
Mean, median, mode, range, variance, standard deviation (SD), coefficient of variation (CV = SD ÷ mean × 100). Spreadsheet: =AVERAGE(), =MEDIAN(), =STDEV.S().
Example: weights 2.0, 2.4, 2.2, 2.6, 2.3 kg. Mean = 11.5 ÷ 5 = 2.3. Deviations −0.3, 0.1, −0.1, 0.3, 0: squares sum = 0.09 + 0.01 + 0.01 + 0.09 + 0 = 0.20. SD = √(0.20 ÷ 4) = √0.05 ≈ 0.224 kg; CV ≈ 9.7%.
Comparing means
- t-test: two treatments (new feed vs old).
- One-way ANOVA: three or more treatments (fertiliser rates).
- If ANOVA is significant, a mean separation test (LSD, Duncan's, Tukey) shows which treatments differ.
- Correlation and regression: relationship between two variables (fertiliser rate and yield).
- Chi-square: association between categories (adoption and education level) in surveys.
Worked example: one-way ANOVA by hand
Maize yield (t/ha), three fertiliser rates, three plots each: A: 4, 5, 6 (mean 5); B: 6, 7, 8 (mean 7); C: 8, 9, 10 (mean 9). Grand mean 7.
- Between groups SS = 3[(5 − 7)² + (7 − 7)² + (9 − 7)²] = 3 × 8 = 24, df = 2, mean square = 12.
- Within groups SS = (1 + 0 + 1) × 3 = 6, df = 6, mean square = 1.
- F = 12 ÷ 1 = 12. The table value of F(2, 6) at 5% is about 5.14, so the rates differ significantly.
Check: total SS = sum of (each value − 7)² = 9+4+1 + 1+0+1 + 1+4+9 = 30 = 24 + 6 ✓.
Reading output
Look for the test statistic, degrees of freedom and the p-value: p < 0.05 is usually called significant. Report means with SD or standard error, and say which test you used.
Exams usually ask: name statistical packages and their uses; compute mean, SD and CV; choose a test for a given experiment; interpret a p-value or an ANOVA table.
Common mistake: running several t-tests between three or more treatments instead of one ANOVA. Multiple t-tests raise the chance of a false "significant" result.
Written by the UniHive team in our own words. Spotted a mistake? Tell us on WhatsApp.
Read
-
SPSS
(opens en.wikipedia.org in a new tab)
Wikipedia, SPSS, CC BY-SA 4.0 · licence
-
R (programming language)
(opens en.wikipedia.org in a new tab)
Wikipedia, R (programming language), CC BY-SA 4.0 · licence
-
List of statistical software
(opens en.wikipedia.org in a new tab)
Wikipedia, List of statistical software, CC BY-SA 4.0 · licence
Watch
We link to free material and never copy it. Every link was opened by our team before it went up; video data is a rough guide at 360p.