Skip to contents

Inputs

Create the optimisation inputs

simulate_pvalues()
Simulate raw p-values
trial_success()
Create a trial success function
graph_constraint()
Create a graph constraint object for optimisation procedures
graph_constraint_free()
Create an unconstrained graph constraint

Advanced control

Control more advanced aspects of the global and local optimisation

multigrain_control()
Set parameters for graph optimisation
control_nsim_local() control_nsim_global()
Modify the number of simulations
control_local()
Modify local optimisation options
control_global()
Modify global optimisation options

Optimisation

Optimisation functions

graph_optimise()
Optimise graph-based multiple testing procedures

Post-processing

Work with an optimised graph

calc_power_pvals()
Calculate power for a graph-based multiple test procedure using p-values
is_graph_valid()
Check the validity of a graph-based MTP
graph_optimal_get_control()
Get the optimisation control

Plotting

Plotting functions

autoplot(<multigrain_graph_constraint>) plot(<multigrain_graph_constraint>)
Autoplot method for multigrain_graph_constraint objects
autoplot(<multigrain_graph_optimal>) plot(<multigrain_graph_optimal>)
Autoplot method for multigrain_graph_optimal objects

Helper functions

Other useful functions

calc_ncp()
Calculate non-centrality parameter
normalise_sum()
Normalise graph weights to sum to a target value
graph_random()
Generate random graph

Options

Options consulted by multigrain

multigrain_verbosity()
Multigrain verbosity

Data

multigrain objects used for examples and tests

graph_optimal_example
Optimised graph example