plotCellsTime: Function to plot cell fluorescence from a TIFF over time.

View source: R/Plot_Image.R

plotCellsTimeR Documentation

Function to plot cell fluorescence from a TIFF over time.

Description

This function creates a cell tower or movie based on the pixel values and cell outlines of the cell. As input, it takes the 'rawdata_turned' dataframe output from extr_OriginalCells.

Usage

plotCellsTime(celdat,
              updown = T,
              movie = F,
              viridisoption = "magma",
              cellN,
              minf,
              maxf,
              outlines=FALSE,
              meshdata)

Arguments

celdat

TIFF and mesh outline data from a timelapse movie as it was obtained by running extr_OriginalCells.

updown

When updown==TRUE, a horizontal cell tower is made, otherwise, the cells are displayed left-right. movie==TRUE will overwrite this and return an animation instead.

movie

When movie == TRUE, an animation made with gganimate is returned.

viridisoption

The color palette used. The default palettes are part of the viridis color palettes (default = "magma").

cellN

The cell number or numbers to be displayed. When not indicated, a list of plots of all cells will be made.

minf

The minimum frame to be displayed.

maxf

The maximum frame to be displayed

outlines

when TRUE and meshdata is specified, the cell outlines are drawn over the pixels

meshdata

to be able to draw outlines, specify your mesh dataframe.

Value

A plot, list of plots or animation of a single cell's fluorescence over time.

Author(s)

Renske van Raaphorst

Examples

## Not run: 
##In the BactMAP example data, the raw data of one cell is saved as "TurnedCell4":
##Download this via https://veeninglab.com/f/example_datasets.zip

load("TurnedCell4.rda")
#to plot a left-right tower:
plotCellsTime(TurnedCell4, updown=F, viridisoption="inferno")

#or to create an animation:
plotCellsTime(TurnedCell4, movie=T)

## End(Not run)

vrrenske/shinyspots documentation built on Oct. 28, 2023, 12:26 p.m.