Skip to content
A tool for getting the information of animal feeds.
R
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
R
data-raw
data
man
vignettes
.Rbuildignore
.gitignore
DESCRIPTION
LICENSE
NAMESPACE
README.html
README.md
feed.Rproj

README.md

feed

A tool for getting the information of animal feeds.

Overview

feed is a tool for getting the information of animal feeds. Basically, it can load, modify, and compare the animal feed dataset from Animal Feed Resources Information System (INRA CIRAD AFZ and FAO).

Installation

# install.packages("remots")
remotes::install_github("adatalab/feed")

Usage

library(feed)

Feed information

feed_list

feed_list function shows the list of feeds of feedipedia.org.

# All feeds
feed_list(category = "all")

# Forage plants
feed_list(category = "forage")

# Plant products/by-products
feed_list(category = "plantProduct")

# Feeds of animal origin
feed_list(category = "animalOrigin")

# Other feeds
feed_list(category = "other")

feed_search

feed_search function shows the results found at feedipedia.org. When you find the result (in the R or Web) that you want, copy the url for scraping the feed data using feed_info function.

feed_search("maize")

feed_info

feed_info function shows the nutritive values of the specific feedstuff(url) in the form of a list. If you use extract option, a list is returned for each nutrient composition of the specific feed.

# get the information about the url
feed_info(url = "https://www.feedipedia.org/node/556")

# extract 2nd objects of nutrient composition dataset list
feed_info(url = "https://www.feedipedia.org/node/556", extract = 2)

feed_compare

feed_compare function compares each result of feed composition.

# extract the result
feed1 <- feed_info("https://www.feedipedia.org/node/556", 2)
feed2 <- feed_info("https://www.feedipedia.org/node/674", 3)

# extract the main analysis results
feed1 <- feed1[[1]]
feed2 <- feed2[[1]]

# compare the results
feed_compare(feed1, feed2, radar = TRUE)

Conversion

dm_asis

dm_asis function converts dry-matter basis into as-is basis.

df <- data.frame(nutrient = c("CP", "NDF", "EE", "Ash"), composition = c(10, 30, 5, 2))
dm_asis(composition = df$composition, dm = 85, digits = 2)

asis_dm

asis_dm function converts as-is basis into dry-mater basis.

df <- data.frame(nutrient = c("CP", "NDF", "EE", "Ash"), composition = c(10, 30, 5, 2))
asis_dm(composition = df$composition, dm = 85, digits = 2)

j_cal

j_cal function converts joule into calorie.

j_cal(joule = 4000, standard = "15")

cal_j

cal_j function converts calorie into joule.

cal_j(cal = 5000, standard = "15")

Datasets

feed_nias

feed_nias is a dataset fram National Institute of Animal Science (South Korea). This dataset contains the information of common feed ingredient used in South Korea. The dataset contains the Korean language.

feed_nias

# find the ingredients by the name
feed_nias %>% dplyr::filter(grepl("옥수수", .$ingredients))

amino_acids

This dataset contains the list and characteristics of amino acids.

amino_acids

fatty_acids

This dataset contains the list and characteristics of saturated and unsaturated fatty acids.

fatty_acids

Getting helps

Email: ruminoreticulum@gmail.com

You can’t perform that action at this time.