Class SubtractMean
- All Implemented Interfaces:
Provider<Channel>,ProviderAsStack
Subtracts the mean intensity (of the entire channel or a masked portion thereof) from every
voxel.
This class extends UnaryWithMaskBase to perform mean subtraction on a channel,
optionally restricted to a masked region.
- Author:
- Owen Feehan
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ChannelcreateFromMaskedChannel(Channel channel, Mask mask) Creates a newChannelfrom the input channel and mask.booleanWhether to subtract the mean only from voxels within the mask.voidsetSubtractFromMaskOnly(boolean subtractFromMaskOnly) Whether to subtract the mean only from voxels within the mask.Methods inherited from class org.anchoranalysis.plugin.image.bean.channel.provider.mask.UnaryWithMaskBase
createFromChannel, getMask, setMaskMethods inherited from class org.anchoranalysis.image.bean.provider.ChannelProviderUnary
get, getChannel, setChannelMethods inherited from class org.anchoranalysis.image.bean.provider.ChannelProvider
getAsStackMethods inherited from class org.anchoranalysis.bean.initializable.InitializableBean
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitializationMethods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
SubtractMean
public SubtractMean()
-
-
Method Details
-
createFromMaskedChannel
Description copied from class:UnaryWithMaskBaseCreates a newChannelfrom the input channel and mask.- Specified by:
createFromMaskedChannelin classUnaryWithMaskBase- Parameters:
channel- the inputChannelmask- theMaskto apply to the channel- Returns:
- a new
Channelcreated from the input channel and mask
-
isSubtractFromMaskOnly
public boolean isSubtractFromMaskOnly()Whether to subtract the mean only from voxels within the mask.If true, only voxels within the mask are modified. If false, all voxels in the channel are modified.
-
setSubtractFromMaskOnly
public void setSubtractFromMaskOnly(boolean subtractFromMaskOnly) Whether to subtract the mean only from voxels within the mask.If true, only voxels within the mask are modified. If false, all voxels in the channel are modified.
-