Skip to content

PharmaForest/sas_compare

Repository files navigation

sas_compare

Compares SDTM/ADaM, TLF datasets, etc. Assume a double program in the pharmaceutical industry to compare main and sub

Image

%ads_compare

Main Functions :

  • Iteratively compares a list of target datasets between two libraries.
  • Creates a unique output folder using date and time.
  • Generates PROC COMPARE reports as PDF files.
  • Automatically renames the result files to indicate "OK" or "NG" compare-match status.
  • Aggregates comparison results into a summary dataset.
  • Exports the summary as an Excel file.

Parameters :

  output_folder : Full path to the folder where output files will be saved.
  main_lib_path : Path to the main library containing the original ADaM datasets.
  sub_lib_path  : Path to the sub library containing the comparison ADaM datasets.
  target_list   : Space-delimited list of dataset names to compare.

Usage Example :

  %ads_compare(
    output_folder = D:/project/output,
    main_lib_path = D:/project/main,
    sub_lib_path  = D:/project/sub,
    target_list   = A
                    B
                    C
                    D
                    E
  );
Image Image Image

Notes on versions history

  • 0.1.1(28August2025): BugFix.
  • 0.1.0(09July2025): Initial version.

What is SAS Packages?

The package is built on top of SAS Packages Framework(SPF) developed by Bartosz Jablonski.

For more information about the framework, see SAS Packages Framework.

You can also find more SAS Packages (SASPacs) in the SAS Packages Archive(SASPAC).

How to use SAS Packages? (quick start)

1. Set-up SAS Packages Framework

First, create a directory for your packages and assign a packages fileref to it.

filename packages "\path\to\your\packages";

Secondly, enable the SAS Packages Framework. (If you don't have SAS Packages Framework installed, follow the instruction in SPF documentation to install SAS Packages Framework.)

%include packages(SPFinit.sas)

2. Install SAS package

Install SAS package you want to use with the SPF's %installPackage() macro.

  • For packages located in SAS Packages Archive(SASPAC) run:

    %installPackage(packageName)
  • For packages located in PharmaForest run:

    %installPackage(packageName, mirror=PharmaForest)
  • For packages located at some network location run:

    %installPackage(packageName, sourcePath=https://some/internet/location/for/packages)

    (e.g. %installPackage(ABC, sourcePath=https://github.com/SomeRepo/ABC/raw/main/))

3. Load SAS package

Load SAS package you want to use with the SPF's %loadPackage() macro.

%loadPackage(packageName)

Enjoy!

About

mirror of sas_compare

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages