{"name":"napari-gemspa","display_name":"GEMspa","visibility":"public","icon":"","categories":[],"schema_version":"0.2.0","on_activate":null,"on_deactivate":null,"contributions":{"commands":[{"id":"napari-gemspa.get_reader","title":"Open data with GEMspa","python_name":"napari_gemspa._reader:napari_get_reader","short_title":null,"category":null,"icon":null,"enablement":null},{"id":"napari-gemspa.write_points","title":"Save points layer data with GEMspa","python_name":"napari_gemspa._writer:write_points","short_title":null,"category":null,"icon":null,"enablement":null},{"id":"napari-gemspa.write_tracks","title":"Save tracks layer data with GEMspa","python_name":"napari_gemspa._writer:write_tracks","short_title":null,"category":null,"icon":null,"enablement":null},{"id":"napari-gemspa.make_gemspa_plugin","title":"Make GEMspa plugin","python_name":"napari_gemspa._gemspa_plugin:GEMspaPlugin","short_title":null,"category":null,"icon":null,"enablement":null}],"readers":[{"command":"napari-gemspa.get_reader","filename_patterns":["*.txt","*.csv","*.tsv"],"accepts_directories":false}],"writers":[{"command":"napari-gemspa.write_points","layer_types":["points"],"filename_extensions":[".txt",".csv",".tsv"],"display_name":""},{"command":"napari-gemspa.write_tracks","layer_types":["tracks"],"filename_extensions":[".txt",".csv",".tsv"],"display_name":""}],"widgets":[{"command":"napari-gemspa.make_gemspa_plugin","display_name":"GEMspa","autogenerate":false}],"sample_data":null,"themes":null,"menus":{},"submenus":null,"keybindings":null,"configuration":[]},"package_metadata":{"metadata_version":"2.1","name":"napari-gemspa","version":"0.0.4","dynamic":null,"platform":null,"supported_platform":null,"summary":"A plugin for analysis of single particle tracking experiments","description":"# napari-gemspa\n\nThis plugin provides for analysis tools for data from single particle tracking experiments. It provides an interface for particle localization and tracking using [trackpy](http://soft-matter.github.io/trackpy/dev/index.html). It also allows for import of tracking data from Mosaic and Trackmate. These files must be tab/comma delimited text files. It provides an option to exclude particles/tracks masked with a labels layer.\n\nThere are 5 tabs available in the plugin, following the workflow of data analysis:\n\n1) **New/Open**: open nd2/tiff time-lapse movie files and/or import a tracks layer (from Mosaic, Trackmate or napari-gemspa saved tracks layer)\n2) **Locate**: locate particles with trackpy\n3) **Link**: link particles with trackpy\n4) **Filter Links**: filter links with trackpy\n5) **Analyze**: Perform analysis on tracks from a tracks layer (can be from imported file from step 1 or layer created in step 3)\n\n**Detailed description of features:**\n\n1) **New/Open**\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/1_1.png)\n\n**Add layer** button will create a blank 2D (no time dimension) layer that is the same height/width as the currently selected image layer. Alternatively, a labeled mask can be opened from a file. The labels layer can be used to provide a mask for excluding areas of the image from analysis.\n\nTrack files from other software or previously saved by GEMspa can also be imported in this pane. Only tab/comma (.csv/.txt/.tsv) delimited text files are allowed.\n\n**GEMspa** expects these columns in the header: ['track_id', 'frame', 'z', 'y', 'x']\n\n**Mosaic** expects these columns in the header: ['Trajectory', 'Frame', 'z', 'y', 'x']\n\n**Trackmate** expects these columns in the header: ['TRACK_ID', 'FRAME', 'POSITION_Z', 'POSITION_Y', 'POSITION_X'],\n* 3 rows will be skipped for Trackmate files (assumes data begins at the 4th row after the header)\n\n**Trackpy** expects these columns in the header: ['particle', 'frame', 'z', 'y', 'x']\n\n_(All columns are case and order insensitive)_\n\n2) **Locate**\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/2_1.png)\n\nIn this tab, adjust the parameters and perform particle localization with [trackpy.locate](http://soft-matter.github.io/trackpy/dev/generated/trackpy.locate.html#trackpy.locate). To first test out parameters on a single frame, check the \"Process only current frame\" checkbox. Please refer to the trackpy documentation for more details on parameters.\n\nAfter localization is performed, a new points layer will be created and particles will be shown circled in red. In the example, we have used a labels layer to exclude particles outside an ROI (this is optional):\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/2_2.png)\n\nIn addition, the mass histogram and subpixel bias histograms will be shown for help with adjusting the mass and diameter parameters:\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/2_3.png)\n\n3) **Link**\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/3_1.png)\n\nIn this tab, adjust parameters and perform linking with [trackpy.link](http://soft-matter.github.io/trackpy/dev/generated/trackpy.link.html). Once linking is performed a new tracks layer will be added. Please refer to the trackpy documentation for more details on parameters.\n\nIn addition, scatter plots of mass vs. size and mass vs. eccentricity, as well as the track lengths histogram are shown for help with filtering tracks. (next step)\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/3_2.png)\n\n4) **Filter**\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/4_1.png)\n\nIn this tab, adjust parameters and filter links from trackpy output. After filtering, a new layer will be added to napari with the filtered tracks and the same plots as shown in step 4 will be displayed.\n\n5) **Analyze**\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_1.png)\n\nIn this tab, adjust parameters and perform analysis. You may process all tracks or enter a track id and deselect the \"Process all tracks\" check box. Enter the appropriate parameters for converting pixels to microns and the time lag (in seconds) between frames of the movie. \n\nGEMspa will calculate the effective diffusion coefficient (D) for each track based on the mean squared displacement values (MSD) for each time-lag using this equation:\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_2.png)\n\nThis is the diffusion coefficient with the assumption of Brownian motion. GEMspa will also calculate the generalized diffusion coefficient and anomalous exponent using this equation:\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_3.png)\n\nThe fitting is performed on a log-log scale where the slope corresponds to the anomalous exponent (alpha):\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_4.png)\n\n**Definition of terms:**\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_5.png)\n\nThis review: [Manzo et al](https://pubmed.ncbi.nlm.nih.gov/26511974/) is useful for learning more about these and other analysis methods.\n\n**Min track len for fit**: all tracks less than this length will be excluded from calculations of effective diffusion coefficient and anomalous exponent.\n\n**Max time lag for fit**: GEMspa will fit the MSD up to the max time-lag entered here. (in frames)\n\n**Fit with error term**: check this box to allow a y-intercept when fitting for effective diffusion coefficient:\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_6.png)\n\nCheck these papers by [Martin, et al](https://www.sciencedirect.com/science/article/pii/S0006349502739714) and [Xavier Michalet](https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3055791/) for some information on fitting MSD with localization error.\n\n**Rainbow tracks**\n\nGEMspa can output a plot where the tracks are colored by any of the listed quantities. Check each box that you would like to see. \n\nFor the effective diffusion coefficient and anomalous exponent, set the Min/Max cutoffs for the track color map. Any tracks at or below the minimum will be colored with the minimum color (blue). Any tracks at or above the maximum will be colored with the maximum color (red).\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_10.png)\n\n**Plots**\n\nGEMspa will also output summary plots including:\n* Ensemble average MSD shown on linear and log-scale with results from fitting the MSD vs time-lag data from the ensemble average MSD.\n* Track length histogram, Radius of gyration (for full track lengths) histogram, Scatter plot of track length vs. radius of gyration\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_7.png)\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_8.png)\n\n**Tracks data table**\n\nGEMspa will output a table of data in a new pop-up window with data for each track. This table will only show one line for each track (not one line for every particle position) and it will output the following data:\n* track_id\n* frame_start\n* frame_end\n* radius_gyration: radius of gyration for the full track length (See [Elliot et al](https://doi.org/10.1039/c0cp01805h))\n* track_length\n* D: effective diffusion coefficient\n* E: y-intercept for the fit of MSD for D\n* r_sq (lin): R-squared value for goodness-of-fit for the fit of MSD vs time-lag\n* K: generalized diffusion coefficient\n* a: anomalous exponent (alpha)\n* r_sq (log): R-squared value for goodness-of-fit for the fit of log-log MSD vs. time-lag\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_9.png)\n\n**New tracks layer**\n\nGEMspa will add a new tracks layer and save all data for each track in the properties of the tracks layer. Save the tracks layer to obtain a tab/comma-delimited text file with all analysis results. The data included for each track is:\n* track_id\n* frame\n* y: y position in pixels\n* x: x position in pixels\n* frame_start\n* frame_end\n* y (microns): y position in microns\n* x (microns): x position in microns\n* tau: time-lag in seconds\n* MSD: mean squared displacement \n* t: time in seconds from start of track\n* step_size\n* radius_gyration: radius of gyration at each time point of track (See [Elliot et al](https://doi.org/10.1039/c0cp01805h))\n* track_length\n* D: effective diffusion coefficient\n* E: y-intercept for the fit of MSD for D\n* r_sq (lin): R-squared value for goodness-of-fit for the fit of MSD vs time-lag\n* K: generalized diffusion coefficient\n* a: anomalous exponent (alpha)\n* r_sq (log): R-squared value for goodness-of-fit for the fit of log-log MSD vs. time-lag\n\nTo extract this data, save the layer as a tab or comma delimited text file (txt/tsv/csv). GEMspa will save all track information.\n\n**Analysis for a single track**\n\nGEMspa also provides the option to select a single track and output analysis results. Detailed information is shown for the selected track, including a plot of the radius of gyration at each time point and a plot of the track itself. \n\nHere is an example:\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_11.png)\n\n![My Image](https://raw.githubusercontent.com/liamholtlab/napari-gemspa/main/screen_shots/5_12.png)\n\n\n","description_content_type":"text/markdown","keywords":null,"home_page":"https://github.com/liamholtlab/napari-gemspa","download_url":null,"author":"Sarah Keegan","author_email":"sarah.keegan@nyulangone.org","maintainer":null,"maintainer_email":null,"license":"BSD-3-Clause","classifier":["Development Status :: 2 - Pre-Alpha","Framework :: napari","Intended Audience :: Developers","License :: OSI Approved :: BSD License","Operating System :: OS Independent","Programming Language :: Python","Programming Language :: Python :: 3","Programming Language :: Python :: 3 :: Only","Programming Language :: Python :: 3.8","Programming Language :: Python :: 3.9","Programming Language :: Python :: 3.10","Topic :: Scientific/Engineering :: Image Processing"],"requires_dist":["numpy","magicgui","qtpy","pandas","napari","scikit-image","gemspa-spt","matplotlib","trackpy","nd2","tox ; extra == 'testing'","pytest ; extra == 'testing'","pytest-cov ; extra == 'testing'","pytest-qt ; extra == 'testing'","napari ; extra == 'testing'","pyqt5 ; extra == 'testing'"],"requires_python":">=3.8","requires_external":null,"project_url":["Bug Tracker, https://github.com/liamholtlab/napari-gemspa/issues","Documentation, https://github.com/liamholtlab/napari-gemspa#README.md","Source Code, https://github.com/liamholtlab/napari-gemspa","User Support, https://github.com/liamholtlab/napari-gemspa/issues"],"provides_extra":["testing"],"provides_dist":null,"obsoletes_dist":null},"npe1_shim":false}