set histogram bins image to image metric

antsrMetricSetNumberOfHistogramBins(metric, nBins)

Arguments

metric

an 'antsrMetric' of type 'MattesMutualInformation' or 'JointHistogramMutualInformation'

nBins

number of bins (minimum is 5 even for binary data)

Examples

x <- antsImageRead(getANTsRData("r16"))
y <- antsImageRead(getANTsRData("r30"))
metric <- antsrMetricCreate(x, y, type = "MattesMutualInformation")
antsrMetricSetNumberOfHistogramBins(metric, 12)