Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split figures relying on pgfplot 1.12 commands to separate file
- Loading branch information
Showing
4 changed files
with
181 additions
and
141 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
\documentclass[a4paper,english]{report} | ||
|
||
\include{rendering-preamble} | ||
|
||
\usepackage[pfx=figures-ng-]{jpfigurengcommands} | ||
\include{tableread} | ||
|
||
\begin{document} | ||
|
||
|
||
|
||
\tikzsetnextfilename{mini-2x1-categories-scatter} | ||
\begin{tikzpicture} | ||
\begin{groupplot}[ | ||
group style={ | ||
group size=2 by 1, | ||
horizontal sep=8pt, | ||
vertical sep=16pt, | ||
}, | ||
] | ||
|
||
\nextgroupplot[ | ||
% title=C1 Sweden, | ||
xlabel=http-www, | ||
ylabel=https-www, | ||
allDatasetsScatter, | ||
allDatasetsScatterMiniResults, | ||
scatter/classes={ | ||
Any={mark=square*,blue},% | ||
Disconnect={mark=triangle*,red},% | ||
Content={mark=x,draw=black},% | ||
Advertising={mark=o,draw=red},% | ||
Analytics={mark=diamond,draw=blue},% | ||
Social={mark=+,draw=green}% | ||
},% | ||
] | ||
\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedSwedenHttpHttpsWww | ||
|
||
\legend{} | ||
|
||
\nextgroupplot[ | ||
% title=C2 Global, | ||
xlabel=http-www, | ||
% ylabel=https-www, | ||
allDatasetsScatter, | ||
allDatasetsScatterMiniResults, | ||
scatter/classes={ | ||
Any={mark=square*,blue},% | ||
Disconnect={mark=triangle*,red},% | ||
Content={mark=x,draw=black},% | ||
Advertising={mark=o,draw=red},% | ||
Analytics={mark=diamond,draw=blue},% | ||
Social={mark=+,draw=green}% | ||
},% | ||
yticklabels={}, | ||
] | ||
\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedGlobalHttpHttpsWww | ||
|
||
\end{groupplot} | ||
\end{tikzpicture} | ||
|
||
|
||
|
||
\end{document} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
\NeedsTeXFormat{LaTeX2e} | ||
\ProvidesPackage{jpfigurengcommands}[2015/05/04 v0.1 Joel Purra, figure next generation commands] | ||
|
||
\RequirePackage{pgfplotstable} | ||
|
||
\RequirePackage{kvoptions} | ||
\SetupKeyvalOptions{% | ||
family=JPFCNG, | ||
prefix=JPFCNG@, | ||
} | ||
|
||
\DeclareStringOption{pfx} | ||
\ProcessKeyvalOptions* | ||
|
||
\PassOptionsToPackage{pfx=\JPFCNG@pfx}{jpfigurecommands} | ||
\RequirePackage{jpfigurecommands} | ||
|
||
|
||
|
||
\pgfplotsset{compat=1.12} | ||
|
||
|
||
|
||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
|
||
|
||
|
||
\pgfplotsset{ | ||
allDatasetsScatter/.style= | ||
{ | ||
scatter, | ||
only marks, | ||
point meta=explicit symbolic, | ||
fill opacity=0.9, | ||
ymin=0, | ||
ymax=1, | ||
ytick={0,.2,.4,.6,.8,1}, | ||
minor ytick={.1,.3,.5,.7,.9}, | ||
yminorgrids=true, | ||
ymajorgrids=true, | ||
xtick={0,.2,.4,.6,.8,1}, | ||
minor xtick={.1,.3,.5,.7,.9}, | ||
xminorgrids=true, | ||
xmajorgrids=true, | ||
}, | ||
allDatasetsScatterFullPage/.style= | ||
{ | ||
width=1.47\textwidth, | ||
height=.65\textwidth, | ||
font=\small, | ||
legend columns=1, | ||
legend style={at={(1.05,0.5)},anchor=west,cells={anchor=west},} | ||
}, | ||
allDatasetsScatterMiniResults/.style= | ||
{ | ||
enlarge y limits={abs=8pt}, | ||
enlarge x limits={abs=8pt}, | ||
width=.35\textwidth, | ||
height=.35\textwidth, | ||
font=\tiny, | ||
legend columns=1, | ||
legend style={at={(1.05,0.5)},anchor=west,cells={anchor=west},}, | ||
yticklabel style={ | ||
/pgf/number format/fixed, | ||
/pgf/number format/fixed zerofill=false, | ||
/pgf/number format/precision=1 | ||
}, | ||
title style={at={(.5,.95)}}, | ||
xticklabel style={ | ||
/pgf/number format/fixed, | ||
/pgf/number format/fixed zerofill, | ||
/pgf/number format/precision=1 | ||
}, | ||
yticklabel style={ | ||
/pgf/number format/fixed, | ||
/pgf/number format/fixed zerofill, | ||
/pgf/number format/precision=1 | ||
}, | ||
}, | ||
} | ||
|
||
\newcommand{\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww}[3]{ | ||
\scatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{#1}{\newScatterTable}{#2}{#3} | ||
|
||
\addplot+[] | ||
table[x=http-www,y=https-www,label=Category] | ||
\newScatterTable; | ||
|
||
\addlegendentry{#1} | ||
} | ||
|
||
\newcommand{\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww}[2]{ | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Any}{#1}{#2} | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Disconnect}{#1}{#2} | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Content}{#1}{#2} | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Advertising}{#1}{#2} | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Analytics}{#1}{#2} | ||
\addScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{Social}{#1}{#2} | ||
} | ||
|
||
\newcommand{\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedSwedenHttpHttpsWww}[0]{ | ||
\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{\tableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedSwedenHttpWww}{\tableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedSwedenHttpsWww} | ||
} | ||
|
||
\newcommand{\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedGlobalHttpHttpsWww}[0]{ | ||
\addDefaultScatterTableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedHttpHttpsWww{\tableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedGlobalHttpWww}{\tableDatasetsNonFailedDisconnectCategoriesCoverageExternalSortedGlobalHttpsWww} | ||
} | ||
|
||
|
||
|
||
|
||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
|
||
|
||
|
||
\endinput |