Introduction
The data visualization method widely used at present lacks information on the distribution pattern hidden in the raw data, and has a drawback that it is difficult to judge whether the sample distribution assumption, which is the premise of the hypothesis test, is correct.
In recent years, new data visualization methods that overcome such drawbacks have been announced and are already available in open source languages such as R and python. In contrast, the SAS language has made little effort as seen in open source languages.
“SAS plotter” is modern graph package for SAS. You can easily create advanced graphs for journals with little knowledge of SAS GTL (Graph Template Language) or sgplot procedures.
the lengthens data format is suitable.
history
0.1 (beta version)
three macros were added.
Raincloud plot
RainCloud plot (paired)
Ridgeline plot
1.0
bug fix. new macros were added.
mirrored histogram
1.1
bug fix. new macros were added.
2D-KDE
macro for initiation
palette parameter was added to all plot macros. color palette was added.
SAS
SNS (Seaborn)
STATA
TABLEAU
1.15 (beta)
new macros were added.
Sankey
1.2
new macros were added.
Multihistogram
- bug fix. following macros were updated.
Sankey
ridgeline
Multihistogram
- bug fix. following macros were updated.
Sankey
ridgeline
1.3
SAS PACKAGE framework is supported.
note parameter is added to all macros.
bugfix
legendtitle parameter is updated.
if ticklabel parameter is not set, the label is get from variable label automatically.
usage
this package is supported SAS PACKAGE framework. for more information : https://github.com/yabwon/SAS_PACKAGES
when the package is loaded. use %installpackage() and %loadpackage(). installed package is stored in “packages” directory. “packages” directory is set using following code. the name “packages” of filename is required.
code
filename packages "<your path>";
%installpackage() and %loadpackage() are available using SPFinit.sas
code
filename packages "<your path>";
filename SPFinit url "https://raw.githubusercontent.com/yabwon/SAS_PACKAGES/main/SPF/SPFinit.sas";
%include SPFinit;
/* install sas package framework*/
%installPackage(SPFinit);
/*install SAS plotter*/
%installpackage(sasplotter);
%loadpackage(sasplotter);
Color palette
this package is contained following color palette. To use these palette, set the palette parameter of each plot macro. The graph color(marker, line, fill) will be replaced.
SAS
default color palette of SAS.
SNS
default color palette of Seaborn, the graphics package of Python.
STATA
default color palette of STATA.
- TABLEAU
default color of Tableau. same as color palette “set2” of python graphics package, “Matplotlib”.
title and footnote
plot title and footnote are available using note parameter. The parameter is set entry statement and insert title or footnote into graph template.
the details of available statement is as follows.
entrytitle statement
https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatgraph/n0zp1mg0ard2dan17sohm8jb773n.htm
entryfootnote statement
https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatgraph/n1wobkwtxddh7gn1qs51yq2hhj1o.htm
entry statement
https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatgraph/p03b079gr8rmujn16jbfff7rue0p.htm