This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var r =6; | |
macro "2D Gaussian Fit Tool - C00cT0f16GTbf16f" { | |
setBatchMode(1); | |
getCursorLoc(x, y, z, f); | |
while (f&16>0) { | |
Overlay.clear; | |
getCursorLoc(x, y, z, f); | |
makeRectangle(x-r,y-r,2*r,2*r); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// emoji from https://emojipedia.org/ | |
url="https://emojipedia-us.s3.dualstack.us-west-1.amazonaws.com/thumbs/120/whatsapp/273/face-with-medical-mask_1f637.png"; | |
hues=8; | |
open(url); | |
setBatchMode(1); | |
run("Duplicate...","title=temp"); | |
Color.setForeground("blue");floodFill(0, 0); | |
run("Size...", "width="+Image.width+" height="+Image.height+" depth="+hues+" constrain average interpolation=Bilinear"); | |
run("HSB Stack"); | |
Stack.getDimensions(width, height, channels, slices, frames); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
run("Boats"); | |
makeLut("#009100","#ccff42"); | |
function makeLut(a,b) { | |
a = Color.toArray(a); | |
b = Color.toArray(b); | |
reds=newArray(256); | |
greens=newArray(256); | |
blues=newArray(256); | |
for (i=0;i<reds.length;i++) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
macro "Better Wand Tool - C000T0f10BT7f10WTff10T" { | |
if (!isOpen("ROI Manager")) run("ROI Manager..."); | |
smoothness= call('ij.Prefs.get','bwt.selectSmoothness',3); | |
getCursorLoc(x, y, z, flags); | |
id=getImageID; | |
setBatchMode(1); | |
run("Select None"); | |
run("Duplicate...","title=a"); | |
run("Gaussian Blur...", "radius="+smoothness); | |
id2=getImageID; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//ImageJ macro making a tilted movie out of stack | |
//uses shear transform + rotation | |
//Eugene Katrukha katpyxa at gmail.com | |
requires("1.48h"); | |
sTitle=getTitle(); | |
sMovieTitle=sTitle+"_tilt_movie"; | |
setBatchMode(true); | |
//Dialog |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Collections of scripts harvested mainly from Pete, but also picked up from the forums | |
If you are starting with 0.2.0m4+ START HERE: https://petebankhead.github.io/qupath/2019/08/21/scripting-in-v020.html | |
TOC | |
Access objects in other project images.groovy - in later versions of 0.2.0M#, access the hierarchies of other images | |
Access other project images or data.groovy | |
Access project metadata.groovy - interact with user defined, per image metadata. Useful for sorting projects. |