Learn R Programming

liver

The R package liver provides a suite of helper functions and a collection of datasets used in the book Data Science Foundations and Machine Learning with R: From Data to Decisions. Designed to make data science techniques accessible to individuals with minimal coding experience, it simplifies tasks such as data partitioning for out-of-sample testing and data transformations (z-score and min-max). Inspired by an ancient Persian idiom, the package likens this learning process to "eating the liver of data science," symbolizing deep and immersive engagement with the field. In addition to its helper functions, liver also includes a collection of datasets valuable for multivariate analysis.

Installation

To install the latest version of this package from CRAN, do the following from the R console:

install.packages("liver")

Loading

library(liver)

Example for Data Analysis

To see how to use the functionality of the package for data analysis:

Copy Link

Version

Install

install.packages('liver')

Monthly Downloads

1,017

Version

1.29

License

GPL (>= 2)

Maintainer

Abdolreza Mohammadi

Last Published

May 4th, 2026

Functions in liver (1.29)

conf.mat

Confusion Matrix
cpu_price

CPU Specifications and Market Prices
credit

South German Credit Data
doctor_visits

Doctor Visits and Health Care Utilization Data
drug

drug data set
find.na

find.na
creditcard_fraud

Credit Card Transactions for Fraud Detection
gapminder

Gapminder Data on Global Health, Income, and Population
conf.mat.plot

Plot Confusion Matrix
house

house data set
mae

Mean Absolute Error (MAE)
marketing

marketing data set
house_price

house_price dataset
liver-package

liver: Foundations Toolkit and Datasets for Data Science
minmax

Min-Max scaling of numerical variables
kNN

k-Nearest Neighbour Classification
loan

Loan Application and Approval Data
kNN.plot

Visualizing the Optimal Number of k
mortgage

Mortgage data set
mse

Mean Squared Error (MSE)
insurance

insurance data set
purchase_intention

Online Shopper Purchase Intention Data
prop.conf

Confdidence interval for proportion
skewness

Skewness
red_wines

Red wines data set
one.hot

One Hot Encoder
wholesale_customers

Wholesale Customer Spending Data
partition

Partition the data
z.conf

Confdidence interval for mean using z-distribution
skim

Skim a data frame to get useful summary statistics
zscore

Z-score scaling of numerical variables
risk

Risk data set
scaler

Feature scaling
t_conf

Confdidence interval for mean
white_wines

White wines data set
bank

Bank marketing data set
churn_mlc

Churn data set from MLC++ machine learing
churn_tel

churn_tel dataset
adult

adult data set
bike_demand

Seoul Bike Sharing Demand Data
caravan

Caravan insurance data set
advertising

advertising data set
churn

Churn dataset for Credit Card Customers
cereal

Cereal data set
accuracy

Average classification accuracy