SAS Programming

DATA Step, Macro, Functions and more
BookmarkSubscribeRSS Feed
amorts
Calcite | Level 5
Hi All, I am new to SAS EG and don’t have access to Data Flux. I would like to run some basic data profiling (min, max, count, Null values etc.) against a group of tables which exist in SAS. I have come across bits and pieces of code online but none seem to be complete and provided in a way that can be easily used. I would imagine it’s a very common task and it would be time consuming to hand code which is what I would like to avoid. I want to provide a table name and for the code to run some basic checks and output the results based upon the table structure and data types. Thanks for your help
4 REPLIES 4
RW9
Diamond | Level 26 RW9
Diamond | Level 26

Proc means, proc freq.  You might also use SQL for some other checks.  Plenty of documentation and examples out there including the SAS documentation:

http://support.sas.com/documentation/cdl/en/procstat/66703/HTML/default/viewer.htm#procstat_freq_syn...

amorts
Calcite | Level 5
Hi, thanks for the response. I have tried using it without any specifications beyond the dataset like this:
proc freq data=library.tablename
run;
And I get the following error:
ERROR: File library.tablename.DATA does not exist.
ERROR: The metadata for the table/view library.tablename does not exist.
ERROR 22-322: Syntax error, expecting one of the following: ;, (, ALPHA, CHARTYPE, CLASSDATA, CLM, COMPLETETYPES, CSS, CV, DATA,
DESCEND, DESCENDING, DESCENDTYPES, EXCLNPWGT, EXCLNPWGTS, EXCLUSIVE, FW, IDMIN, KURTOSIS, LCLM, MAX, MAXDEC, MEAN,
MEDIAN, MIN, MISSING, MODE, N, NDEC, NMISS, NOLABELS, NONOBS, NOPRINT, NOTHREADS, NOTRAP, NWAY, ORDER, P1, P10, P20,
P25, P30, P40, P5, P50, P60, P70, P75, P80, P90, P95, P99, PCTLDEF, PRINT, PRINTALL, PRINTALLTYPES, PRINTIDS,
PRINTIDVARS, PROBT, Q1, Q3, QMARKERS, QMETHOD, QNTLDEF, QRANGE, RANGE, SKEWNESS, STACKODS, STACKODSOUTPUT, STDDEV,
STDERR, SUM, SUMSIZE, SUMWGT, T, THREADS, UCLM, USS, VAR, VARDEF.
ERROR 202-322: The option or parameter is not recognized and will be ignored.
As my SAS set up and permissions on new I wanted to check if this could be related?
Reeza
Super User

In EG use the TASKS item, Characterize Data.

 

 

Tasks>Describe>Characterize Data.

 

amorts
Calcite | Level 5
Thank you. That seems to be working now although is taking a long time.

I'll take a look into how I can't reduce the time it takes.

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

Register now!

How to Concatenate Values

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 4 replies
  • 4022 views
  • 2 likes
  • 3 in conversation