How to draw a graph that looks wonky(like hand drawn)

How to draw a graph that looks wonky(like hand drawn)



How would you draw a graph in latex that looks like below?
Something that looks almost hand drawn but still Latex generated.



desired output



Please note that I do not care about axes labels in this question.



I have included the graph template code below, where I want to draw such graph.


documentclassarticle
usepackage[margin=0.5in]geometry
usepackagepgfplots
renewcommandthesectionarabicsection
usepackagemathtools
usepackagecancel
usepackagepgfplots
usepackageamsmath
newtheoremtheoremTHEOREM
newtheoremproofPROOF
usepackagetikz
usepackageamssymb
usetikzlibrarypatterns
usepgfplotslibraryfillbetween
newenvironmenttightcenter
setlengthtopsep0pt
setlengthparskip0pt
begincenterendcenter
begindocument
% !TeX spellcheck = en_GB
begintikzpicture
beginaxis[
axis lines=middle,
grid=major,
%ticks=none,
xmin=-0.4,
xmax=6.5,
ymin=-1,
ymax=11,
xtick=0,1,2,3,4,5,6,
ytick=0,2.5,5,7.5,10,
height=9cm,
width=12cm,
axis line style=shorten >=-10pt, shorten <=-10pt,
ylabel style=
anchor=south,
at=(ticklabel* cs:1.0),
yshift=10pt
,
ylabel=y,
xlabel style=
anchor=west,
at=(ticklabel* cs:1.0),
xshift=10pt
,
xlabel=x,
axis line style=shorten >=-10pt, shorten <=-10pt,
yticklabel style=
fill=white,
%yshift=10pt,
,
xticklabel style=
%xshift=10pt,
fill=white

]
endaxis
endtikzpicture
enddocument



Thank you





Maybe this question is of interest?
– Max
Aug 24 at 2:11





Take a look at these questions with excellent answers: (1) tex.stackexchange.com/questions/74878/… (2) tex.stackexchange.com/questions/95322/…
– Tom
Aug 24 at 8:27





1 Answer
1



Here is a proposal: build up list and plot it smoothly. Of course, you can adjust the step (it is 0.5 in the example below) and the amplitude (1.5 in the example below).


documentclassarticle
usepackage[margin=0.5in]geometry
usepackagepgfplots
renewcommandthesectionarabicsection
usepackagemathtools
usepackagecancel
usepackagepgfplots
usepackageamsmath
newtheoremtheoremTHEOREM
newtheoremproofPROOF
usepackagetikz
usepackageamssymb
usetikzlibrarypatterns
usepgfplotslibraryfillbetween
newenvironmenttightcenter
setlengthtopsep0pt
setlengthparskip0pt
begincenterendcenter
begindocument
% !TeX spellcheck = en_GB
foreach X [count=Y] in 0,0.5,...,6
ifnumY=1
pgfmathsetmacromyrnd10*rnd
xdefmyrndmyrnd
xdefLst(X,myrnd)
else
pgfmathsetmacromyrndmyrnd+1.5*(rnd-0.5)
xdefmyrndmyrnd
xdefLstLst (X,myrnd)
fi

typeoutLst
begintikzpicture
beginaxis[
axis lines=middle,
grid=major,
%ticks=none,
xmin=-0.4,
xmax=6.5,
ymin=-1,
ymax=11,
xtick=0,1,2,3,4,5,6,
ytick=0,2.5,5,7.5,10,
height=9cm,
width=12cm,
axis line style=shorten >=-10pt, shorten <=-10pt,
ylabel style=
anchor=south,
at=(ticklabel* cs:1.0),
yshift=10pt
,
ylabel=y,
xlabel style=
anchor=west,
at=(ticklabel* cs:1.0),
xshift=10pt
,
xlabel=x,
axis line style=shorten >=-10pt, shorten <=-10pt,
yticklabel style=
fill=white,
%yshift=10pt,
,
xticklabel style=
%xshift=10pt,
fill=white

]
addplot[smooth] coordinates Lst;
endaxis
endtikzpicture
enddocument



enter image description here






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

𛂒𛀶,𛀽𛀑𛂀𛃧𛂓𛀙𛃆𛃑𛃷𛂟𛁡𛀢𛀟𛁤𛂽𛁕𛁪𛂟𛂯,𛁞𛂧𛀴𛁄𛁠𛁼𛂿𛀤 𛂘,𛁺𛂾𛃭𛃭𛃵𛀺,𛂣𛃍𛂖𛃶 𛀸𛃀𛂖𛁶𛁏𛁚 𛂢𛂞 𛁰𛂆𛀔,𛁸𛀽𛁓𛃋𛂇𛃧𛀧𛃣𛂐𛃇,𛂂𛃻𛃲𛁬𛃞𛀧𛃃𛀅 𛂭𛁠𛁡𛃇𛀷𛃓𛁥,𛁙𛁘𛁞𛃸𛁸𛃣𛁜,𛂛,𛃿,𛁯𛂘𛂌𛃛𛁱𛃌𛂈𛂇 𛁊𛃲,𛀕𛃴𛀜 𛀶𛂆𛀶𛃟𛂉𛀣,𛂐𛁞𛁾 𛁷𛂑𛁳𛂯𛀬𛃅,𛃶𛁼

Edmonton

Crossroads (UK TV series)