These functions set up the necessary objects to perform clustering with the respective algorithm. See details for more.

initiateHierarchicalClustering(
  object,
  variable_set,
  phase = NULL,
  scale = TRUE,
  force = FALSE,
  verbose = NULL
)

initiateKmeansClustering(
  object,
  variable_set,
  phase = NULL,
  scale = TRUE,
  force = FALSE,
  verbose = NULL
)

initiatePamClustering(
  object,
  variable_set,
  phase = NULL,
  scale = TRUE,
  force = FALSE,
  verbose = NULL
)

Arguments

object

A valid cypro object.

variable_set

Character value. Denotes the variable set of interest. Use getVariableSetNames() to obtain all names of currently stored variable sets in your object.

phase

Character or numeric. If character, the ordinal value referring to the phase of interest (e.g. 'first', 'second' etc.). referring to the phase of interest or 'all'. If numeric, the number referring to the phase.

If set to NULL takes the phase denoted as default with adjustDefault().

Ignored if the experiment design contains only one phase.

scale

Logical value. If set to TRUE (the default) all variables will be scaled before clustering is performed to ensure that all variables are weighted equally.

force

Logical value. Needs to be set to TRUE if you want to overwrite an already existing set up or already existing results.

verbose

Logical. If set to TRUE informative messages regarding the computational progress will be printed.

(Warning messages will always be printed.)

variables_subset

Character vector or NULL. Denotes the numeric variables the subsequent clustering steps will include which influences the clustering results.

If set to NULL all of them are chosen. You can prefix variables you do NOT want to influence the clustering with a '-'. (Saves writing if there are more variables you are interested in than variables you are not interested in.)

Use getNumericVariableNames() to obtain all valid input options.

Value

An updated version of the input cypro-object.

Details

The clustering initiation functions set up the S4 object that is used by cypro to do the clustering. Every downstream analysis function depends on the input you specify here. This means in particular the input for argument scale and the input for argument variables_subset. The latter denotes the variables on which the clustering will base on. Changing these might influence the clustering results. If you realize later on that you want to change the set up use the respective initiate*Clustering() function again and set argument force to TRUE in order to overwrite the current set up.

See also

getHclustConv(), getKmeansConv(), getPamConv()