Skip to contents

Expand Aggregated Fish Data to Individual Records (simple without tidyverse version)

Usage

expand_to_individual_simple(
  data,
  treatment_col = "tmt",
  replicate_col = "tank",
  score_prefix = "S",
  total_col = "total"
)

Arguments

data

A data frame containing aggregated fish data

treatment_col

Name of the column containing treatment groups (default: "tmt")

replicate_col

Name of the column containing tank/replicate IDs (default: "tank")

score_prefix

Prefix used for score columns (default: "S")

total_col

Name of the column containing total counts (default: "total")

Value

A list containing:

  • data: A data frame with individual fish records

  • score_columns: Vector of all score column names from the original data