% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SFaov.R
\name{aov_of}
\alias{aov_of}
\title{One-Factor ANOVA for Agricultural Designs}
\usage{
aov_of(
  data,
  design = c("CRD", "RBD", "LSD"),
  treatment,
  replication = NULL,
  row = NULL,
  column = NULL,
  responsevar = "all",
  test = c("lsd", "tukey", "duncan"),
  transform = NULL,
  narc = 1,
  alpha = 0.05
)
}
\arguments{
\item{data}{A data frame containing experimental data.}

\item{design}{Type of design. One of "CRD", "RBD", or "LSD".}

\item{treatment}{Name of treatment column in the dataset.}

\item{replication}{Name of replication/block column (required for RBD).}

\item{row}{Name of row factor (required for LSD).}

\item{column}{Name of column factor (required for LSD).}

\item{responsevar}{Specific variables c("v1" ,"v2", "v3") or "all".}

\item{test}{Mean comparison test. Options include "lsd", "tukey", or "duncan".}

\item{transform}{List specifying transformations for variables.
Options include "log", "sqrt", and "arcsine".}

\item{narc}{Numeric or list specifying denominator for arcsine transformation.}

\item{alpha}{Significance level (e.g., 0.05).}
}
\value{
A list containing:
\describe{
\item{Individual outputs}{
Analysis results for each response variable separately.
}
\item{Summary statistics}{
Arithmetic mean, standard deviation, minimum, and maximum values for each variable.
}
\item{Shapiro-Wilk test}{
Results of the Shapiro-Wilk test for normality.
}
\item{ANOVA and mean comparison}{
ANOVA table along with mean comparison based on the selected test for each response variable.
}
\item{Combined table}{
A summary table including mean ± SD, grouping letters, SEm, SEd, CD, and CV values for all variables.
}
}
}
\description{
Performs analysis of variance for one-factor experiments under
Completely Randomized Design (CRD), Randomized Block Design (RBD),
and Latin Square Design (LSD). Supports multiple response variables,
data transformation, and mean comparison tests.
}
\details{
This function supports:
\itemize{
\item Analysis for CRD, RBD, and LSD designs
\item Multiple response variables
\item Data transformations (log, square root, arcsine)
\item Mean separation tests (LSD, Tukey, Duncan)
\item Combined summary table output
}
}
\examples{

# Example
data(Gnutdataset)
head(Gnutdataset)
Out_rbd <- aov_of(
           Gnutdataset,
           design = "RBD",
           treatment = "Trt",
           replication = "Rep",
           responsevar = "all",
           transform = list(Noflwr="sqrt", Germ="arcsine", Disease="arcsine"),
           narc = list(Germ=10, Disease=5),
           alpha = 0.05 )

# Single variable result
Out_rbd$Germ

# Combined table for all varaibles
Out_rbd$Combined_table

# Entire output
Out_rbd

#Example without transformation
Out_rbd2 <- aov_of(
  Soildataset,
  design = "RBD",
  treatment = "TRT",
  replication = "REP",
  responsevar = "all",
  test = "lsd",
  alpha = 0.05
)

Out_rbd2$Combined_table
}
