Skip to contents

Create empty composition for invalid inputs (Utility)

Usage

create_empty_composition()

Value

A named list with 13 numeric/logical elements, all set to zero or FALSE: total_weight, water_g, protein_g, ash_g, fat_g, water_fraction, protein_fraction, ash_fraction, fat_fraction, energy_density, total_energy, total_fraction (all 0), and balanced (FALSE). Used as a safe fallback when fish weight is zero or negative.

Examples

create_empty_composition()
#> $total_weight
#> [1] 0
#> 
#> $water_g
#> [1] 0
#> 
#> $protein_g
#> [1] 0
#> 
#> $ash_g
#> [1] 0
#> 
#> $fat_g
#> [1] 0
#> 
#> $water_fraction
#> [1] 0
#> 
#> $protein_fraction
#> [1] 0
#> 
#> $ash_fraction
#> [1] 0
#> 
#> $fat_fraction
#> [1] 0
#> 
#> $energy_density
#> [1] 0
#> 
#> $total_energy
#> [1] 0
#> 
#> $total_fraction
#> [1] 0
#> 
#> $balanced
#> [1] FALSE
#>