Learn R Programming

ProTrackR2

ProTracker is music sequencer software from the 1990s on the Commodore Amiga (see screenshot of version 2.3a on the right). The R package ProTrackR2 is the successor of ProTrackR. It can be used to play and manipulate ProTracker module music.

Installation

You can install the development version of ProTrackR2 from r-universe with:

install.packages("ProTrackR2", repos = c("https://pepijn-devries.r-universe.dev", "https://cloud.r-project.org"))

Install the CRAN release with:

install.packages("ProTrackR2")

ProTracker2.3d clone

The ProTrackR2 package essentially provides an R entry point into the ProTracker2.3d clone by Olav Sørensen (A.K.A. 8bitbubsy) and other contributors (source code). For this purpose, I took the code by Sørensen and stripped away the graphical user interface (GUI) and access to the audio device. Next I added R bindings to access functionality to read, write, manipulate and render ProTracker modules. This allows you to process such modules with R scripts and in batches. If you wish to use the the GUI I suggest to visit one of the links above and check out the work of Olav Sørensen.

The work by Olav Sørensen is gratefully acknowledged here, without which this package would have not been possible.

Example

The example below shows how to load a ProTracker module file and play it in R:

library(ProTrackR2)

mod <- pt2_read_mod("https://api.modarchive.org/downloads.php?moduleid=41529#elektric_funk.mod")

play(mod)

Code of Conduct

Please note that the ProTrackR2 project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.

Copy Link

Version

Install

install.packages('ProTrackR2')

Monthly Downloads

154

Version

0.1.1

License

GPL (>= 3)

Issues

Pull Requests

Stars

Forks

Maintainer

Pepijn de Vries

Last Published

November 21st, 2025

Functions in ProTrackR2 (0.1.1)

pt2_duration

Calculate the duration of the module
pt2_sample

Obtain sample data and info from a ProTracker module
pt2_render_options

Retrieve options for rendering
pt2_read_sample

Read and write ProTracker audio samples
pt2_pattern

Create or retrieve a pattern from a ProTracker module
pt2_render

Render ProTracker modules and other objects to a playable format
pt2_demo

Path to demonstration ProTracker module file
pt2_new_mod

Create a new (empty) ProTracker module
pt2_validate

Validate ProTrackR2 S3 class objects
pt2_new_pattern

Create a new ProTracker pattern
pt2_sample_to_audio

Coerce ProTracker sample to audio sample
pt2_finetune

Get or set ProTracker sample properties
$.pt2mod

Select and assign operators for ProTrackR2 S3 class objects
as_pt2cell

Convert object into a pt2cell or pt2celllist class object
pt2_length

Obtain ProTracker module information
pt2_cell

Select a cell from a ProTracker pattern table
ProTrackR2-package

ProTrackR2: Manipulate and Play 'ProTracker' Modules
pt2_read_mod

Read and write ProTracker modules
pt2_command

Extract effect commands from a ProTracker module
as_modplug_pattern

Format a ProTracker pattern conform OpenMPT specs
play

Play a ProTrackR2 class objects as audio
effect_commands

Effect commands (data.frame)
pt2_note_to_period

Get a corresponding period value from a note string
pt2_note

Extract a note from a ProTracker module
pt2_instrument

Extract or replace a sample index from a ProTracker pattern
format.pt2mod

Implementation of basic S3 methods