Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

loopState

Get PTSample loop state


Description

Determines whether a loop is specified for a PTSample object.

Usage

## S4 method for signature 'PTSample'
loopState(sample)

Arguments

sample

A PTSample object for which the loop state needs to be determined.

Details

The loop state is not explicitly stored in a PTSample object. It can be derived from the loopStart position and loopLength. This method is provided as a convenient method to get the state. Use either loopStart or loopLength to change the state.

Value

Returns a logical value indicating whether a loop is (TRUE) or isn't (FALSE) specified for the sample.

Author(s)

Pepijn de Vries

See Also

Other loop.methods: loopLength(), loopSample(), loopStart()

Examples

data("mod.intro")

## Get the loop status of sample number 1
## (it has a loop):
loopState(PTSample(mod.intro, 1))

## Get the loop status of sample number 2
## (it has no loop):
loopState(PTSample(mod.intro, 2))

ProTrackR

Manipulate and Play 'ProTracker' Modules

v0.3.7
GPL-3
Authors
Pepijn de Vries [aut, cre, dtc]
Initial release
2020-02-03

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.