find_cuts: Find Cut Positions

View source: R/userFunctions.R

find_cutsR Documentation

Find Cut Positions

Description

Attempts to find a straight line between the timing marks and the traces(.bottom_image_cut) and a straight line between the traces and the writing at the top of the images(.top_image_cut)

Usage

find_cuts(
  imageMatrix,
  cutPercentage = 2,
  percentFromEdge = 2,
  percentEdgeForLeft = NULL,
  shortestAllowedSeqOfZeros = 25
)

Arguments

imageMatrix

imported with import_process_image() or an equivilent

cutPercentage

A bound for which the start and end is never found, could be a flare on the sides of the scanned image

percentFromEdge

used in find_peaks if you know there wont be a peak in a region

percentEdgeForLeft

passed into find peaks, if not specified (NULL), uses percentFromEdge for both left and right sides, if specified, percentFromEdge is defaulted to just the right side of the plot

shortestAllowedSeqOfZeros

smallest gap allowed to be found to consider the trace not intersecting the timing marks in pixels

Value

list of the top and bottom cuts, warnings are returned if exist


Bott-binc/magnetoPackage2020 documentation built on Oct. 12, 2024, 7:49 p.m.