This function will take the data.frame of predictors and predict the ICH voxels from the model chosen.

ich_predict(
  df,
  nim,
  model = c("rf", "logistic", "big_rf"),
  verbose = TRUE,
  native = TRUE,
  native_img = NULL,
  transformlist = NULL,
  interpolator = NULL,
  native_thresh = 0.5,
  shiny = FALSE,
  model_list = NULL,
  smoothed_cutoffs = NULL,
  outfile = NULL,
  ...
)

Arguments

df

data.frame of predictors. If multiplier column does not exist, then ich_candidate_voxels will be called

nim

object of class nifti, from make_predictors

model

model to use for prediction, either the random forest (rf) or logistic

verbose

Print diagnostic output

native

Should native-space predictions be given?

native_img

object of class nifti, which is the dimensions of the native image

transformlist

Transforms list for the transformations back to native space. NOTE: these will be inverted.

interpolator

Interpolator for the transformation back to native space

native_thresh

Threshold for re-thresholding binary mask after interpolation

shiny

Should shiny progress be called?

model_list

list of model objects, used mainly for retraining but only expert use.

smoothed_cutoffs

A list with an element mod.dice.coef, only expert use.

outfile

filename for output file. We write the smoothed, thresholded image. If native = TRUE, then the file will be native space, otherwise in registered space

...

Additional options passsed to ich_preprocess

Value

List of output registered and native space prediction/probability images

See also