example datasets in bactmap - veeninglab/BactMAP GitHub Wiki
For beginning users to be able to play around with the plotting
functions of BactMAP, I saved three example datasets in in a folder
you can download here.
These sets are the ssbB-set
(kindly donated
by my colleague Arnau), the
dnaX/ftsZ-set
and the ‘Van-FL
dataset’. Below you can find the documentation:
Dataset retrieved from movie previously published in Moreno-Gamez et
al., 2017
(pubMED).
Competence is induced with CSP, leading to expression of ssbB-GFP. The
timing between cells differs slightly. I used
SuperSegger to track
the cells in the original movie. After this, I used BactMAP to extract
the phylogeny. See the tutorial on
genealogy to see the ssbB-set
in action.
load("ssbB_meanfluo.rda")
A data frame with the following columns:
Column Name | Description |
---|---|
node |
the number of the node in the genealogy tree |
birth |
birthframe of this cell |
cell |
cell identifier. unique per frame. |
death |
death frame (or frame the cell divides) of this cell |
edgelength |
the time (in frames) of the cell division |
fluorsum |
the sum of the total fluorescence inside the cell. inherited from SuperSegger ('fluor sum' , see the SuperSegger Wiki) |
fluormean |
the mean of the total fluorescence inside the cell. inherited from SuperSegger ('fluor mean' , see the SuperSegger Wiki) |
fluorsum_D |
the sum of the fluorescence at cell division . inherited from SuperSegger ('fluor sum death' , see the SuperSegger Wiki) |
fluormean_D |
the mean of the total fluorescence at cell division. inherited from SuperSegger ('fluor mean death' , see the SuperSegger Wiki) |
parent |
the node of the parent of this cell |
child1 |
the cell number of the daughter cell of this cell |
child2 |
the cell number of the other daughter cell of this cell |
root |
the root of the genealogy tree. by default, this is 0. |
nodelabel |
the cell number corresponding to the node |
Moreno-Gámez, Stefany, et al. “Quorum sensing integrates environmental cues, cell density and cell history to control bacterial competence.” Nature communications 8.1 (2017): 854.
summary(ssbB_meanfluo)
## node cell birth death
## Min. : 1.00 Min. : 1.0 Min. : 1.00 Min. : 1.0
## 1st Qu.: 50.00 1st Qu.: 50.0 1st Qu.:17.00 1st Qu.:26.0
## Median : 99.00 Median : 99.0 Median :25.00 Median :39.0
## Mean : 99.48 Mean :100.5 Mean :24.57 Mean :32.5
## 3rd Qu.:149.00 3rd Qu.:150.0 3rd Qu.:36.00 3rd Qu.:40.0
## Max. :198.00 Max. :207.0 Max. :40.00 Max. :40.0
##
## edgelength fluorsum fluormean fluorsum_D
## Min. : 0.000 Min. : 47218 Min. : 457.5 Min. : 95546
## 1st Qu.: 3.000 1st Qu.: 65794 1st Qu.: 466.2 1st Qu.: 152536
## Median : 8.000 Median : 81324 Median : 470.8 Median : 340060
## Mean : 7.924 Mean :151942 Mean : 764.9 Mean : 354852
## 3rd Qu.:12.000 3rd Qu.:254545 3rd Qu.:1133.5 3rd Qu.: 460037
## Max. :31.000 Max. :492453 Max. :1886.3 Max. :1465046
##
## fluormean_D parent child1 child2
## Min. : 459.3 Min. :104.0 Min. : 10.0 Min. : 11.0
## 1st Qu.: 471.3 1st Qu.:125.0 1st Qu.: 56.5 1st Qu.: 57.5
## Median :1114.5 Median :149.0 Median :103.0 Median :104.0
## Mean :1045.4 Mean :149.3 Mean :104.6 Mean :105.6
## 3rd Qu.:1379.1 3rd Qu.:174.0 3rd Qu.:151.5 3rd Qu.:152.5
## Max. :2075.6 Max. :198.0 Max. :206.0 Max. :207.0
## NA's :103 NA's :103
## root nodelabel
## Min. :0 Min. : 0.00
## 1st Qu.:0 1st Qu.: 21.00
## Median :0 Median : 48.00
## Mean :0 Mean : 50.74
## 3rd Qu.:0 3rd Qu.: 78.00
## Max. :0 Max. :127.00
##
load("ssbB_phylos.rda")
A phylo
object
containing the genealogy information of this timelapse movie:
phylogenetic tree with 103 tips and 95 internal nodes.
Moreno-Gámez, Stefany, et al. “Quorum sensing integrates environmental cues, cell density and cell history to control bacterial competence.” Nature communications 8.1 (2017): 854.
summary(bactMAP::ssbB_phylos)
## Length Class Mode
## edge 394 -none- numeric
## tip.label 103 -none- character
## Nnode 1 -none- numeric
## root.label 1 -none- character
## node.label 95 -none- character
## edge.length 197 -none- numeric
## root.edge 1 -none- numeric
load("ssbB_network.rda")
iGRAPH
network dataset containing
the same information as ssbB_phylos
& ssbB_meanfluo
together
Moreno-Gámez, Stefany, et al. “Quorum sensing integrates environmental cues, cell density and cell history to control bacterial competence.” Nature communications 8.1 (2017): 854.
#requires("igraph")
library(igraph)
##
## Attaching package: 'igraph'
## The following objects are masked from 'package:stats':
##
## decompose, spectrum
## The following object is masked from 'package:base':
##
## union
summary(ssbB_network)
## IGRAPH 431b225 DN-- 198 197 --
## + attr: name (v/c), birth (e/n), death (e/n), edgelength (e/n),
## | fluorsum (e/n), fluormean (e/n), fluorsum_D (e/n), fluormean_D
## | (e/n), child1 (e/n), child2 (e/n)
plot(ssbB_network)
This short timelapse movie was taken for van Raaphorst, Kjos &
Veening, 2017.
I recently re-analyzed this dataset and saved the cell meshes, tracked
DnaX & FtsZ filaments separately. I also saved the output of
extr_OriginalCells()
of the TIFF data of the FtsZ channel combined with the cell meshes of
cell 4. If you want to play with the original data (TIFF files, Oufti
and ISBatch output), click
here. If you want to
see the data in action, go to the tutorial on time-lapse
data.
Cell meshes, retreived by importing Oufti segmentation output in
BactMAP using extr_Oufti()
.
load("DnaX_mesh.rda")
A data frame with the following columns:
Column Name | Description |
---|---|
X |
x-coordinate of cell outline point (pixels) |
Y |
y-coordinate of cell outline point (pixels) |
cell |
cell identifier. unique per frame. |
frame |
frame identifier. in this case, an image was taken every 20 seconds, so 1 frame corresponds to 20s. |
num |
number indicating the order of cell outline points (useful for plotting polygons) |
max.width |
maximum cell width in pixels |
length |
the point of cell length from pole 0 |
steplength |
the distance (over the length axis) of this cell outline point from the previous cell outline point |
max.length |
the maximum cell length of the given cell |
xy |
indicates whether it’s the right or the left side of the cell (inherited from oufti) |
area |
cell area in pixels^2 |
angle |
the angle of the cells length axis to the horizontal line of the image. |
Xmid |
the mid-point (pixel x-coordinate) of the cell |
Ymid |
the mid-point (pixel y-coordinate) of the cell |
X_rot |
the x-coordinate of the cell outline point (in pixels) when the cell length axis is horizontal, with mid-cell at (0,0) |
Y_rot |
the y-coordinate of the cell outline point (in pixels) when the cell length axis is horizontal, with mid-cell at (0,0) |
max_um |
the maximum cell length in micron |
maxwum |
the maximum cell width in micron |
Xrot_micron |
the x-coordinate of the cell outline point (in micron) when the cell length axis is horizontal, with mid-cell at (0,0) |
Yrot_micron |
the y-coordinate of the cell outline point (in micron) when the cell lenth axis is horizontal, with mid-cell at (0,0) |
van Raaphorst, Renske, Morten Kjos, and Jan-Willem Veening. “Chromosome segregation drives division site selection in Streptococcus pneumoniae.” Proceedings of the National Academy of Sciences 114.29 (2017): E5959-E5968.
summary(DnaX_mesh)
## X Y cell frame
## Min. : 28.25 Min. : 67.88 Min. : 1.00 Min. : 1.00
## 1st Qu.: 91.25 1st Qu.:108.13 1st Qu.: 9.00 1st Qu.: 49.00
## Median :127.09 Median :128.23 Median :16.00 Median : 94.00
## Mean :129.44 Mean :127.51 Mean :18.14 Mean : 93.32
## 3rd Qu.:167.75 3rd Qu.:146.84 3rd Qu.:22.00 3rd Qu.:138.00
## Max. :233.65 Max. :183.22 Max. :46.00 Max. :181.00
## num max.width length steplength
## Min. : 0.00 Min. :10.83 Min. : 0.000 Min. :-0.9323
## 1st Qu.:13.00 1st Qu.:13.09 1st Qu.: 7.041 1st Qu.: 0.9216
## Median :27.00 Median :13.74 Median :13.886 Median : 1.0025
## Mean :28.02 Mean :13.74 Mean :14.583 Mean : 1.0249
## 3rd Qu.:41.00 3rd Qu.:14.48 3rd Qu.:21.190 3rd Qu.: 1.1330
## Max. :85.00 Max. :15.58 Max. :45.955 Max. : 5.6841
## max.length xy area angle
## Min. :10.85 Min. :0.0 Min. :121.7 Min. :0.0000198
## 1st Qu.:24.94 1st Qu.:0.0 1st Qu.:238.5 1st Qu.:1.1230295
## Median :29.76 Median :0.5 Median :287.1 Median :1.6312324
## Mean :29.22 Mean :0.5 Mean :289.4 Mean :1.7271795
## 3rd Qu.:33.51 3rd Qu.:1.0 3rd Qu.:332.3 3rd Qu.:2.3366826
## Max. :45.96 Max. :1.0 Max. :486.1 Max. :3.1399158
## Xmid Ymid X_rot
## Min. : 40.87 Min. : 80.33 Min. :-20.194841
## 1st Qu.: 90.81 1st Qu.:112.39 1st Qu.: -6.773118
## Median :127.98 Median :125.13 Median : 0.009878
## Mean :129.48 Mean :127.52 Mean : 0.006536
## 3rd Qu.:173.38 3rd Qu.:144.25 3rd Qu.: 6.779854
## Max. :225.79 Max. :173.85 Max. : 20.194841
## Y_rot max_um maxwum
## Min. :-8.699684 Min. :0.7001 Min. :0.6993
## 1st Qu.:-5.892610 1st Qu.:1.6101 1st Qu.:0.8450
## Median :-0.032674 Median :1.9211 Median :0.8871
## Mean : 0.002581 Mean :1.8861 Mean :0.8872
## 3rd Qu.: 5.931830 3rd Qu.:2.1631 3rd Qu.:0.9344
## Max. : 8.699684 Max. :2.9664 Max. :1.0057
## Xrot_micron Yrot_micron
## Min. :-1.3035770 Min. :-0.5615646
## 1st Qu.:-0.4372048 1st Qu.:-0.3803680
## Median : 0.0006377 Median :-0.0021091
## Mean : 0.0004219 Mean : 0.0001666
## 3rd Qu.: 0.4376396 3rd Qu.: 0.3828996
## Max. : 1.3035770 Max. : 0.5615646
Spot trajectories of DnaX and FtsZ filaments in a time-lapse,
retrieved by importing ISBatch output using
extr_ISBatch()
.
load("DnaX_tracks.rda")
load("FtsZ_tracks.rda")
Both DnaX_tracks & FtsZ_tracks are data frames with the following columns:
Column Name | Description |
---|---|
x |
x-coordinate of detected DnaX/FtsZ spot |
y |
y-coordinate of detected DnaX/FtsZ spot |
cell |
cell identifier. unique per frame. |
frame |
frame identifier. in this case, an image was taken every 20 seconds, so 1 frame corresponds to 20s. |
max.width |
maximum cell width in pixels |
max.length |
the maximum cell length of the given cell |
l |
relative localization of DnaX on the length axis of the cell. |
d |
relative localization of DnaX on the width axis (diameter) of the cell |
trajectory |
identifier of the DnaX track |
trajectory_length |
the time (in frames) the trajectory could be followed |
displacement_sq |
the displacement of the molecule (in pixels, as calculated by ISBatch ) |
van Raaphorst, Renske, Morten Kjos, and Jan-Willem Veening. “Chromosome segregation drives division site selection in Streptococcus pneumoniae.” Proceedings of the National Academy of Sciences 114.29 (2017): E5959-E5968.
summary(DnaX_tracks)
## x y frame cell
## Min. : 37.31 Min. : 76.1 Min. : 1.00 Min. : 1.00
## 1st Qu.: 85.90 1st Qu.:107.4 1st Qu.: 49.00 1st Qu.: 9.00
## Median :116.31 Median :125.6 Median : 91.00 Median :16.00
## Mean :123.09 Mean :125.9 Mean : 91.25 Mean :18.15
## 3rd Qu.:161.98 3rd Qu.:144.5 3rd Qu.:133.00 3rd Qu.:23.00
## Max. :227.67 Max. :177.3 Max. :181.00 Max. :46.00
## l d max.width trajectory
## Min. :-14.6329 Min. :-6.3754 Min. :10.83 Min. : -1.0
## 1st Qu.: -0.9614 1st Qu.:-1.9099 1st Qu.:13.17 1st Qu.:100.8
## Median : 1.9133 Median :-0.3906 Median :13.90 Median :284.5
## Mean : 1.8945 Mean :-0.4696 Mean :13.82 Mean :286.7
## 3rd Qu.: 5.2385 3rd Qu.: 0.9774 3rd Qu.:14.53 3rd Qu.:471.0
## Max. : 17.0349 Max. : 5.5524 Max. :15.55 Max. :686.0
## max.length trajectory_length displacement_sq
## Min. :11.75 Min. : 1.00 Min. : 0.000000
## 1st Qu.:24.62 1st Qu.: 3.00 1st Qu.: 0.001589
## Median :29.78 Median : 8.00 Median : 1.234500
## Mean :29.26 Mean : 13.01 Mean : 2.754613
## 3rd Qu.:33.85 3rd Qu.: 17.00 3rd Qu.: 4.000000
## Max. :45.96 Max. :102.00 Max. :15.994000
summary(FtsZ_tracks)
## x y frame cell
## Min. : 30.16 Min. : 72.38 Min. : 1.00 Min. : 1.00
## 1st Qu.: 94.05 1st Qu.:110.34 1st Qu.: 46.00 1st Qu.:10.00
## Median :146.93 Median :128.14 Median : 88.00 Median :16.00
## Mean :139.12 Mean :124.81 Mean : 89.81 Mean :18.01
## 3rd Qu.:181.37 3rd Qu.:141.26 3rd Qu.:135.00 3rd Qu.:20.00
## Max. :229.33 Max. :176.05 Max. :181.00 Max. :46.00
## l d max.width trajectory
## Min. :-18.0765 Min. :-7.4016 Min. :10.83 Min. : -1
## 1st Qu.: -0.6594 1st Qu.:-3.0234 1st Qu.:13.30 1st Qu.: 629
## Median : 1.2287 Median :-0.4745 Median :13.79 Median :1524
## Mean : 1.0582 Mean :-0.2716 Mean :13.85 Mean :1597
## 3rd Qu.: 2.7943 3rd Qu.: 2.3553 3rd Qu.:14.52 3rd Qu.:2490
## Max. : 16.2050 Max. : 7.1052 Max. :15.58 Max. :3830
## max.length trajectory_length displacement_sq
## Min. :10.85 Min. : 1.0 Min. : 0.0000
## 1st Qu.:25.64 1st Qu.: 5.0 1st Qu.: 0.0240
## Median :30.28 Median :12.0 Median : 0.2020
## Mean :29.74 Mean :15.2 Mean : 0.8358
## 3rd Qu.:34.45 3rd Qu.:20.0 3rd Qu.: 0.7362
## Max. :45.96 Max. :93.0 Max. :15.9850
Pixel values of FtsZ intensities per cell, retrieved by importing the
FtsZ channel TIFF stack using extr_OriginalStack()
,
and then using the output and DnaX_mesh
to connect the pixels to the
meshes with extr_OriginalCells()
. Only cell number 4
is included in this dataframe.
load("TurnedCell4.rda")
A data frame with the following columns:
Column Name | Description |
---|---|
x |
x-coordinate of the pixel |
y |
y-coordinate of the pixel |
cell |
cell identifier. unique per frame. |
frame |
frame identifier. in this case, an image was taken every 20 seconds, so 1 frame corresponds to 20s. |
max.width |
maximum cell width in pixels |
max.length |
the maximum cell length of the given cell |
pointN |
number of specific pixel. unique per cell and frame |
values |
intensity of the pixel |
X_rot |
pixel x coordinate when the cell is turned so that the length axis is horizontal and mid-cell is at 0,0. |
Y_rot |
pixel y coordinate when the cell is turned so that the length axis is horizontal and mid-cell is at 0,0. |
xt |
the point marking one corner of the square pixel (x-coordinate) |
yt |
the point marking one corner of the square pixel (y-coordinate) |
area |
the cell area (pixel squared) |
van Raaphorst, Renske, Morten Kjos, and Jan-Willem Veening. “Chromosome segregation drives division site selection in Streptococcus pneumoniae.” Proceedings of the National Academy of Sciences 114.29 (2017): E5959-E5968.
bactMAP::bactKymo(TurnedCell4, timeD=TRUE, sizeAV=TRUE, mag="100x_DVMolgen")
## [[1]]
As the DnaX/FtsZ-set
, the Van-FL set
is a subset of a dataset
generated and analyzed for van Raaphorst, Kjos &
Veening, 2017.
I included this dataset in BactMAP as an example of a dataset with
objects
and two different
conditions
, so it is a good set to try out
functions as plotObjects()
or
plotOverlay()
. The dataset
contains 2 different cells: Wild Type (“WT”) S. pneumoniae and S.
pneumoniae lacking the gene mapZ (“DM”). These cells where treated
with fluorescent vancomycin and imaged. The septa were detected as
objects, the cells as meshes using Oufti
.
an object_relative
dataframe containing the coordinates
and shape descriptors of the fluorescent objects (septa as stained by
fluorescent vancomycin) in Wild Type pneumococcus, and a mesh
dataframe containing the coordinates and shape descriptors of the
pneumococcal cells.
#objects
VanFL_objWT
#mesh
VanFL_meshWT
van Raaphorst, Renske, Morten Kjos, and Jan-Willem Veening. “Chromosome segregation drives division site selection in Streptococcus pneumoniae.” Proceedings of the National Academy of Sciences 114.29 (2017): E5959-E5968
For more examples, see
plotObjects()
summary(VanFL_objWT)
## frame cell max.length obnum
## Min. :1.000 Min. : 1.0 Min. :17.92 Min. :1.000
## 1st Qu.:2.000 1st Qu.: 60.0 1st Qu.:24.74 1st Qu.:1.000
## Median :5.000 Median :155.0 Median :26.77 Median :1.000
## Mean :4.867 Mean :119.5 Mean :28.18 Mean :1.506
## 3rd Qu.:8.000 3rd Qu.:173.0 3rd Qu.:29.50 3rd Qu.:2.000
## Max. :9.000 Max. :189.0 Max. :44.45 Max. :4.000
## NA's :26 NA's :5
## num obpath obID max.width
## Min. : 1.0 Min. : 1.00 Length:3765 Min. :14.39
## 1st Qu.: 63.0 1st Qu.: 7.00 Class :character 1st Qu.:16.45
## Median :148.0 Median :14.00 Mode :character Median :17.03
## Mean :154.4 Mean :16.86 Mean :16.92
## 3rd Qu.:244.0 3rd Qu.:22.00 3rd Qu.:17.44
## Max. :328.0 Max. :84.00 Max. :18.61
## NA's :5 NA's :26
## Dum Lmid ob_out_x
## Min. :-5.93760 Min. :-1.047667 Min. :-1.55394
## 1st Qu.:-0.03004 1st Qu.:-0.095982 1st Qu.:-0.21668
## Median : 0.01509 Median : 0.008118 Median :-0.01836
## Mean :-0.04567 Mean :-0.028105 Mean :-0.03678
## 3rd Qu.: 0.07370 3rd Qu.: 0.072275 3rd Qu.: 0.18314
## Max. : 2.03162 Max. : 0.759431 Max. : 1.41061
## NA's :31 NA's :31 NA's :31
## ob_out_y pole1 pole2 max_um
## Min. :-0.87521 Min. :-1.4348 Min. :0.5784 Min. :1.157
## 1st Qu.:-0.20162 1st Qu.:-0.9520 1st Qu.:0.7986 1st Qu.:1.597
## Median : 0.04066 Median :-0.8639 Median :0.8639 Median :1.728
## Mean : 0.03150 Mean :-0.9095 Mean :0.9095 Mean :1.819
## 3rd Qu.: 0.27449 3rd Qu.:-0.7986 3rd Qu.:0.9520 3rd Qu.:1.904
## Max. : 0.75336 Max. :-0.5784 Max. :1.4348 Max. :2.870
## NA's :31 NA's :26 NA's :26 NA's :26
## maxwum
## Min. :0.9289
## 1st Qu.:1.0621
## Median :1.0993
## Mean :1.0924
## 3rd Qu.:1.1256
## Max. :1.2012
## NA's :26
bactMAP::plotRaw(meshdata=VanFL_meshWT)
an object_relative
dataframe containing the coordinates
and shape descriptors of the fluorescent objects (septa as stained by
fluorescent vancomycin) in pneumococcus where mapZ is replaced for a
chloramphenical resistance marker, and a mesh
dataframe
containing the coordinates and shape descriptors of the same
**pneumococcal cells. **
#objects
VanFL_objDM
#mesh
VanFL_meshDM
van Raaphorst, Renske, Morten Kjos, and Jan-Willem Veening. “Chromosome segregation drives division site selection in Streptococcus pneumoniae.” Proceedings of the National Academy of Sciences 114.29 (2017): E5959-E5968
For more examples, see
plotOverlay()
summary(VanFL_objDM)
## frame cell max.length obnum
## Min. : 1.000 Min. : 3.00 Min. :18.50 Min. :1.000
## 1st Qu.: 4.000 1st Qu.:25.00 1st Qu.:23.68 1st Qu.:1.000
## Median : 7.000 Median :40.00 Median :27.49 Median :1.000
## Mean : 6.588 Mean :37.15 Mean :29.50 Mean :1.763
## 3rd Qu.:10.000 3rd Qu.:52.00 3rd Qu.:35.72 3rd Qu.:2.000
## Max. :10.000 Max. :60.00 Max. :43.61 Max. :5.000
## NA's :51 NA's :3
## num obpath obID max.width
## Min. : 3.0 Min. : 1.00 Length:1908 Min. :15.13
## 1st Qu.: 64.0 1st Qu.: 8.00 Class :character 1st Qu.:17.14
## Median :137.0 Median :15.00 Mode :character Median :18.00
## Mean :141.8 Mean :17.33 Mean :18.09
## 3rd Qu.:220.0 3rd Qu.:24.00 3rd Qu.:19.29
## Max. :262.0 Max. :73.00 Max. :20.36
## NA's :3 NA's :51
## Dum Lmid ob_out_x
## Min. :-4.61623 Min. :-0.93076 Min. :-1.09986
## 1st Qu.:-0.05215 1st Qu.:-0.24524 1st Qu.:-0.22804
## Median : 0.02144 Median : 0.00473 Median :-0.03272
## Mean : 0.14133 Mean :-0.01610 Mean :-0.01446
## 3rd Qu.: 0.29018 3rd Qu.: 0.13257 3rd Qu.: 0.20792
## Max. : 5.52891 Max. : 1.09036 Max. : 1.45269
## NA's :54 NA's :54 NA's :54
## ob_out_y pole1 pole2 max_um
## Min. :-0.80697 Min. :-1.4076 Min. :0.5972 Min. :1.194
## 1st Qu.:-0.20679 1st Qu.:-1.1530 1st Qu.:0.7644 1st Qu.:1.529
## Median : 0.07488 Median :-0.8873 Median :0.8873 Median :1.775
## Mean : 0.06105 Mean :-0.9521 Mean :0.9521 Mean :1.904
## 3rd Qu.: 0.31968 3rd Qu.:-0.7644 3rd Qu.:1.1530 3rd Qu.:2.306
## Max. : 1.04965 Max. :-0.5972 Max. :1.4076 Max. :2.815
## NA's :54 NA's :51 NA's :51 NA's :51
## maxwum
## Min. :0.9769
## 1st Qu.:1.1066
## Median :1.1622
## Mean :1.1679
## 3rd Qu.:1.2451
## Max. :1.3144
## NA's :51
bactMAP::plotRaw(meshdata=VanFL_meshDM)