View source: R/file_velocity.R
file_velocity | R Documentation |
A wrapper for the OpenPoseR functions velocity_x() and velocity_y() that makes it possible to directly pass a file name and or path including a file name to the function. Will create two CSV files with the infixes "velocity_x" and "velocity_y" in the given input directory as its output.
Can be used to call velocity_x() and velocity_y() for a CSV file (*.csv) created using the create_csv() function and (optinally but recommend) cleaned with either clean_data() or file_clean() without manually loading the data from the file into R first.
file_velocity(file, model, fps = 25)
file |
Name of CSV file (*.csv) or path to file including filename. |
model |
Specify which tracking model generated the data. Supply either body25, hands, or face. If no model is supplied the model will be guessed on the basis of the CSV file name provided (the file name contains model information when created using create_csv() from this package). |
fps |
Optional. Frames per second of original video file used for tracking. Defaults to 25. |
# Compute velocity for file "~/myvideo/myvideo_body25.csv" file_velocity("~/myvideo/myvideo_body25_cleaned.csv") # Compute velocity for file "~/myvideo/myvideo.csv" and manually specify model file_velocity("~/myvideo/myvideo_cleaned.csv", model = "body25")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.