gen3DNet | R Documentation |
This function creates a 3D network model relating two matrices. The columns of each matrix should represent two sets of objects, with the rows of both matrices corresponding to observations under the same circumstances. For example, the columns might be phosphoproteins and histones, and the rows might correspond to drugs. In this case, the data values would represent the transcription or GCP activation level in cells treated with different drugs.
gen3DNet(
left,
right,
nmf_nrun = 10,
k = NULL,
k_picker = max_ward_kl,
seed = 123456,
p_val_threshold = 1e-04,
out_folder = NULL,
verbose = TRUE
)
left |
Matrix of left objects |
right |
Matrix of right objects |
nmf_nrun |
Number of iterations to use for NMF |
k |
Number of clusters to use for NMF. This can be specified as a
|
k_picker |
Method for picking k. If unspecified, k values are compared using the KL-index of Ward clusterings based on euclidean distance. Possible values:
To learn more, use help() for each of these functions. |
seed |
Seed to use for NMF. |
p_val_threshold |
Threshold for significant p-values in PLSR. |
out_folder |
Folder used for outputting results. |
verbose |
Whether to print output (default TRUE). |
The final 3D network model consists of connections between the rows and both sets of columns, as follows:
Connections between the rows and the left columns. These are found using NMF (nonnegative matrix factorization). The data can contain negative values, as an antilog transformation is used internally. The number of NMF clusters can be specified, but otherwise it will be chosen automatically based on the value that gives the highest KL-index when using Ward hierarchical clustering. The connection weight between a given left column and row is the maximum basis value for the left column object. See the function generate_nmf_modules for further information.
Connections between the rows of the right and left columns. These are found using PLSR. The connection strength is the absolute value of the PLSR regression coefficient. See the function generate_plsr for more information.
library("gen3DNet")
histon_path <- system.file("extdata", "histon_data.csv", package="gen3DNet")
phospho_path <- system.file("extdata", "phospho_data.csv", package="gen3DNet")
result <- gen3DNet(
histon_path,
phospho_path,
nmf_nrun = 10,
p_val_threshold = 0.01,
# k_picker = max_cophenetic
# k_picker = kneedle_silhouette_consensus
# k_picker = kneedle_cophenetic
# k_picker = max_silhouette_consensus
# k_picker = max_cophenetic
# k_picker = max_ward_kl
k_picker = max_ward_kl
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.