mve.f: Estimation of missing values for a factorial experiment

View source: R/mve_f.R

mve.fR Documentation

Estimation of missing values for a factorial experiment

Description

Function to estimate missing values for factorial experiment with a CRD or a RCBD by the least squares method.

Usage

mve.f(trait, factors, rep, dfr, maxp = 0.1, tol = 1e-06)

Arguments

trait

The name of the column for the trait to estimate missing values.

factors

The names of the columns that identify the factors.

rep

The name of the column that identifies the replications or blocks, NULL for a CRD.

dfr

The name of the data frame.

maxp

Maximum allowed proportion of missing values to estimate, default is 10%.

tol

Tolerance for the convergence of the iterative estimation process.

Value

It returns a data frame with the experimental layout and columns trait and trait.est with the original data and the original data plus the estimated values.

Author(s)

Raul Eyzaguirre.

Examples

# A data frame with some missing values
temp <- asc
temp$dm[c(3, 10, 115)] <- NA
# Estimate the missing values
mve.f("dm", c("geno", "treat"), NULL, temp)

reyzaguirre/st4gi documentation built on April 20, 2024, 3:53 a.m.