T
- public class Coloc_2<T extends RealType<T> & NativeType<T>> extends Object implements ij.plugin.PlugIn
Modifier and Type | Class and Description |
---|---|
protected class |
Coloc_2.BoundingBox |
protected class |
Coloc_2.MaskInfo |
protected static class |
Coloc_2.RoiConfiguration |
Modifier and Type | Field and Description |
---|---|
protected boolean |
autoSavePdf |
protected String |
Ch1Name |
protected String |
Ch2Name |
protected CostesSignificanceTest<T> |
costesSignificance |
protected boolean |
displayImages |
protected Histogram2D<T> |
histogram2D |
protected Img<T> |
img1 |
protected int |
img1Channel |
protected Img<T> |
img2 |
protected int |
img2Channel |
protected static int |
index1 |
protected static int |
index2 |
protected static int |
indexMask |
protected static int |
indexRegr |
protected static int |
indexRoi |
protected KendallTauRankCorrelation<T> |
kendallTau |
protected LiHistogram2D<T> |
liHistogramCh1 |
protected LiHistogram2D<T> |
liHistogramCh2 |
protected LiICQ<T> |
liICQ |
protected MandersColocalization<T> |
mandersCorrelation |
protected ArrayList<Coloc_2.MaskInfo> |
masks |
protected PearsonsCorrelation<T> |
pearsonsCorrelation |
protected static String |
PREF_KEY |
protected String[] |
regressions |
protected Coloc_2.RoiConfiguration |
roiConfig |
protected SpearmanRankCorrelation<T> |
SpearmanRankCorrelation |
Constructor and Description |
---|
Coloc_2() |
Modifier and Type | Method and Description |
---|---|
protected void |
addIfValid(Algorithm<T> a,
List<Algorithm<T>> list)
Adds the provided Algorithm to the list if it is not null.
|
protected static int |
clip(int val,
int min,
int max)
Clips a value to the specified bounds.
|
void |
colocalise(Img<T> image1,
Img<T> image2,
Coloc_2.BoundingBox roi,
Img<T> mask)
Call this method to run a whole colocalisation configuration, all selected
algorithms get run on the supplied images.
|
AnalysisResults<T> |
colocalise(Img<T> image1,
Img<T> image2,
Coloc_2.BoundingBox roi,
Img<T> mask,
List<ResultHandler<T>> extraHandlers)
Call this method to run a whole colocalisation configuration, all selected
algorithms get run on the supplied images.
|
protected RandomAccessibleInterval<T> |
createMaskImage(RandomAccessibleInterval<T> image,
RandomAccessibleInterval<BitType> mask,
long[] offset,
long[] size)
This method duplicates the given images, but respects ROIs if present.
|
protected void |
createMasksAndRois(Roi[] rois,
int width,
int height)
Creates appropriate data structures from the ROI information
passed.
|
protected void |
createMasksFromImage(ij.ImagePlus imp)
This method checks if the given ImagePlus contains any masks or ROIs.
|
protected boolean |
createMasksFromRoiManager(int width,
int height)
A method to fill the masks array with data based on the ROI manager.
|
protected Coloc_2.MaskInfo |
getBoundingBoxOfMask(Img<T> mask)
A method to get the bounding box from the data in the given image that is
above zero.
|
protected boolean |
hasValidRoi(ij.ImagePlus imp)
Returns true if a custom ROI has been selected, i.e if the current ROI does
not have the extent of the whole image.
|
boolean |
initializeSettings(ij.ImagePlus imp1,
ij.ImagePlus imp2,
int gdIndexMask,
int gdIndexRegr,
boolean gdAutoSavePdf,
boolean gdDisplayImages,
boolean gdDisplayShuffledCostes,
boolean gdUseLiCh1,
boolean gdUseLiCh2,
boolean gdUseLiICQ,
boolean gdUseSpearmanRank,
boolean gdUseManders,
boolean gdUseKendallTau,
boolean gdUseScatterplot,
boolean gdUseCostes,
int gdPsf,
int gdNrCostesRandomisations)
Programmatically initializes the colocalisation settings to match the given values.
|
void |
run(String arg0) |
boolean |
showDialog() |
static Roi[] |
split(Roi roi)
Splits a non overlapping composite ROI into its sub ROIs.
|
protected static final String PREF_KEY
protected Coloc_2.RoiConfiguration roiConfig
protected ArrayList<Coloc_2.MaskInfo> masks
protected String[] regressions
protected static int index1
protected static int index2
protected static int indexMask
protected static int indexRoi
protected static int indexRegr
protected String Ch1Name
protected String Ch2Name
protected int img1Channel
protected int img2Channel
protected PearsonsCorrelation<T extends RealType<T> & NativeType<T>> pearsonsCorrelation
protected LiHistogram2D<T extends RealType<T> & NativeType<T>> liHistogramCh1
protected LiHistogram2D<T extends RealType<T> & NativeType<T>> liHistogramCh2
protected SpearmanRankCorrelation<T extends RealType<T> & NativeType<T>> SpearmanRankCorrelation
protected MandersColocalization<T extends RealType<T> & NativeType<T>> mandersCorrelation
protected KendallTauRankCorrelation<T extends RealType<T> & NativeType<T>> kendallTau
protected Histogram2D<T extends RealType<T> & NativeType<T>> histogram2D
protected CostesSignificanceTest<T extends RealType<T> & NativeType<T>> costesSignificance
protected boolean displayImages
protected boolean autoSavePdf
public void run(String arg0)
run
in interface ij.plugin.PlugIn
public boolean showDialog()
public boolean initializeSettings(ij.ImagePlus imp1, ij.ImagePlus imp2, int gdIndexMask, int gdIndexRegr, boolean gdAutoSavePdf, boolean gdDisplayImages, boolean gdDisplayShuffledCostes, boolean gdUseLiCh1, boolean gdUseLiCh2, boolean gdUseLiICQ, boolean gdUseSpearmanRank, boolean gdUseManders, boolean gdUseKendallTau, boolean gdUseScatterplot, boolean gdUseCostes, int gdPsf, int gdNrCostesRandomisations)
public void colocalise(Img<T> image1, Img<T> image2, Coloc_2.BoundingBox roi, Img<T> mask) throws MissingPreconditionException
NB: This method returns void
for binary backwards compatibility
with old code which might invoke it. If you want access to the
AnalysisResults
directly, call
colocalise(Img, Img, Coloc_2.BoundingBox, Img, List)
with
null
for extraHandlers
.
image1
- image2
- roi
- mask
- MissingPreconditionException
public AnalysisResults<T> colocalise(Img<T> image1, Img<T> image2, Coloc_2.BoundingBox roi, Img<T> mask, List<ResultHandler<T>> extraHandlers) throws MissingPreconditionException
image1
- First image.image2
- Second image.roi
- Region of interest to which analysis is confined.mask
- Mask to which analysis is confined.extraHandlers
- additional objects to be notified of analysis results.MissingPreconditionException
protected Coloc_2.MaskInfo getBoundingBoxOfMask(Img<T> mask)
mask
- The image to look for "on" values inprotected void addIfValid(Algorithm<T> a, List<Algorithm<T>> list)
protected boolean hasValidRoi(ij.ImagePlus imp)
protected static int clip(int val, int min, int max)
protected void createMasksFromImage(ij.ImagePlus imp)
protected boolean createMasksFromRoiManager(int width, int height)
protected void createMasksAndRois(Roi[] rois, int width, int height)
Image<T>
.
In the end the members ROIs, masks and maskBBs will be
filled if ROIs or masks were found. They will be null
otherwise.protected RandomAccessibleInterval<T> createMaskImage(RandomAccessibleInterval<T> image, RandomAccessibleInterval<BitType> mask, long[] offset, long[] size) throws MissingPreconditionException
MissingPreconditionException
Copyright © 2015–2021 Fiji. All rights reserved.