quick_plot_3d_with_labels/quick_plot_3d_with_labels.rs
1use plotting::{Figure, quick_plot_3d_with_labels};
2use std::path::Path;
3
4fn main() {
5 // Create the figure.
6 let fig: Figure = quick_plot_3d_with_labels(
7 [1.0, 2.0, 10.0],
8 [1.0, 4.0, 9.0],
9 [2.0, 5.0, 10.0],
10 "x",
11 "y",
12 "z",
13 "z vs. x and y",
14 );
15
16 // Save the figure so it can be displayed right below this example.
17 fig.save_inline_html(Path::new("book/src/figures/quick_plot_3d_with_labels.html"));
18
19 // Alternatively, you can show the figure in a web browser.
20 // fig.show();
21}