if(interactive() && ants_available()) {
ants <- load_ants()
img <- ants$image_read(ants$get_ants_data('mni'))
ants_plot(
img, nslices = 12, black_bg = FALSE,
bg_thresh_quant = 0.05, bg_val_quant = 1.0, axis = 2,
cbar = TRUE, crop = TRUE, reverse = TRUE, cbar_vertical = FALSE,
ncol = 4, title = "Axial view of MNI brain"
)
}
Run the code above in your browser using DataLab