Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions docs/ass2.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
- [arm](#arm)
- [arm_by](#arm_by)
- [sort_by](#sort_by)
- [sort_linguistic](#sort_linguistic)
- [at_least](#at_least)
- [at_least_text](#at_least_text)
- [at_least_output_if_zero](#at_least_output_if_zero)
Expand Down Expand Up @@ -283,6 +284,26 @@ sort_by = %str(#G1#FREQ(desc) #G1#TIME(desc) #G2#FREQ(desc) #G2#TIME(desc))

---

#### sort_linguistic

**Syntax** : `true` | `false`

指定是否在排序时遵循当前区域设置的默认 collating sequence 选项。

> [!NOTE]
>
> 指定 `sort_linguistic = true` 相当于指定了 `PROC SQL` 语句的 [SORTSEQ = LINGUISTIC](https://documentation.sas.com/doc/zh-CN/pgmsascdc/9.4_3.5/sqlproc/p12ohgh32ffm6un13s7l2d5p9c8y.htm#p0i5z6z3vnmjd2n1abnsp9p3bc05) 选项。

**Default** : `true`

**Usage** :

```sas
sort_linguistic = false
```

---

#### at_least

**Syntax** : `true` | `false`
Expand Down
21 changes: 21 additions & 0 deletions docs/ass3.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
- [arm](#arm)
- [arm_by](#arm_by)
- [sort_by](#sort_by)
- [sort_linguistic](#sort_linguistic)
- [at_least](#at_least)
- [at_least_text](#at_least_text)
- [at_least_output_if_zero](#at_least_output_if_zero)
Expand Down Expand Up @@ -321,6 +322,26 @@ sort_by = %str(#G1#FREQ(desc) #G1#TIME(desc) #G2#FREQ(desc) #G2#TIME(desc))

---

#### sort_linguistic

**Syntax** : `true` | `false`

指定是否在排序时遵循当前区域设置的默认 collating sequence 选项。

> [!NOTE]
>
> 指定 `sort_linguistic = true` 相当于指定了 `PROC SQL` 语句的 [SORTSEQ = LINGUISTIC](https://documentation.sas.com/doc/zh-CN/pgmsascdc/9.4_3.5/sqlproc/p12ohgh32ffm6un13s7l2d5p9c8y.htm#p0i5z6z3vnmjd2n1abnsp9p3bc05) 选项。

**Default** : `true`

**Usage** :

```sas
sort_linguistic = false
```

---

#### at_least

**Syntax** : `true` | `false`
Expand Down
7 changes: 5 additions & 2 deletions src/gb18030/ass2.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass2
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass2(indata,
Expand All @@ -14,6 +14,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -34,6 +35,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -57,6 +59,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -508,7 +511,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
7 changes: 5 additions & 2 deletions src/gb18030/ass3.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass3
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass3(indata,
Expand All @@ -16,6 +16,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -38,6 +39,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -63,6 +65,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -563,7 +566,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
7 changes: 5 additions & 2 deletions src/gb2312/ass2.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass2
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass2(indata,
Expand All @@ -14,6 +14,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -34,6 +35,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -57,6 +59,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -508,7 +511,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
7 changes: 5 additions & 2 deletions src/gb2312/ass3.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass3
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass3(indata,
Expand All @@ -16,6 +16,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -38,6 +39,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -63,6 +65,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -563,7 +566,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
7 changes: 5 additions & 2 deletions src/gbk/ass2.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass2
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass2(indata,
Expand All @@ -14,6 +14,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -34,6 +35,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -57,6 +59,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -508,7 +511,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
7 changes: 5 additions & 2 deletions src/gbk/ass3.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass3
* Macro Purpose: �����¼�����
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass3(indata,
Expand All @@ -16,6 +16,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(���ٷ���һ��AE),
at_least_output_if_zero = false,
Expand All @@ -38,6 +39,7 @@
* arm: ����-�������#null ��ʾ����
* arm_by: ����-������������ʽ�����ܵ�ȡֵ�У���ֵ�ͱ����������ʽ��#null��#null ��ʾ����
* sort_by: ���ܽ�����ݼ��й۲������ʽ����ϸ�﷨�ο������ĵ�
* sort_linguistic: �Ƿ�������ʱ��ѭ��ǰ�������õ�Ĭ�� collating sequence ѡ��
* at_least: �Ƿ��ڻ��ܽ�����ݼ��ĵ�һ��������ٷ���һ�β����¼���ͳ�ƽ��
* at_least_text: at_least = true ʱ�����ܽ�����ݼ��ĵ�һ����ʾ���������ı�
* at_least_output_if_zero �����ٷ���һ�β����¼��ĺϼ�����Ϊ��ʱ���Ƿ���Ȼ�ڻ��ܽ�����ݼ������
Expand All @@ -63,6 +65,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -563,7 +566,7 @@
quit;

/*����*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
Binary file modified src/utf16/ass2.sas
Binary file not shown.
Binary file modified src/utf16/ass3.sas
Binary file not shown.
7 changes: 5 additions & 2 deletions src/utf8/ass2.sas
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* Macro Name: ass2
* Macro Purpose: 不良事件汇总
* Author: wtwang
* Version Date: 2025-06-25
* Version Date: 2025-07-16
*/

%macro ass2(indata,
Expand All @@ -14,6 +14,7 @@
arm = #null,
arm_by = %nrstr(&arm),
sort_by = %str(#FREQ(desc) #TIME(desc)),
sort_linguistic = true,
at_least = true,
at_least_text = %str(至少发生一次AE),
at_least_output_if_zero = false,
Expand All @@ -34,6 +35,7 @@
* arm: 变量-试验组别,#null 表示单组
* arm_by: 变量-试验组别的排序方式,可能的取值有:数值型变量、输出格式、#null,#null 表示单组
* sort_by: 汇总结果数据集中观测的排序方式,详细语法参考帮助文档
* sort_linguistic: 是否在排序时遵循当前区域设置的默认 collating sequence 选项
* at_least: 是否在汇总结果数据集的第一行输出至少发生一次不良事件的统计结果
* at_least_text: at_least = true 时,汇总结果数据集的第一行显示的描述性文本
* at_least_output_if_zero 当至少发生一次不良事件的合计例数为零时,是否仍然在汇总结果数据集中输出
Expand All @@ -57,6 +59,7 @@
%let arm = %upcase(%sysfunc(strip(%bquote(&arm))));
%let arm_by = %upcase(%sysfunc(strip(%bquote(&arm_by))));
%let sort_by = %upcase(%sysfunc(strip(%bquote(&sort_by))));
%let sort_linguistic = %upcase(%sysfunc(strip(%bquote(&sort_linguistic))));
%let at_least = %upcase(%sysfunc(strip(%bquote(&at_least))));
%let at_least_text = %sysfunc(strip(%superq(at_least_text)));
%let at_least_output_if_zero = %upcase(%sysfunc(strip(%bquote(&at_least_output_if_zero))));
Expand Down Expand Up @@ -508,7 +511,7 @@
quit;

/*排序*/
proc sql noprint;
proc sql noprint %if %bquote(&sort_linguistic) = %upcase(true) %then %do; sortseq = linguistic %end;;
create table tmp_summary_formated_sorted as
select * from tmp_summary_formated
order by &aesoc._FLAG,
Expand Down
Loading