Skip to content

Latest commit

 

History

History
52 lines (37 loc) · 1.24 KB

README.md

File metadata and controls

52 lines (37 loc) · 1.24 KB

SURGE

The SURGE package streamlines importing of 3D landmark data from Stratovan Checkpoint into R for analysis.

Installation

You can install the development version of SURGE from GitHub with:

# install.packages("devtools")
devtools::install_github("rnfelice/SURGE")

Basic Usage

You can import your .pts files from Checkpoint into a 3D array. You need a list of .pts files and a csv file containing information about the start and end of each semilandmark curve and how many points to retain from each

#import table defining curves
curve_table <- read_csv("croc_curves.csv")
#identify the folder where your pts files are
ptsfolder <- "~/Crocs/pts"
#import the pts file names
ptslist <- dir(ptsfolder, pattern='.pts', recursive=F)

Then use the function create_curve_info to define your curves in a Morpho-friendly format

my_curves <- create_curve_info(curve_table, n_fixed = 102)

And then use that curve info to import the data and make all the curves have the same number of points

setwd(ptsfolder)
subsampled.lm <- import_chkpt_data(ptslist, my_curves, subsampl = TRUE)