callback_base_report {GSgalgoR} | R Documentation

## Print basic info per generation

### Description

Print basic info per generation

### Usage

    callback_base_report (userdir, generation, pop_pool,
    pareto, prob_matrix, current_time)

### Arguments

`userdir` | the default directory used by 'galgo()' to store files
`generation` | a number indicating the number of iterations of the galgo algorithm
`pop_pool` | a `data.frame` with the solution vectors, number of clusters and their ranking.
`pareto` | the solutions found by Galgo across all generations in the solution space
`prob_matrix` | a `matrix` or `data.frame`. Must be an expression matrix with features in rows and samples in columns
`current_time` | an `POSIXct` object

### Value

Nothing.

### Examples

    # load example dataset

    library(breastCancerTRANSBIG)
    data(transbig)
    Train <- transbig
    rm(transbig)
    expression <- Biobase::exprs(Train)
    clinical <- Biobase::pData(Train)
    OS <- survival::Surv(time = clinical$t.rfs, event = clinical$e.rfs)
    # We will use a reduced dataset for the example
    expression <- expression[sample(1:nrow(expression), 100), ]

    # Now we scale the expression matrix
    expression <- t(scale(t(expression)))

    # Run galgo with base_report_callback assigned to the report_callback
    # hook-point
    GSgalgoR::galgo(generations = 5,
    population = 15,
    prob_matrix = expression,
    OS = OS,
    report_callback = callback_base_report
    )

[Package GSgalgoR version 1.2.1 Index]