Hey SAS-C!
Just FYI.
Bart
SAS Packages Framework, version 20230520,
Available at GitHub: https://github.com/yabwon/SAS_PACKAGES
Fixes:
%loadPackageAddCnt()
and %generatePackage()
macros lengths of the "file path" variables were extended.Packages:
BasePlus
package, version 1.24.1
was regenerated with latest version of the framework.%RainCloudPlot()
macro from the BasePlus
packages was updated with new parameters (see the documentation).
Base Plus [1.24.1]: https://github.com/SASPAC/baseplus
%RainCloudPlot()
macro from the BasePlus
packages was updated with new parameters:
sganno
- Optional, default value is empty.
keeps name of a data set for the sganno=
option
of the SGPLOT procedure.
sgPlotOptions
- Optional, default value is noautolegend noborder
.
List of additional options values for SGPLOT procedure.
odsGraphicsOptions
- Optional, default value is empty.
List of additional options values for ODS Graphics
statement.
By default only the: width=
, height=
, and antialiasmax=
are modified.
Example: Rain Cloud plot with formatted groups and annotations.
data annotation;
function="text";
label="This graph is full(*ESC*){sup '2'} of annotations!";
drawspace="graphpercent";
rotate=30;
anchor="center";
textsize=32;
x1=50;
y1=50;
textcolor="red";
justify="center";
textweight="bold";
width=100;
widthunit="percent";
run;
proc format;
value system
1="Windows"
2="MacOS"
3="Linux"
;
run;
data test;
do system = 1 to 3;
do i = 1 to 30;
x = rannor(123)/system;
output;
end;
end;
format system system.;
run;
%RainCloudPlot(test, system, x
, formated=1
, sganno=annotation
, sgPlotOptions=noborder
, WidthPX=2000
, HeightPX=420
)
1.24.2
]Current release is natural continuation of 1.24.1
Updates:
The %RainCloudPlot()
has 2 new parameters: catLabelAttrs
and xLabelAttrs
:
catLabelAttrs
- Optional, default value is empty.
List of attributes for group axix labels (vertical).
xLabelAttrs
- Optional, default value is empty.
List of attributes for data variable axix labels (horizontal).
The catLabelAttrs
and xLabelAttrs
should be space separated lists of key=value
pairs,
e.g. xLabelAttrs=size=12 color=Pink weight=bold
, see Example below.
Documentation was updated (new examples with plots), and some spellings were fixed.
The SHA256 hash digest for package BasePlus:F*2A4F3953EC56DB914024457F74286D565C23DCF220FF151040BDB704FD8DDB06
Example: Rain Cloud plot for sashelp.cars
dataset with groups by Origin or Type for Invoice variables:
%RainCloudPlot(
sashelp.cars(where=(Type ne "Hybrid"))
, Origin Type
, Invoice
, HeightPX=300
, y2axisLevels=3
, catLabels=("Continent of Origin", "Car Type")
, xLabels="Invoice, [$]"
, xLabelAttrs=size=12 color=Pink weight=bold
)
1.26.0
]Located at: https://github.com/SASPAC/baseplus
Two new macros were introduces in the release:
%findDSwithVarVal()
macro searches for all datasets (available for a given session) containing a variable of a given value.%getTitle()
macro extract text of titles or footnotes into a delimited list.Documentation updated.
Note:
With this release the BasePlus
gained its first official co-author: Quentin McMullen ( @Quentin ) who provided the %getTitle()
macro.
EXAMPLE 1. Search numeric variable AGE
containing value 14
:
%findDSwithVarVal(age, 14, type=num)
EXAMPLE 2. Search library WORK
for variable NAME
starting with value Jo
ignoring cases and trimming blanks from value:
data A;
name="Joanna";
data B;
name="john";
data C;
name=" Joseph";
data D;
name=" joe";
run;
%findDSwithVarVal(name, Jo, ic=1, tb=1, cts=1, lib=WORK)
EXAMPLE 3. Get titles in different forms:
title1 j=c "Hi Roger" ;
title2 j=l "Good Morning" ;
title3 "How are you?" ;
title4 ;
title5 "Bye bye!" ;
%put %GetTitle() ;
%put %GetTitle(1 3,dlm=c, qt=[]) ;
%put %GetTitle(2:4,dlm=s, qt='') ;
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.