import_optitrack_csv: Import csv files exported by the Optitrack system

View source: R/import_functions.R

import_optitrack_csvR Documentation

Import csv files exported by the Optitrack system

Description

import_optitrack_csv takes the filepath and filename of a .csv file containg motion capture data captured and exported using the Optitrack motion capture system. The .csv file is then imported and cleaned and returned as a tibble. All joint angles and global joint center positions are in abreviated names (e.g. left knee flexion = LKF, global Y coordinate of the right hip joint is RHY).
Please see the GitHub README.me for a more detailed description.

Usage

import_optitrack_csv(
  filename,
  keep_rotations = TRUE,
  keep_finger_coords = FALSE,
  keep_marker_coords = FALSE
)

Arguments

filename

Path and filename of a .csv file containg motion capture data from the Optitrack system

keep_rotations

A logical. Should columns with joint rotations be kept if they exist in the data? Defaults to TRUE

keep_finger_coords

A logical. Should finger coordinates be kept if they exist in the data? Defaults to FALSE

keep_marker_coords

A logical. Should marker coordinate be kept if they exist in the data? Columns with Bone Marker data will start with a "BM". Columna with Marker data will start with a "M". Defaults to FALSE

Value

A tibble containing joint angles and global joint center positions of the: toes, ankles, knees, hips, center of gravity, shoulders, elbows, and wrists.

Examples

path <- system.file("examples", "optitrack.csv", package = "mocapr")
import_optitrack_csv(path)

steenharsted/mocapr documentation built on Feb. 1, 2024, 1:49 p.m.