MCPcopy Create free account
hub / github.com/daniel-e/rustml / main

Function main

examples/octave_plot.rs:6–18  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4use rustml::opencv::*;
5
6fn main() {
7 let o = builder()
8 .add("x = linspace(-10, 10, 80)")
9 .add("y = x.^2 + sin(x) .* (x .* x)")
10 .add("plot(x, y, 'linewidth', 2)")
11 .add("grid on")
12 .add("print -dpng '/tmp/example_plot.png'");
13
14 o.run("/tmp/example_plot.m").unwrap();
15 Window::new()
16 .show_image(&RgbImage::from_file("/tmp/example_plot.png").unwrap())
17 .wait_key();
18}
19

Callers

nothing calls this directly

Calls 6

from_fileFunction · 0.85
runMethod · 0.80
wait_keyMethod · 0.80
show_imageMethod · 0.80
builderFunction · 0.50
addMethod · 0.45

Tested by

no test coverage detected