README.md

fluoR

Calcium imaging methods produce massive datasets that require immense data manipulation, exploration, and summarizing. fluoR provides highly-accessible functions to address these issues for both inexperienced and seasoned R users to save researchers time. This package is catered to live-recorded fluorescence data, but works with any type of waveform data. A few functions include:

The Examples vignette explains these functions and more in greater detail. This can be viewed using browseVignettes('fluoR').

There is also a fluoR manual in Gitbook format that I will be regularly updating over the next few months.

Installation

### Install from Github
devtools::install_github('atamalu/fluoR', build_vignettes = TRUE)
library(fluoR)

Getting started

Since there is currently no ubiquitous way to analyze or format calcium imaging data, most of fluoR’s commands require the data frame to be in “fluoR format.” This is essentially a transposed time series data frame; where the times of recorded signals are in the first row or column, and the observed values of each trial are in the following rows or columns.

### Format data
df <- format_data(GCaMP)
### What does the median value of trials 1, 2, 3, and 4 look like?
head( summarize_trials(dataframe = df, trials = 1:4, summary.type = 'median') )
#>      Time summ.trials
#> 1 -3.9902     82.7735
#> 2 -3.9803     82.7890
#> 3 -3.9705     82.8170
#> 4 -3.9607     82.8565
#> 5 -3.9508     82.8985
#> 6 -3.9410     82.9365
### Where are the inflection points (peaks/valleys) in trial 1?
head( inflect_points(x = df$Trial1) )
#> [1] 0 0 2 0 0 0
### Where are the peaks in trial 1 with at least 10 decreasing values on 
head( find_peaks(xvals = df$Trial1, n.points = 10) )
#> [1]   8  27  44  78 100 122
### Transform raw input values into modified z-scores (using median & mad) for trial 1
head( z_score(xvals = df$Trial1, z.type = 'modified') )
#> [1] 0.5840183 0.4935366 0.4770854 0.5346646 0.6470813 0.7704654


atamalu/fluoR documentation built on Dec. 7, 2020, 4:48 a.m.