diff --git a/pom.xml b/pom.xml
index c2b0b85b5d9f898309cbd7356bac2f02a9692128..147ba62f201105d32cbd4fe226f471b08438eff9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -8,18 +8,18 @@
<parent>
<artifactId>pom-icy</artifactId>
<groupId>org.bioimageanalysis.icy</groupId>
- <version>2.0.0</version>
+ <version>2.1.0</version>
</parent>
<!-- Project Information -->
<artifactId>msd-track-processor</artifactId>
- <version>1.1.3</version>
+ <version>1.1.4-SNAPSHOT</version>
<packaging>jar</packaging>
<name>MSD Track Processor</name>
<description>Track Processor computing the MSD (Mean Square Displacement).</description>
- <url>http://icy.bioimageanalysis.org/plugin/track-processor-msd/</url>
+ <url>https://icy.bioimageanalysis.org/plugin/track-processor-msd/</url>
<inceptionYear>2020</inceptionYear>
<organization>
@@ -58,52 +58,31 @@
</properties>
- <profiles>
- <profile>
- <id>icy-plugin</id>
- <activation>
- <activeByDefault>true</activeByDefault>
- </activation>
- </profile>
- </profiles>
-
<!-- List of project's dependencies -->
<dependencies>
- <!-- The core of Icy -->
- <dependency>
- <groupId>org.bioimageanalysis.icy</groupId>
- <artifactId>icy-kernel</artifactId>
- <version>${icy-kernel.version}</version>
- </dependency>
-
<dependency>
<groupId>org.bioimageanalysis.icy</groupId>
<artifactId>jfreechart</artifactId>
- <version>${jfreechart.version}</version>
</dependency>
<dependency>
<groupId>net.sourceforge.jexcelapi</groupId>
<artifactId>jxl</artifactId>
- <version>${jxl.version}</version>
</dependency>
<dependency>
<groupId>org.bioimageanalysis.icy</groupId>
<artifactId>spot-detection-utilities</artifactId>
- <version>${spot-detection-utilities.version}</version>
</dependency>
<dependency>
<groupId>org.bioimageanalysis.icy</groupId>
<artifactId>distance-profiler</artifactId>
- <version>${distance-profiler.version}</version>
</dependency>
<dependency>
<groupId>org.bioimageanalysis.icy</groupId>
<artifactId>track-manager</artifactId>
- <version>${track-manager.version}</version>
</dependency>
</dependencies>
diff --git a/src/main/java/plugins/fab/trackmanager/processors/TrackProcessorMSD.java b/src/main/java/plugins/fab/trackmanager/processors/TrackProcessorMSD.java
index 2f1fac8c4a5f44ececd3659c1d1a424b21ea1038..0d469d39bea939dee1c9013a07f0e0e9950af943 100644
--- a/src/main/java/plugins/fab/trackmanager/processors/TrackProcessorMSD.java
+++ b/src/main/java/plugins/fab/trackmanager/processors/TrackProcessorMSD.java
@@ -238,7 +238,9 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (useRealScalesBox.isSelected())
{
int cnt = 0;
- int row = 0;
+ int row = 1; // Start from 1 because of table head
+ int cols = 0;
+
for (TrackSegment ts : trackPool.getTrackSegmentList())
{
// Better to allow partially clipped tracks otherwise we cannot get MSD for them (Stephane)
@@ -249,6 +251,10 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (msd.length > 0)
{
+ // Get max cols for the table
+ if (msd.length > cols)
+ cols = msd.length;
+
System.out.println("track " + cnt);
if (page != null)
@@ -268,11 +274,22 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
}
}
}
+
+ // Write table head
+ if (page != null) {
+ XLSUtil.setCellString(page, 0, 0, "frame");
+ if (cols > 0) {
+ for (int c = 0; c < cols; c++) {
+ XLSUtil.setCellString(page, c+1, 0, String.valueOf(c));
+ }
+ }
+ }
}
else
{
int cnt = 0;
- int row = 0;
+ int row = 1; // Start from 1 because of table head
+ int cols = 0;
for (TrackSegment ts : trackPool.getTrackSegmentList())
{
@@ -284,6 +301,10 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (msd.length > 0)
{
+ // Get max cols for the table
+ if (msd.length > cols)
+ cols = msd.length;
+
System.out.println("track " + cnt);
if (page != null)
@@ -302,6 +323,16 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
}
}
}
+
+ // Write table head
+ if (page != null) {
+ XLSUtil.setCellString(page, 0, 0, "frame");
+ if (cols > 0) {
+ for (int c = 0; c < cols; c++) {
+ XLSUtil.setCellString(page, c+1, 0, String.valueOf(c));
+ }
+ }
+ }
}
if (workbook != null)