| 2 | #include <matplot/matplot.h> |
| 3 | |
| 4 | int main() { |
| 5 | using namespace matplot; |
| 6 | |
| 7 | vector_1d data = {2, 4, 6, 7, 8, 7, 5, 2}; |
| 8 | stem(data); |
| 9 | |
| 10 | auto r1 = rectangle(2.5, 5.5, 2, 2); |
| 11 | r1->color("red"); |
| 12 | |
| 13 | auto r2 = rectangle(6.5, 4.5, 1, 1); |
| 14 | r2->fill(true); |
| 15 | r2->color({0.8f, 0.f, 0.f, 1.f}); |
| 16 | |
| 17 | show(); |
| 18 | return 0; |
| 19 | } |