-
Notifications
You must be signed in to change notification settings - Fork 0
/
tikz_fig.tex
102 lines (90 loc) · 2.94 KB
/
tikz_fig.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
\documentclass{article} %
\usepackage[utf8]{inputenc}
\usepackage{xifthen}
\usepackage{color}
\usepackage{tikz}
\usetikzlibrary{arrows, arrows.meta}
\usepackage{pgfplots}
\definecolor{mid-gray}{gray}{0.5}
%%% yellow-brown
\definecolor{clsAa}{HTML}{FEC44F}
\definecolor{clsZa}{HTML}{662506}
%%% grey light-dark
\definecolor{clsAb}{HTML}{DDDDDD}
\definecolor{clsZb}{HTML}{666666}
\pgfplotsset{compat=1.17,
fbyf/.style={height=.265\textwidth, width=.265\textwidth,
ytick pos=left,
xtick pos=bottom,
tick align=outside,
x label style={
align=center,text width=3cm, %
},
y label style={
align=center,text width=3cm, %
},
major tick length=2pt,
tick style={black, semithick},
tick label style={black, font=\scriptsize} %
},%
hrz/.style={dotted, mid-gray, line width=.5pt}, %
}
\tikzset{
tsc node/.style={draw=none, circle, inner sep=1.2pt}, %
mrk node/.style={circle, inner sep=1.2pt}, %
tsc path/.style={-{Stealth[length=4pt, width=3pt]}, line width=.5pt, shorten <=.4pt, shorten >=.4pt}, %
mrk nodea/.style={circle, inner sep=1.pt}, %
tsc patha/.style={-{Stealth[length=4pt, width=3pt]}, line width=.5pt, shorten <=.4pt, shorten >=.4pt}, %
mrk nodeb/.style={circle, inner sep=.6pt}, %
tsc pathb/.style={-{Stealth[length=2.5pt, width=2pt]}, line width=.3pt, shorten <=.4pt, shorten >=.4pt}, %
}
\newenvironment{dummy}{}{}
\usepackage[active,tightpage]{preview}
\PreviewEnvironment{dummy}
\setlength\PreviewBorder{1pt}%
\begin{document}
\begin{dummy}
\newcommand{\srs}{a}%
\begin{tikzpicture}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%% CHANGE INPUT FILE HERE
\input{figs/trend-nbCooc-avg_hyp_NA-L_null-CB_x+i100.tikz}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\foreach \sm in {1,...,\nbs}{%
\ifnum\sm<\nbs%
\renewcommand{\srs}{b}%
\fi%
\foreach \x [count=\xm] in {2,...,\nbt}{%
\pgfmathtruncatemacro{\cgrd}{100*(\nbt-\x)/17}%
\path[tsc path\srs] (s\sm_n\xm) edge[clsA\srs!\cgrd!clsZ\srs, opacity=.5] (s\sm_n\x);
}
\foreach \x in {1,...,\nbt}{
\pgfmathtruncatemacro{\cgrd}{100*(\nbt-\x)/17}%
\node[mrk node\srs, fill=clsA\srs!\cgrd!clsZ\srs] at (s\sm_n\x) {};
};
}%
\end{tikzpicture}
\end{dummy}
\begin{dummy}
\newcommand{\srs}{a}%
\begin{tikzpicture}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%% CHANGE INPUT FILE HERE
\input{figs/trend-nbCooc-avg_hyp_EU-L_null-CB_x+i100.tikz}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\foreach \sm in {1,...,\nbs}{%
\ifnum\sm<\nbs%
\renewcommand{\srs}{b}%
\fi%
\foreach \x [count=\xm] in {2,...,\nbt}{%
\pgfmathtruncatemacro{\cgrd}{100*(\nbt-\x)/17}%
\path[tsc path\srs] (s\sm_n\xm) edge[clsA\srs!\cgrd!clsZ\srs, opacity=.5] (s\sm_n\x);
}
\foreach \x in {1,...,\nbt}{
\pgfmathtruncatemacro{\cgrd}{100*(\nbt-\x)/17}%
\node[mrk node\srs, fill=clsA\srs!\cgrd!clsZ\srs] at (s\sm_n\x) {};
};
}%
\end{tikzpicture}
\end{dummy}
\end{document}