# NOT RUN {
### many of the functions in this package are interconnected so the
### easiest way to learn to use the package is by working through the vignette,
### which is available at ajpete.com/software
#general example illustrating some of the main functions
#see the vignette for additional direction on using all of the functions
#and the help pages for the specific functions for details on using each function
#existing folder to save results (update this to an existing folder on your computer)
outputFolder = "scalpelResults"
#location on computer of raw data in R package to use
rawDataFolder = gsub("Y_1.rds", "", system.file("extdata", "Y_1.rds", package = "scalpel"))
#video height of raw data in R package
videoHeight = 30
#run SCALPEL pipeline
scalpelOutput = scalpel(outputFolder = outputFolder, rawDataFolder = rawDataFolder,
videoHeight = videoHeight)
#summarize each step
summary(scalpelOutput, step = 0)
summary(scalpelOutput, step = 1)
summary(scalpelOutput, step = 2)
summary(scalpelOutput, step = 3)
#plot the spatial and temporal components
plotResults(scalpelOutput = scalpelOutput)
#plot a summary of the video with the found neurons outlined
plotVideoVariance(scalpelOutput = scalpelOutput, neuronSet = "Afilter")
#plot the frames with the most fluorescence for each found neuron
plotBrightest(scalpelOutput = scalpelOutput, AfilterIndex = 1)
plotBrightest(scalpelOutput = scalpelOutput, AfilterIndex = 2)
plotBrightest(scalpelOutput = scalpelOutput, AfilterIndex = 3)
#if you want to use results from a previous session,
#use "getScalpel" to read in previous results
scalpelOutputCopy = getScalpel(outputFolder = outputFolder)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab