BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Becca
Calcite | Level 5

I have a few data sets that I have merged together and manipulated with PROC REPORT. I am struggling with two things

  • I can't seem to figure out how to get a 0 input for missing/blank data
  • I need to export this data into notepad as a txt file

Any help/hints would be great!

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
SASKiwi
PROC Star

options missing = '0'; ?

View solution in original post

3 REPLIES 3
SASKiwi
PROC Star

options missing = '0'; ?

Becca
Calcite | Level 5

Thanks! That worked like a charm! 

Cynthia_sas
SAS Super FREQ

Hi:

  When you say that you "need to export this data into notepad as a txt file", do you mean you need to export ONLY the data or you need a PROC REPORT type report in a TEXT file. You can simply use ODS LISTING FILE= if you want the PROC REPORT output in Notepad/TXT file, however, this will send your SAS titles to the TXT file too. Something like the program below. Otherwise, you could do something with a DATA Step program.

Cynthia

ods _all_ close;

ods listing file='c:\temp\myreport.txt';

options nodate number pageno=1;

 

proc report data=sashelp.class ls=80 ps=60;

title 'This is the Title';

column name sex age height weight;

define name / order;

define sex / display f=$3.;

define age / display;

define height / display;

define weight / display;

run;

ods listing close;


save_report_as_txt.png

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1271 views
  • 0 likes
  • 3 in conversation