Plot coefficients
Usage
plot_coefficient(
data,
style = "continuous",
positive_color = "#3d67a2",
negative_color = "#c82926",
neutral_color = "#cccccc",
bar_width = 0.7,
text_size = 3,
show_values = TRUE
)
Arguments
- data
Input data.
- style
Plotting style: "binary", "gradient", or "continuous".
- positive_color
Color for positive weights.
- negative_color
Color for negative weights.
- neutral_color
Color for weights near zero (used in "continuous" style).
- bar_width
Width of the bars.
- text_size
Size of the text for weight values.
- show_values
Logical, whether to show weight values on bars.
Examples
data("example_matrix")
network_table <- inferCSN(example_matrix, targets = "g1")
#> ℹ [2025-05-07 09:38:39] Running for <dense matrix>.
#> ℹ [2025-05-07 09:38:39] Checking input parameters.
#> ℹ [2025-05-07 09:38:39] Using 1 target(s).
#> ℹ [2025-05-07 09:38:39] Using L0 sparse regression model.
#> ℹ [2025-05-07 09:38:39] Using 1 core
#> ✔ [2025-05-07 09:38:39] Run done.
plot_coefficient(network_table)
plot_coefficient(network_table, style = "binary")