Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 0cbfac0

Browse files
committedApr 4, 2019
Smooth PNG for sine wave
1 parent cd84513 commit 0cbfac0

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed
 

‎docs/sine.PNG

12.7 KB
Loading

‎examples/sine.exs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,16 @@ defmodule Sine do
77

88
def target,
99
do: [
10-
[:set, :term, :png, :size, '512,256', :font, "/Library/Fonts/FiraCode-Medium.ttf", 12],
10+
[:set, :term, :pngcairo, :size, '512,256' ,:font, "Fira Sans"],
1111
[:set, :output, png()]
1212
]
1313

1414
def commands,
1515
do: [
16-
~w(set style line 1 lw 2 lc '#732C7B')a,
16+
~w(set style line 1 linecolor rgb '#77216F' linetype 1 linewidth 2)a,
17+
~w(unset xzeroaxis)a,
18+
~w(unset yzeroaxis)a,
19+
~w(set ytics -1,1)a,
1720
[
1821
:plot,
1922
'sin(x)',

0 commit comments

Comments
 (0)
Please sign in to comment.