Skip to content
François Simon edited this page Apr 29, 2024 · 10 revisions

Welcome to the aTrack wiki!

Installation

To use the stand-alone version of aTrack, first download it at https://zenodo.org/records/11075336. Then, extract the compressed file to the location of your choice. You can create a shortcut of the executable file aTrack.exe for easier ulterior use. To create a shortcut, select the aTrack.exe file, right click on it, and select create a shortcut. It will create a shortcut that you can move to any location.

Input file format

The data set to analyze needs to be in a csv format with rows that represent the peaks of the tracks and columns that must contain the following headers: ['POSITION_X', 'POSITION_Y', 'FRAME', 'TRACK_ID']. The columns 'POSITION_X' and 'POSITION_Y' must contain floats that represent the positions in the different dimensions of your track. 'FRAME' must contain floats or integers ordered with regard to the time points of the tracks. 'TRACK_ID' must contain integers that specify to which track the position belongs to. N/A values are not allowed.

Getting started

To use aTrack, double-click on the aTrack.exe file on the aTrack_GUI folder. The following window will appear: image

Click on Browse to select the csv file to analyze.

In the 'Analysis Type' menu, select the type of analyzis you wish to perform. image

Length: select the number of time steps to consider per track. Tracks that have less than the required number of time-steps will not be considered and longer tracks will be cut to match the length.

Analysis Types:

  • Fitting single tracks in Brownian motion
  • Fitting single tracks in confined motion
  • Fitting single tracks in directed motion
  • Fitting a population of tracks with multiple states

Fitting single tracks in Brownian motion

Fit single tracks to a diffusion model with localization error. If memory issues occur, split your data set into multiple arrays and perform a fitting on each array separately.

image

Arguments:

  • Initial loaclization error : Initial guess on the localization error (in the same unit as the length units given in the csv file).
  • Initial diffusion length : Initial guess on the diffusion length per step $d =\sqrt{2D\Delta t} with $D$ the diffusion coefficient and $\Delta t$ the frame time.
  • Fixed localization error : Fix the localization error to the initial guess if ticked.
  • number of epochs : Number of epochs for the model fitting.
  • Save path : name of the file to save the results of the analysis. The saved file will be a csv file with rows representing the individual tracks and columns Log_likelihood, LocErr, d for the associated log likelihood, localization error and diffusion length.

Fitting single tracks in confined motion

Fit single tracks to a model with diffusion plus confinement while still considering localization error. If memory issues occur, split your data set into multiple arrays and perform a fitting on each array separately.

image

Arguments:

  • Initial loaclization error : Initial guess on the localization error (in the same unit as the length units given in the csv file).
  • Initial diffusion length : Initial guess on the diffusion length per step $d =\sqrt{2D\Delta t} with $D$ the diffusion coefficient and $\Delta t$ the frame time.
  • Initial confinemet factor : Initial guess on the confinement factor which is proportional to the strength of the confinement. See https://doi.org/10.1101/2024.04.18.589798 for more details on the confinement factor.
  • Initial diffusion length of the potential well : Initial guess on the diffusion length of the potential well assuming the well can diffuse.
  • Fixed localization error : Fix the localization error to the initial guess if ticked.
  • number of epochs : Number of epochs for the model fitting.
  • Save path : name of the file to save the results of the analysis. The saved file will be a csv file with rows representing the individual tracks and columns Log_likelihood, LocErr, d, q, l for the associated log likelihood, localization error, diffusion length (of the particle), diffusion length of the potential well and confinement factor respectively.

Fitting single tracks in directed motion

Fit single tracks to a model with diffusion plus directed motion while still considering localization error. If memory issues occur, split your data set into multiple arrays and perform a fitting on each array separately.

image

Arguments:

  • Initial loaclization error : Initial guess on the localization error (in the same unit as the length units given in the csv file).
  • Initial diffusion length : Initial guess on the diffusion length per step $d =\sqrt{2D\Delta t} with $D$ the diffusion coefficient and $\Delta t$ the frame time.
  • Initial change rate of the velocity : Initial guess on change of velocity in x and y in distance unit per time step.
  • Initial velocity : Initial guess on the velocity of the directed motion at the first time point of the track. The velocity of the directed motion evolves proportionally to change rate of the velocity.
  • Fixed localization error : Fix the localization error to the initial guess if ticked.
  • number of epochs : Number of epochs for the model fitting.
  • Save path : name of the file to save the results of the analysis. The saved file will be a csv file with rows representing the individual tracks and columns Log_likelihood, LocErr, d, q, l and mean_speed for the associated log likelihood, localization error, diffusion length, change rate of the velocity, velocity (at the first time point of the track and mean velocity for the whole track respectively.

Fitting a population of tracks in multiple states

Fit models with multiple states and vary the number of states to determine which number of states is best suited to the data set and to retrieve the multi-state model parameters. More precisely, in a first fitting step, we estimate the parameters of individual tracks. We then cluster tracks with close parameters using a Gaussian mixture model to form Maximal number of states states whose parameters are the average of the parameters of their tracks. Then, multi-state fitting is performed on the full data set. the log likelihood is computed and stored and the state with the lowest impact on the likelihood is removed. The number of states is further reduced until the number of states of the model reaches the value Minimal number of states.

  • Fixed localization error : Fix the localization error to the initial guess if ticked.
  • number of epochs : Number of epochs for the model fitting.
  • Minimal number of states : Minimal number of states for which a model will be fitted.
  • Maximal number of states : Minimal number of states for which a model will be fitted.
  • Number of tracks considered per batch : number of tracks considered per batch. This value affects the speed of the method. A higher number allow for faster computation. If the number is too high it can decrease the speed due to memory issues.
  • Save path : name of the files to save the results of the analysis. One file will be saved for each model with a different number of states. The resulting csv files will contain the states (rows) and the parameters associated to each state: 'LocErr', 'd', 'q', 'l', 'type', 'fraction'. state: integer representing each state of the model. LocErr: localization error, d: diffusion length per step which relates to the diffusion coefficient $D$ and time step $\Delta t$ according to $D = \sqrt{2D\Delta t}$. q: evolution parameter which corresponds to the diffusion length of the potential well when the state is confined and which corresponds to the change per time step of the velocity when the state is directed (see type to know if the state is confined or directed). l: force of the anomalous diffusion parameter, in case of confinement it corresponds to the fraction of the distance between the particle and the center of the potential well crossed during 1 time step, in case of directed motion, it corresponds to the velocity of the directed motion (at the first time step of the tracks). type: Either 'Conf' if the state represents confined motion or 'Dir' if the state represents directed motion. fraction: Fraction of the particles in this state. Another csv file containing the likelihoods of each model is saved.

Initial parameters for the confined states and the directed states. See the sections Fitting single tracks in directed motion and Fitting single tracks in confined motion for more details about the directed and confined motion parameters.