Skip to content

alextssheehan/LSEx.R

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LSEx.R

Lindenmayer System Explorer for R

A package designed to generate and export Lindenmayer systems (L-systems) in R.

This collection of functions was created as an R-based implementation of LSEx.m, created by Dr Michael Lindner & Prof. Doug Saddy. The functions will be updated over time, hopefully to include more features in-line with the functionality of the original MATLAB-based program, as well as any new features that may be useful. This particular implementation of LSEx was developed with the intention of the outputs being used as stimuli in artificial grammar learning tasks. These tasks have proved to be effective tools to assess implicit statistical learning and hierarchical structure processing (Schmid et al., 2023; Vender et al., 2019), and to drive bilingual experience-modulated changes to resting-state EEG functional connectivity (Sheehan et al., 2026).

Functions included

  • Lindenmayer system generator (lsex_gen())
    • Generates pre-defined or custom-configured L-systems using simple input and output specifications.
  • Lindenmayer system string exporter (lsexport_strings())
    • Exports the strings generated using lsex_gen() as .txt or .csv files.
  • Lindenmayer system lengths exporter (lsexport_lengths())
    • Exports the lengths of the iterations generated using lsex_gen() as a .txt file.
  • Lindenmayer system rules exporter (lsexport_rules())
    • Exports the rules used to generate the specified L-system as a .txt file.
  • !NEW! Lindenmayer system sub-string replacer (lsex_replace()) !NEW!
    • Searches for specified sub-strings in an lsex_gen() output and replaces them.
      • This function in particular may exhibit bugs or not work as intended. Further testing will be conducted to ensure stability.

Installing LSEx.R

LSEx.R can be installed using the following functions and packages from CRAN:

  • The install_github() function of the devtools package
install.packages("devtools")
library(devtools)
install_github("alextssheehan/LSEx.R")
  • The install_github() function of the remotes package, a lightweight version of devtools:
install.packages("remotes")
library(remotes)
install_github("alextssheehan/LSEx.R")
  • The githubinstall() function of the githubinstall package:
install.packages("githubinstall")
library(githubinstall)
githubinstall("LSEx.R")

License

This package is free and may be distributed and modified under the GNU General Public License (GPLv3). This package is distributed without warranty.

Current version

The current version of LSEx.R is v0.9.1 (new lsex_replace() function addition).

Updates & improvements

To view updates and improvements to the package, head to the NEWS file. To suggest new features or improvements, please register a 'new issue' in the Issues section using the 'enhancements' label. To register a bug or error in the code, use the 'bug' label.

Author

Dr Alex Sheehan
Contact: alexander.sheehan@reading.ac.uk

About

A collection of functions for generating and exporting Lindenmayer system (L-system) grammars in R.

Topics

Resources

License

Stars

0 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages