10 Commits
2.0.0 ... dev

Author SHA1 Message Date
Bart Jablonski
3b14b9cd3e The BasePlus package [ver. 3.1.1]
The BasePlus package [ver. 3.1.1]

Update:
- Minor updates `%dirsAndFiles()` macro.

- File SHA256: `F*6394CE27FBCF48D475F682CBCF8CA8B4FDD6D40D2672EF571F4A561BDDF274A6` for this version
- Content SHA256: `C*3CA28DF8F3E6D6670D7FD44788D347452F24F4BCF18115873E7EBC742FE30CA4` for this version
2025-11-05 15:19:21 +01:00
Bart Jablonski
65dc1c510d The BasePlus package [ver. 3.1.0]
The BasePlus package [ver. 3.1.0]

Update:
- Update in macro `%findDSwithVarVal()`. To handle bigger range of engines, when a library is assigned with different engine than: "BASE","SPDE","V6","V7","V8","V9","CVP" observation number is not returned.

- File SHA256: `F*9FFBC40A2B7FC51161C7D6D120DADC3ACEF8087E4EB43BB1A3F0FBC1F1CBD5AC` for this version
- Content SHA256: `C*76C55A9F392EAB938D199144CC834EF332CD78BA8B98565FA003DEA509A33A3E` for this version
2025-10-20 11:01:34 +02:00
Bart Jablonski
eb43a1be93 The BasePlus package [ver. 3.0.0]
The BasePlus package [ver. 3.0.0]

New:
- New utility macro `%workLib()`, created in collaboration with Ryo Nakaya, added.

- File SHA256: `F*B9F6D8F1EDD1ECDA89F4BE327C4F4202649475D1D9DFB476279B633D9F14125D` for this version
- Content SHA256: `C*680412F6B403870A3A8975FC17300F7C92AEDECA48D3F242B5BC4E545DC6D313` for this version
2025-10-15 10:23:51 +02:00
Bart Jablonski
0fab75eda8 The BasePlus package [ver. 2.4.1]
The BasePlus package [ver. 2.4.1]

Fix:
- Fix engine recognition code in `%splitDSintoBlocks()` macro.

- File SHA256: `F*DB0811D8F207641BD45FCE30CB75D03CDF8D06849EBEA268BB575358FAA4E76C` for this version
- Content SHA256: `C*27861ABABB412E8229FE25CD5EEA868F49BB3CBD805CCE65F321ADBC522FAC4E` for this version
2025-09-05 10:30:04 +02:00
Bart Jablonski
de1de46fbe The BasePlus package [ver. 2.4.0]
The BasePlus package [ver. 2.4.0]

Changes:
- new parameter `backslashSens=` added to the `%dirsAndFiles()` macro.

- File SHA256: `F*19FE220C82DE4B9990B4AC352A9D9DEF5FAF2FD601BE756B2F3A2AC39CDAF381` for this version
- Content SHA256: `C*83DEF0C93481B1C77494531E5CE9F8EB8E4C15AB3CC48D1E9C0223C13A84DB3F` for this version
2025-08-07 18:26:30 +02:00
Bart Jablonski
8625e9c364 The BasePlus package [ver. 2.3.1]
The BasePlus package [ver. 2.3.1]

Changes:
Fix in log notes produced by `%getVars()` and `%QgetVars()`.

- File SHA256: `F*B2D318DD9708D74E5A7C419F7CAE1BF46D662B7F6AEE7E6B1B9D9B6858A5C41A` for this version
- Content SHA256: `C*C34B47FDC4A22C5F5EACA087FA5308B97C367E8B7C32C5B28D37B491C6DAA9A3` for this version
2025-08-05 20:18:29 +02:00
Bart Jablonski
059f7feb1c The BasePlus package [ver. 2.3.0]
# The BasePlus package [ver. 2.3.0]

- File SHA256: `F*71DC1AFA709B2977E8AEA452721776F62EEC8240ABD658AC83AA6D4310FC49B6` for this version
- Content SHA256: `C*9CEDE8C64D2C619EBC27AC85B4904D2CE2423C832C6C313E526946FC1417EFD1` for this version

---

### Changes:

Update in macros:
- `%getVars()` and `%QgetVars()`

    - New *optional* parameter `nlit=`. Introduced to improve `validvarname=ANY` handling. Indicates if the `NLITERAL()` function should be executed to cover spacial characters. Default value is `0`.
    - Code simplification for the `mcArray=` parameter case.
    - Situation when the `%getVars()` macro is called with `mcArray=` in `%put` or `%let` statements is handled more gracefully.

- `%zipEvalf()` and `%QzipEvalf()`

    - If the list contains quoted blanks, they are respected now, i.e. `a "b c"` are considered 2 strings, `a` and `b c`.

See documentation for details.

---
2025-08-04 15:45:57 +02:00
Bart Jablonski
8a41c32d7c The BasePlus package [ver. 2.1.0]
## The BasePlus package [ver. 2.1.0]

### Changes:

Update to the
[`%rainCloudPlot()`](https://github.com/SASPAC/baseplus/blob/2.1.0/baseplus.md#raincloudplot-macro-17)
macro, new `whiskerScale=` parameter added.

See [documentation](https://github.com/SASPAC/baseplus/blob/main/baseplus.md) for details.

---

SHA256 digest for BasePlus: `F*DFA83F8E0D7424DEB63D49620392068BC68D766552E2804CB6B01DE8E5A87769`

---

### Example.

~~~~sas
%rainCloudPlot(
 sashelp.class
,sex
,height
,whiskerScale=0.5
)
~~~~
2024-09-09 13:16:59 +02:00
Bart Jablonski
8778f39ce4 WUSS 2024 conference - materials on %RainCloudPlot() macro 2024-09-05 07:26:30 +02:00
Bart Jablonski
8ceeeaadae The BasePlus package [ver. 2.0.1]
## The BasePlus package [ver. 2.0.1]

This release is dedicated to all dyslexics in the world.

### Changes:

New macros:
- [`%expandDataSetsList()`](https://github.com/SASPAC/baseplus/blob/2.0.0/baseplus.md#expanddatasetslist-macro) allowing to expand data set lists of the form: `a1-a3`, `b_:`, mixed, and `_all_`;
- [`%unifyVarsCaseSize()`](https://github.com/SASPAC/baseplus/blob/2.0.0/baseplus.md#unifyvarscasesize-macro) allowing to convert all variables in a list of datasets to all-low-case or all-upcase letters.

Both macros are result of recent discussions at `SAS-L` and `communities.sas.com`.

New format/informats:
- [`bpklength.`](https://github.com/SASPAC/baseplus/blob/2.0.0/baseplus.md#bpklength-format)
- [`bplength.`](https://github.com/SASPAC/baseplus/blob/2.0.0/baseplus.md#bplength-format)
- Bug fix in spelling (`lenght` vs `length`).

See [documentation](https://github.com/SASPAC/baseplus/blob/main/baseplus.md) for details.

---

SHA256 digest for BasePlus: `F*FB102C9B12E870666C15A651017D48E0141E47D64C11437350D0EC75A7E9E609`

---

### Example 1. New macros.

~~~~sas
data a1 a2 a3 b_x b_y b_z;
  set sashelp.class(obs=1);
run;

%put #%expandDataSetsList(lib=work,datasets=a1-a3 b_:)#;

proc print data=a1;
proc print data=b_x;
run;

%unifyVarsCaseSize(work,a1-a3 b_:)

proc print data=a1;
proc print data=b_x;
run;
~~~~

### Example 2. New formats/informats:

~~~~sas
data _null_;
  x = input('żółw', bpklength.);
  y = input('żółw', bplength.);
  put x= y=;
run;
~~~~

~~~~log
x=4 y=7
~~~~
2024-07-24 08:10:07 +02:00
67 changed files with 70436 additions and 40 deletions

View File

@@ -53,10 +53,12 @@ libname NEW "%workPath()/new";
%put %monthShift(2023,1,-5);
%put #%expandDataSetsList(lib=sashelp,datasets=_all_)#;
%workLib(ABC)
```
and more.
SHA256 digest for the latest version of `BasePlus`: F*0730DD793516E5C193842126A7EC9D339ADADD19F0F40B071F938CABDE4E66AD
SHA256 digest for the latest version of `BasePlus`: F*6394CE27FBCF48D475F682CBCF8CA8B4FDD6D40D2672EF571F4A561BDDF274A6
[**Documentation for BasePlus**](./baseplus.md "Documentation for BasePlus")

View File

@@ -9,22 +9,22 @@
### Version information:
- Package: BasePlus
- Version: 2.0.0
- Generated: 2024-07-23T21:51:33
- Author(s): Bartosz Jablonski (yabwon@gmail.com), Quentin McMullen (qmcmullen@gmail.com)
- Version: 3.1.1
- Generated: 2025-11-05T15:10:31
- Author(s): Bartosz Jablonski (yabwon@gmail.com), contributors are Quentin McMullen (qmcmullen@gmail.com) and Ryo Nakaya (nakaya.ryou@gmail.com)
- Maintainer(s): Bartosz Jablonski (yabwon@gmail.com)
- License: MIT
- File SHA256: `F*0730DD793516E5C193842126A7EC9D339ADADD19F0F40B071F938CABDE4E66AD` for this version
- Content SHA256: `C*0352F7BB04B99D620BEFD33FF1B1FF1835E6F8F21CC6A764D05EEE51E77E57E0` for this version
- File SHA256: `F*6394CE27FBCF48D475F682CBCF8CA8B4FDD6D40D2672EF571F4A561BDDF274A6` for this version
- Content SHA256: `C*3CA28DF8F3E6D6670D7FD44788D347452F24F4BCF18115873E7EBC742FE30CA4` for this version
---
# The `BasePlus` package, version: `2.0.0`;
# The `BasePlus` package, version: `3.1.1`;
---
# The BasePlus package [ver. 2.0.0] <a name="baseplus-package"></a> ###############################################
# The BasePlus package [ver. 3.1.1] <a name="baseplus-package"></a> ###############################################
The **BasePlus** package implements useful
functions and functionalities I miss in the BASE SAS.
@@ -47,7 +47,8 @@ Kudos to all who inspired me to generate this package:
*Quentin McMullen*,
*Kurt Bremser*,
*Leonid Batkhan*,
*Louise Hadden*.
*Louise Hadden*,
*Ryo Nakaya*.
---
@@ -387,6 +388,11 @@ proc print data=b_x;
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 29** Create library ABC assigned to `<WORK>/ABC` directory:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%workLib(abc)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
---
@@ -403,7 +409,7 @@ localization (only if additional content was deployed during the installation pr
--------------------------------------------------------------------
*SAS package generated by SAS Package Framework, version `20240711`*
*SAS package generated by SAS Package Framework, version `20251017`*
--------------------------------------------------------------------
@@ -490,10 +496,11 @@ The `BasePlus` package consists of the following content:
78. [`%translate()` macro ](#translate-macro-78 )
79. [`%tranwrd()` macro ](#tranwrd-macro-79 )
80. [`%unifyvarscasesize()` macro ](#unifyvarscasesize-macro-80 )
81. [`%workpath()` macro ](#workpath-macro-81 )
81. [`%worklib()` macro ](#worklib-macro-81 )
82. [`%workpath()` macro ](#workpath-macro-82 )
82. [License note](#license)
83. [License note](#license)
---
@@ -838,6 +845,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
<,longFormat=>
<,fileExt=>
<,maxDepth=>
<,backslashSens=>
)
~~~~~~~~~~~~~~~~~~~~~~~
@@ -868,6 +876,11 @@ The basic syntax is the following, the `<...>` means optional parameters:
* `maxDepth=0` - *Optional*, if not zero then indicates
maximum depth of search in the root path.
* `backslashSens=0` - *Optional*, if not zero then it indicates
that backslash(`\`) symbol in files and dirs
names is detectable under Linux. Accepted
values: `0` and `1`. Ignored under Windows.
### EXAMPLES AND USECASES: ####################################################
@@ -989,7 +1002,12 @@ The QgetVars() returns quoted value [by %superq()].
See examples below for the details.
The `%getVars()` macro executes like a pure macro code.
When `mcArray=` is not used the `%getVars()` macro executes like
a pure macro code. When `mcArray=` is not null (creation of a
macro variable array is requested) them a single semicolon is returned.
When `validvarname=ANY` in set special care should be kept.
See dedicated examples below.
### SYNTAX: ###################################################################
@@ -1003,6 +1021,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
<,quote=>
<,mcArray=>
<,ignoreCases>
<,nlit=>
)
~~~~~~~~~~~~~~~~~~~~~~~
@@ -1025,23 +1044,32 @@ The basic syntax is the following, the `<...>` means optional parameters:
* `mcArray=` - *Optional*, default value is blank.
1) When *null* - the macro behaves like a macro function
and returns a text string with variables list.
2) When *not null* - behaviour of the macro is altered.
and ban be used in the `%put` or `%let=` statements.
The returned text is a string with variables list.
2) When *not null* - behavior of the macro is altered.
In such case a macro array of selected variables, named
with `mcArray` value as a prefix, is created.
Furthermore a macro named as `mcArray` value is generated.
(see the macroArray package for the details).
When `mcArray=` parameter is active the `getVars` macro
cannot be called within the `%put` statement. Execution like:
`%put %getVars(..., mcArray=XXX);` will result with
an Explicit & Radical Refuse Of Run (aka ERROR).
should not be called within the `%put` or `%let=` statements.
A single semicolon is produced as the macro result, hence
execution like: `%put %getVars(..., mcArray=XXX) some text;`
will result with an Explicit & Radical Refuse Of Run (aka ERROR).
* `ignoreCases=` - *Optional*, default value is 1.
* `ignoreCases=` - *Optional*, default value is 1.
Indicates if search should be case insensitive.
* `nlit=` - *Optional*, default value is 0.
Introduced to improve `validvarname=ANY` handling.
Indicates if the `NLITERAL()` function should be
executed to cover spacial characters.
### EXAMPLES AND USECASES: ####################################################
**When `validvarname=` option is _not_ `ANY`.**
**EXAMPLE 1.** A list of all variables from the
sashelp.class dataset:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
@@ -1267,6 +1295,44 @@ run;
%put %do_over(XYZ);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**When the `validvarname=ANY` option is set.**
**EXAMPLE 12.** Get all variables and handle special characters.
Without `nlit=1` the code will fail.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
options validvarname = any;
data varnameANY;
set sashelp.class(obs=3);
'A&B'n=42;
'space name'n=101;
'2025-08'n=234;
'2025%09'n=235;
"2025'10"n=236;
'2025"11'n=237;
run;
%put %getVars(varnameANY, nlit=1);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 13.** Create macro variable array ABC for all variables.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%getVars(varnameANY, mcArray=ABC, nlit=1);
%put %ABC(1) %ABC(6) %ABC(7) %ABC(11);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 14.** Get only variables with illegal characters in names.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%let notV7compliant = %getVars(varnameANY, pattern=[^a-z0-9_], nlit=1);
%put &notV7compliant.;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 14.** Print variables starting with a digit.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%put %getVars(varnameANY, pattern=^\d, nlit=1);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
@@ -1929,6 +1995,11 @@ The basic syntax is the following, the `<...>` means optional parameters:
* `ignoreCases=` - *Optional*, default value is 1.
Indicates if search should be case insensitive.
* `nlit=` - *Optional*, default value is 0.
Introduced to improve `validvarname=ANY` handling.
Indicates if the `NLITERAL()` function should be
executed to cover spacial characters.
### EXAMPLES AND USECASES: ####################################################
@@ -2035,6 +2106,9 @@ plots of kernel density estimates, jitter data values, and box-and-whiskers plot
See examples below for the details.
The "Here Comes the Rain (Cloud Plot) Again" (B. Jablonski, 2024) article
describing the macro is attached as an additional content to the package.
### SYNTAX: ###################################################################
The basic syntax is the following, the `<...>` means optional parameters:
@@ -2052,6 +2126,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
<,boxPlotSymbolSize=>
<,boxPlotLineSize=>
<,boxPlotFill=>
<,whiskerScale=>
<,meanShiftLine=>
<,meanShiftStep=>
<,meanShiftColors=>
@@ -2147,6 +2222,12 @@ The basic syntax is the following, the `<...>` means optional parameters:
Transparency of the box plot.
Ranges from 0.0 (opaque) to 1.0 (full translucent).
* `whiskerScale=` - *Optional*, default value `1.5`.
It provides `WS` parameter in the `Q1 - WS*IQR`
formula and the `Q3 + WS*IQR` formula.
Provided value should be a positive number.
Otherwise it is set to 0.
* `meanShiftLine` - *Optional*, default value `0`.
Indicates if a line connecting mean symbol
on the Box Plot should be added.
@@ -2366,12 +2447,14 @@ The basic syntax is the following, the `<...>` means optional parameters:
The box-and-whiskers plot has the following interpretation:
- left vertical bar indicates the *minimum*,
- left whisker line starts at `max(Q1 - 1.5IQR, minimum)` and ends at lower quartile (Q1),
- left whisker line starts at `max(Q1 - WS*IQR, minimum)` and ends at lower quartile (Q1),
- diamond indicates mean,
- vertical bar inside of the box indicates median,
- right whisker line starts at upper quartile (Q3) and ends at `min(Q3 + 1.5IQR, maximum)`,
- right whisker line starts at upper quartile (Q3) and ends at `min(Q3 + WS*IQR, maximum)`,
- right vertical bar indicates the *maximum*.
The `WS` value is provided through `whiskerScale=` parameter. Default value is `1.5`.
With above setup it may happen that
there is a gap between the minimum marker and the beginning of the left whisker
or
@@ -2533,6 +2616,7 @@ The output can be seen in the `md` file.
, vertical = 1
, title = %nrstr(title1 J=C HEIGHT=3 "The VERTICAL plotting is cool, ...";)
, footnote = %nrstr(footnote1 J=L HEIGHT=2 "... isn't it?";)
, whiskerScale = 1.5
)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -4521,9 +4605,9 @@ semicolonN(X)
## `$bpklenght.` format/informat <a name="bpklenght-formats-49"></a> ######
## >>> `bpklenght` format/informat: <<< <a name="bpklenght-format"></a> #######################
## >>> `bpklength` format/informat: <<< <a name="bpklength-format"></a> #######################
The **bpklenght** format and informats uses the `klength()` function
The **bpklength** format and informats uses the `klength()` function
to count the number of letters in a word. For empty string returns 0.
@@ -4533,9 +4617,9 @@ to count the number of letters in a word. For empty string returns 0.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data work.count_letters;
input x $ 32.;
n = input (x, bpklenght.);
c = input (x, $bpklenght.);
format x $bpklenght.;
n = input (x, bpklength.);
c = input (x, $bpklength.);
format x $bpklength.;
cards;
ż
żó
@@ -4570,7 +4654,7 @@ data _null_;
length x $ 32767;
do i = 32767/3 to 0 by -1111, 10 to 0 by -1;
x=repeat("空",i);
put x $bpklenght.;
put x $bpklength.;
end;
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -4582,9 +4666,9 @@ run;
## `$bplenght.` format/informat <a name="bplenght-formats-50"></a> ######
## >>> `bplenght` format/informat: <<< <a name="bplenght-format"></a> #######################
## >>> `bplength` format/informat: <<< <a name="bplength-format"></a> #######################
The **bplenght** format and informats use the `lengthn()` function
The **bplength** format and informats use the `lengthn()` function
to count the number of bytes in a word.
@@ -4594,9 +4678,9 @@ to count the number of bytes in a word.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
data work.count_bytes;
input x $ 32.;
n = input (x, bplenght.);
c = input (x, $bplenght.);
format x $bplenght.;
n = input (x, bplength.);
c = input (x, $bplength.);
format x $bplength.;
cards;
ż
żó
@@ -4631,7 +4715,7 @@ data _null_;
length x $ 32767;
do i = 32767/3 to 0 by -1111, 10 to 0 by -1;
x=repeat("空",i);
put x $bplenght.;
put x $bplength.;
end;
run;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -5945,6 +6029,11 @@ See examples below for the details.
The `%findDSwithVarVal()` macro does not execute as a pure macro code.
**NOTE:**
When a library is assigned with different engine than:
"BASE","SPDE","V6","V7","V8","V9","CVP"
observation number is not returned.
### SYNTAX: ###################################################################
The basic syntax is the following, the `<...>` means optional parameters:
@@ -6382,7 +6471,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
3. `false` - *Required*, value returned when condition is false.
4 `v=` - *Optional*, v for verbose. If set to `1` extra notes
* `v=` - *Optional*, v for verbose. If set to `1` extra notes
are printed.
---
@@ -6579,7 +6668,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
The letters() macro function allows to print a list of Roman
letters starting from `start` up to `end` incremented by `by`.
The letters list can be uppercases or lowercase (parameter `c=U` or `c=L`),
The letters list can be uppercase or lowercase (parameter `c=U` or `c=L`),
can be quoted (e.g. `q=""` or `q=[]`), and can be separated by `s=`.
Values of `start`, `end`, and `by` have to be integers in range between 1 ad 26.
@@ -6607,12 +6696,12 @@ The basic syntax is the following, the `<...>` means optional parameters:
Values of `start`, `end`, and `by` are separated by
colon and must be between 1 ad 26.
If value is outside range it is set to
`start=1`, `en=26`, and `by=1`. If `end` is missing
then is set to value of `start`.
`start=1`, `end=26`, and `by=1`. If `end` is missing
then it is set to value of `start`.
If `end` is smaller than `start` list is reversed
* `c = U` - *Optional*, it is a lowercase letters indicator.
Select `L` or `l`. Default value is `U` for upcase.
Select `L` or `l`. Default value is `U` for uppercase.
* `q = ` - *Optional*, it is a quite around elements of the list.
Default value is empty. Use `%str()` for one quote symbol.
@@ -7542,7 +7631,71 @@ run;
---
## `%workpath()` macro <a name="workpath-macro-81"></a> ######
## `%worklib()` macro <a name="worklib-macro-81"></a> ######
## >>> `%workLib()` macro: <<< <a name="worklib-macro"></a> #######################
The `%workLib()` macro creates and assigns a WORK-scoped sub-library.
Purpose:
The macro creates (if needed) and assigns a SAS library as a sub-directory
under the current `WORK` location. This is useful for isolating temporary
outputs per task while ensuring automatic cleanup at the end of the SAS session.
Basic engines libraries, like `BASE`, `V*`, and simple `SPDE`, can be set.
### SYNTAX: ###################################################################
The basic syntax is the following, the `<...>` means optional parameters:
~~~~~~~~~~~~~~~~~~~~~~~sas
%workLib(lib,<engine>)
~~~~~~~~~~~~~~~~~~~~~~~
**Arguments description**:
- `lib` - *Required*: Name of a library (and sub-folder)
to create under WORK. The value must be a valid
nonempty SAS libref (8 characters max, starting
with a letter or underscore).
- `engine` - *Optional*, Name of a basic, directory level,
SAS engine, e.g. `BASE`. When empty the default
engine is used.
---
### Details
- Builds a target path: `<WORK>/<lib>`.
- All data written to this libref are temporary and will be removed
when the WORK library is cleared at session end.
- If a directory with the same name already exists under WORK,
the macro prints a note and simply assigns the LIBNAME to
that location.
- The `dcreate()` function is used to create sub-directory.
### EXAMPLES AND USECASES: ####################################################
**EXAMPLE 1.** Create library ABC assigned to `<WORK>/ABC` directory:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%workLib(abc)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**EXAMPLE 2.** Create libraries with different engines:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~sas
%workLib(b,BASE)
%workLib(v,V6) %* for Windows only.;
%workLib(s,SPDE)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
---
---
## `%workpath()` macro <a name="workpath-macro-82"></a> ######
## >>> `%workPath()` macro: <<< <a name="workpath-macro"></a> #######################
@@ -7585,7 +7738,7 @@ The basic syntax is the following, the `<...>` means optional parameters:
# License <a name="license"></a> ######
Copyright (c) 2020 - 2023 Bartosz Jablonski
Copyright (c) 2020 - 2025 Bartosz Jablonski
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

Binary file not shown.

View File

@@ -0,0 +1,698 @@
/* WUSS 2024 Paper 164 */
/* "Here Comes the Rain (Cloud Plot) Again" */
/* by Bartosz Jablonski */
/* Rain Cloud Plots - PART 1 - Article Plots */
/* SETUP *//*
----------------------------------------------------------------------
Only the first time:
^^^^^^^^^^^^^^^^^^^^
filename packages "/path/to/my/packages";
filename SPFinit url "https://bit.ly/SPFinit"; *(1);
%include SPFinit;
%installPackage(SPFinit BasePlus) *(2);
----------------------------------------------------------------------
On start of fresh SAS session:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
filename packages "/path/to/my/packages";
%include packages(SPFinit.sas);
%loadPackageS(BasePlus) *(3);
----------------------------------------------------------------------*/
/*footnotes**********************************************************
*(1); Bitly points to:
https://github.com/yabwon/SAS_PACKAGES/blob/main/SPF/SPFinit.sas
*(2); BasePlus is loaded for the %RainCloudPlot() macro.
*(3); RainCloudPlot can be just "cherry picked" from BasePlus:
%loadPackage(BasePlus, cherryPick=RainCloudPlot)
*********************************************************************/
/* basePlus, version 1.41.0 or later is required */
/* Help notes in log */
%helpPackage(basePlus, RainCloudPlot)
%let path=/path/for/plots/; /* adjust for your session */
resetline;
data have;
call streaminit(42);
do i = 1 to 3;
groupingVar = byte(64+i);
do j = 1 to rand("integer",17,42);
select(i);
when(1) analysisVar = rand("uniform", 1, 7);
when(2) analysisVar = rand("normal", -3, 2);
when(3) analysisVar = rand("exponential", 2);
otherwise;
end;
output;
end;
end;
drop i j;
run;
proc print;
run;
/* utility macros */
%macro beforePlot(N,orientation=landscape,papersize=A4);
ods printer close; ods pdf close;
options orientation=&orientation. nodate nonumber papersize=&papersize. center;
options topmargin=0cm leftmargin=0cm rightmargin=0cm bottommargin=0cm;
ods pdf file="&path.//WUSS2024paper164plot&n..pdf" contents=no notoc dpi=600;
ods printer file="&path.//WUSS2024paper164plot&n..svg" printer=svg dpi=600;
%mend beforePlot;
%macro afterPlot();
ods printer close;
ods pdf close;
%mend afterPlot;
/* 1 */
%beforePlot(1);
%rainCloudPlot(
have
, groupingVar
, analysisVar
)
%afterPlot()
/* 2 */
%beforePlot(2)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, TITLE = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";
)
, FOOTNOTE =
%str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
)
%afterPlot()
/* 3 */
%beforePlot(3)
data colors;
input color :$20. @@;
retain y -0.5;
value=1;
x=1;
y+1;
cards;
BlueViolet RoyalBlue OliveDrab
Gold HotPink Crimson
MediumPurple CornflowerBlue YellowGreen
Goldenrod Orchid IndianRed
;
run;
proc sgplot data=colors noborder noautolegend nowall subpixel;
styleattrs
DATACOLORS = (
BlueViolet RoyalBlue OliveDrab
Gold HotPink Crimson
MediumPurple CornflowerBlue YellowGreen
Goldenrod Orchid IndianRed
)
;
vbarparm response=value category=value/
group=color
grouporder=data
nooutline
groupdisplay=stack
clusterwidth=1
baselineattrs=(thickness=0)
;
text X=x Y=y TEXT=color /
backlight=.5
position=right
discreteoffset=-0.42
textattrs=(family="Courier New" size=14 weight=bold)
;
xaxis display=none offsetmax=0 offsetmin=0;
yaxis display=none;
run;
%afterPlot()
/* 4 */
%beforePlot(4)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";
)
, footnote =
%str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, MONOCHROME=1
)
%afterPlot()
/* 5 */
%beforePlot(5)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, COLORSLIST = CornflowerBlue OliveDrab IndianRed
)
%afterPlot()
/* 6 */
%beforePlot(6)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, RAINDROPSIZE = 8px
, KERNEL_K = quadratic
, KERNEL_C = 0.99
, VSCALE = Percent
, VSCALEmax = 60
)
%afterPlot()
/* 7 */
%beforePlot(7)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud (without BOX) Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, BOXPLOT=0
)
%afterPlot()
/* 8 */
%beforePlot(8)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, BOXPLOT=1
, BOXPLOTFILL = 0.5
, BOXPLOTLINESIZE = 2px
, BOXPLOTSYMBOLSIZE = 12px 8px
)
%afterPlot()
resetline;
proc format;
value $ FormatForGroup
"A" = 'Uniform[1, 7]'
"B" = 'Normal(-4, 2)'
"C" = 'Exponential(2)'
other = "Unknown!"
;
picture myPercent
0-100 = "099.9%"
other = "Wrong value"
;
run;
proc datasets lib=work nolist;
modify have;
format groupingVar $FormatForGroup.;
run;
quit;
/* 9 */
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%beforePlot(9)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, XLABELS = ("Analyzed variable")
, XLABELPOS = CENTER
, XLABELATTRS = &labelStyle.
, XAXISVALUEATTRS = &valuesStyle.
, XAXISTICKSTYLE = ACROSS
, XBOTHAXIS = 0
, XAXISVALUES=(-10 to 10 by 2)
, XAXISVALUESFORMAT=F5.2 /* instead w.d format use Fw.d !! */
, XAXISOTHER=grid gridattrs=(thickness=0)
minor minorgrid minorgridattrs=(color=cxefefef pattern=dot)
, CATLABELS = ("Grouping variable with formated values")
, CATLABELPOS = TOP
, CATLABELATTRS = &labelStyle.
, CATAXISVALUEATTRS = &valuesStyle.
, FORMATED = 1
, Y2AXIS = 1
, Y2AXISLEVELS = 5
, Y2AXISVALUEATTRS = &valuesStyle.
, Y2AXISFORMAT = myPercent.
, Y2AXISLINES = 1
)
%afterPlot()
/* 10 */
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%beforePlot(10)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("Analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(-8 to 8 by 2)
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable with formated values")
, catlabelpos = TOP
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, WIDTHPX = 1200
, HEIGHTPX = 300
, MINRANGE = -8
, MAXRANGE = 8
)
%afterPlot()
/* 11 */
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%beforePlot(11)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("Analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(-8 to 8 by 2)
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable with formated values")
, catlabelpos = TOP
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, widthpx = 1200
, heightpx = 300
, minrange = -8
, maxrange = 8
, ODSGRAPHICSOPTIONS = NOBORDER
, SGPLOTOPTIONS = NOAUTOLEGEND NOBORDER NOWALL PAD=0
)
%afterPlot()
/* 12 */
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
data WORK.IN_PROGRESS;
function="TEXT"; transparency=0.5;
textcolor="GOLD"; textweight="BOLD";
widthunit="PERCENT"; drawspace="GRAPHPERCENT";
width=500;
label="*) will be ready for WUSS 2024";
textsize=24; anchor="LEFT ";
x1=2; y1=3; rotate=0;
output;
label="Draft(*ESC*){sup '*'}";
textsize=128; anchor="CENTER";
x1=50; y1=50; rotate=30;
output;
run;
%beforePlot(12)
%rainCloudPlot(
have
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("Analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(-8 to 8 by 2)
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable with formated values")
, catlabelpos = TOP
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, widthpx = 1200
, heightpx = 300
, minrange = -8
, maxrange = 8
, odsgraphicsoptions = noborder
, sgplotoptions = noautolegend noborder nowall pad=0
, SGANNO = WORK.IN_PROGRESS
)
%afterPlot()
/* 13 */
%beforePlot(13)
%rainCloudPlot(
have2
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot - vertical";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE2, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("Analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(-8 to 8 by 2)
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable (formatted)")
, catlabelpos = CENTER
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, widthpx = 1200
, heightpx = 300
, minrange = .
, maxrange = .
, odsgraphicsoptions = noborder
, sgplotoptions = noautolegend noborder nowall pad=0
, sganno = work.in_progress
, MEANSHIFTLINE=1
, MEANSHIFTSTEP=0.1
, MEANSHIFTCOLORS=Blue Green Red
)
%afterPlot()
resetline;
/* 14 */
data have2;
set have;
groupingVar2 = ifc(0=mod(_N_,2),"Even","Odd");
analysisVar2 = rannor(42);
run;
%beforePlot(14)
%rainCloudPlot(
have2
, groupingVar groupingVar2
, analysisVar analysisVar2
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot &gi. &xj.";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE2, with 87 observations, four variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("First analyzed variable", "Second analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
/*, xaxisValues=(-8 to 8 by 2)*/
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable one", "Grouping variable two")
, catlabelpos = TOP
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, widthpx = 1200
, heightpx = 300
, minrange = .
, maxrange = .
, odsgraphicsoptions = noborder
, sgplotoptions = noautolegend noborder nowall pad=0
, sganno = work.in_progress
, meanShiftLine =1
)
%afterPlot()
/* 15 */
%beforePlot(15,orientation=PORTRAIT)
%rainCloudPlot(
have2
, groupingVar
, analysisVar
, title = %nrstr(title1 J=C HEIGHT=2 "The Rain Cloud Plot - vertical";
title2 J=C HEIGHT=1 "Plotting for groups: &list_g.";)
, footnote = %str(footnote1 J=R H=1 C=Gray
"Data set HAVE2, with 87 observations, two variables.";)
, colorslist = CornflowerBlue OliveDrab IndianRed
, raindropsize = 8px
, kernel_k = quadratic
, kernel_c = 0.99
, vscale = percent
, vscalemax = 60
, boxplot=1
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, xlabels = ("Analyzed variable")
, xlabelpos = CENTER
, xlabelattrs = &labelStyle.
, xaxisvalueattrs = &valuesStyle.
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(-8 to 8 by 2)
, xaxisValuesFormat=F5.2
, xaxisOther=GRID MINOR MINORGRID MINORGRIDATTRS=(color=CXeFeFeF pattern=dot) GRIDATTRS=(thickness=0)
, catlabels = ("Grouping variable (formatted)")
, catlabelpos = CENTER
, catlabelattrs = &labelStyle.
, cataxisvalueattrs = &valuesStyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesStyle.
, y2axisformat = myPercent.
, y2axislines = 1
, widthpx = 1200
, heightpx = 300
, minrange = .
, maxrange = .
, odsgraphicsoptions = noborder
, sgplotoptions = noautolegend noborder nowall pad=0
, sganno = work.in_progress
, meanShiftLine=1
, meanShiftStep=0.05
, VERTICAL = 1
)
%afterPlot()
/*
%helpPackage(basePlus, RainCloudPlot)
*/

Binary file not shown.

View File

@@ -0,0 +1,299 @@
/* WUSS 2024 Paper 164 */
/* "Here Comes the Rain (Cloud Plot) Again" */
/* by Bartosz Jablonski */
/* Rain Cloud Plots - PART 2 - Presentation Plots */
/*
See:
Rain Cloud Plots - PART 1 - Article Plots (file: Paper_164-WUSS2024.sas)
for details about the setup.
*/
data have;
call streaminit(64);
vertical = 42;
do j = 1 to 42;
horizontal = rand("uniform", 24, 42);
output;
end;
drop i j;
run;
data have;
set have;
horizontal = horizontal - 13;
run;
proc print;
run;
/* 101 */
%beforePlot(101)
%rainCloudPlot(
have
, vertical
, horizontal
, TITLE = %str(
title1 H=2 J=C "Here Come The Rain Again";
title2 H=1 J=C "Bartosz Jablonski";
)
, FOOTNOTE =
, vscale = percent
, vscalemax = 42
, y2axislevels = 1
, BOXPLOT=1
, BOXPLOTFILL = 0.5
, RAINDROPSIZE = 8px
, COLORSLIST=CX222222
, BOXPLOTLINESIZE = 2pt
, MINRANGE = 0
, MAXRANGE = 42
, xaxistickstyle = ACROSS
, xbothaxis = 0
, xaxisValues=(0 to 42 by 42)
, xaxisValuesFormat=F3.0
, xaxisOther=MINOR
, widthpx = 1200
, heightpx = 800
)
%afterPlot()
%beforePlot(102)
%rainCloudPlot(sashelp.cars, origin, invoice)
%afterPlot()
%beforePlot(103)
%rainCloudPlot(sashelp.class, sex, height)
%afterPlot()
%beforePlot(104)
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, TITLE = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, FOOTNOTE = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
)
%afterPlot() /*"*/
%beforePlot(105)
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, title = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, footnote = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
, COLORSLIST = OrangeRed OliveDrab
, BOXPLOTFILL = 0.5
, BOXPLOTLINESIZE = 2px
, BOXPLOTSYMBOLSIZE = 12px 8px
)
%afterPlot()
%beforePlot(106)
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, title = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, footnote = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
, colorslist = OrangeRed OliveDrab
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, RAINDROPSIZE = 3px
, KERNEL_K = triangular
, KERNEL_C = 0.99
, VSCALE = Percent
, VSCALEmax = 75
)
%afterPlot()
%beforePlot(107)
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, title = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, footnote = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
, colorslist = OrangeRed OliveDrab
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, raindropsize = 3px
, kernel_k = triangular
, kernel_c = 0.99
, vscale = percent
, vscalemax = 75
, XLABELS = ("Analyzed variable")
, XLABELPOS = CENTER
, XLABELATTRS = &labelStyle.
, XAXISVALUEATTRS = &valuesStyle.
, XAXISTICKSTYLE = ACROSS
, XBOTHAXIS = 0
, XAXISVALUES=(1e4 to 18e4 by 1e4)
, XAXISVALUESFORMAT=dollar12.2
, XAXISOTHER=grid gridattrs=(thickness=0)
minor minorgrid minorgridattrs=(color=cxefefef pattern=dot)
, CATLABELS = ("Grouping variable")
, CATLABELPOS = TOP
, CATLABELATTRS = &labelStyle.
, CATAXISVALUEATTRS = &valuesStyle.
, FORMATED = 1
, Y2AXIS = 1
, Y2AXISLEVELS = 5
, Y2AXISVALUEATTRS = &valuesStyle.
, Y2AXISFORMAT = F5.2
, Y2AXISLINES = 1
, WIDTHPX = 1200
, HEIGHTPX = 350
)
%afterPlot()
data WORK.AT_WUSS;
function="TEXT"; transparency=0.3;
textcolor="CornflowerBlue"; textweight="BOLD";
widthunit="PERCENT"; drawspace="GRAPHPERCENT";
width=500;
label="WUSS(*ESC*){sup '*'}";
textsize=96; anchor="CENTER";
textfont="Courier New";
x1=75; y1=20; rotate=0;
output;
run;
%beforePlot(108)
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, title = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, footnote = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
, colorslist = OrangeRed OliveDrab
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, raindropsize = 3px
, kernel_k = triangular
, kernel_c = 0.99
, vscale = percent
, vscalemax = 75
, xlabels = ("Analyzed variable")
, xlabelpos = center
, xlabelattrs = &labelstyle.
, xaxisvalueattrs = &valuesstyle.
, xaxistickstyle = across
, xbothaxis = 0
, xaxisvalues=(1e4 to 18e4 by 1e4)
, xaxisvaluesformat=dollar12.2
, xaxisother=grid gridattrs=(thickness=0)
minor minorgrid minorgridattrs=(color=cxefefef pattern=dot)
, catlabels = ("Grouping variable")
, catlabelpos = top
, catlabelattrs = &labelstyle.
, cataxisvalueattrs = &valuesstyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesstyle.
, y2axisformat = f5.2
, y2axislines = 1
, widthpx = 1200
, heightpx = 350
, SGANNO = WORK.AT_WUSS
, MEANSHIFTLINE=1
, MEANSHIFTSTEP=0.01
, MEANSHIFTCOLORS=gold blue
)
%afterPlot()
data WORK.AT_WUSS2;
function="TEXT"; transparency=0.3;
textcolor="CornflowerBlue"; textweight="BOLD";
widthunit="PERCENT"; drawspace="GRAPHPERCENT";
width=500;
label="WUSS(*ESC*){sup '2'}";
textsize=96; anchor="CENTER";
textfont="Courier New";
x1=60; y1=70; rotate=0;
output;
run;
%beforePlot(109,orientation=PORTRAIT)
%let labelStyle = size=10 family="Courier New" color=MidnightBlue weight=bold;
%let valuesStyle = size=8 family="Courier New" style=italic;
%rainCloudPlot(sashelp.cars(where=(origin in: ("E" "U"))), origin, invoice
, title = %nrstr(title1 J=C HEIGHT=2 "Distribution of cars prices";
title2 J=C HEIGHT=1 COLOR=DarkGrey "Europe vs. US";
)
, footnote = %str(footnote1 J=l H=1 C=Gray "1%) Data from SASHELP.CARS";) /*"*/
, colorslist = OrangeRed OliveDrab
, boxplotfill = 0.5
, boxplotlinesize = 2px
, boxplotsymbolsize = 12px 8px
, raindropsize = 3px
, kernel_k = triangular
, kernel_c = 0.99
, vscale = percent
, vscalemax = 75
, xlabels = ("Analyzed variable")
, xlabelpos = top
, xlabelattrs = &labelstyle.
, xaxisvalueattrs = &valuesstyle.
, xaxistickstyle = across
, xbothaxis = 0
, xaxisvalues=(1e4 to 18e4 by 1e4)
, xaxisvaluesformat=dollar12.2
, xaxisother=grid gridattrs=(thickness=0)
minor minorgrid minorgridattrs=(color=cxefefef pattern=dot)
, catlabels = ("Grouping variable")
, catlabelpos = center
, catlabelattrs = &labelstyle.
, cataxisvalueattrs = &valuesstyle.
, formated = 1
, y2axis = 1
, y2axislevels = 5
, y2axisvalueattrs = &valuesstyle.
, y2axisformat = f5.2
, y2axislines = 1
, widthpx = 1200
, heightpx = 400
, sganno = WORK.AT_WUSS2
, meanshiftline=1
, meanshiftstep=0.01
, meanshiftcolors=gold blue
, VERTICAL = 1
, ODSGRAPHICSOPTIONS = NOBORDER
, SGPLOTOPTIONS = NOAUTOLEGEND NOBORDER NOWALL PAD=0
)
%afterPlot()

Binary file not shown.

7609
hist/2.0.1/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.0.1/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

7622
hist/2.1.0/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.1.0/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

7680
hist/2.3.0/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.3.0/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

7680
hist/2.3.1/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.3.1/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

7686
hist/2.4.0/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.4.0/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

7686
hist/2.4.1/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/2.4.1/baseplus.zip Normal file

Binary file not shown.

7757
hist/3.0.0/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/3.0.0/baseplus.zip Normal file

Binary file not shown.

7762
hist/3.1.0/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/3.1.0/baseplus.zip Normal file

Binary file not shown.

7762
hist/3.1.1/baseplus.md Normal file

File diff suppressed because it is too large Load Diff

BIN
hist/3.1.1/baseplus.zip Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB