+ Reply to Thread
Results 1 to 2 of 2

Thread: ODS Output question

  1. #1
    Points: 1,457, Level: 21
    Level completed: 57%, Points required for next Level: 43

    Location
    Cincinnati, OHIO
    Posts
    31
    Thanks
    0
    Thanked 0 Times in 0 Posts

    ODS Output question



    I'm using the ODS Output procedure to send a number of data sets (in .csv format) to a folder that resides on the UNIX box of our firm's SAS server. In PROC EXPORT, you can send a data set to an individual sheet within an Excel workbook instead of creating an individual workbook for each set. Can you do the same thing with ODS? Here's my code. Any suggestions would be greatly appreciated. Thanks.

    options

    missing=" ";
    title

    'OUTSTANDINGS BY REGION';
    /*OUTSTANDINGS BY REGION (HISTORICAL3)*/

    proc tabulate data=service_table out=outstandings_region format=comma10. noseps;
    class serv_month region;
    var nte01t_note_cpb;
    table serv_month*(region ALL='Total'),
    (nte01t_note_cpb='Outstandings')*f=dollar16.2 (ALL='Count');
    keylabel N='#';
    run;

    ods listing close;
    ods csv file='/sharedhome/j024543/nelnet/landon/OUTSTANDINGS_BY_REGION.CSV';
    proc print data=outstandings_region;
    title
    'OUTSTANDINGS BY REGION';
    run;
    ods csv close;
    ods listing;

    options missing=" ";
    title 'DELINQUENCY BUCKETS & PERCENTAGES';
    /*DELINQUENCY BUCKETS & PERCENTAGES*/

    proc tabulate data=service_table out=delq_buckets_pcts format=comma10. noseps;
    class serv_month region delq_cycle;
    var nte01t_note_cpb;
    table serv_month*(delq_cycle ALL='Total'),
    (nte01t_note_cpb= 'Outstandings')*f=dollar16.2*(sum='$' pctsum<delq_cycle ALL>='Rate'*f=tabpct.)(ALL='Count');
    /*keylabel sum='$' pctsum='Rate';*/
    keylabel N='#';
    run;

    ods listing close;
    ods csv file='/sharedhome/j024543/nelnet/landon/DELQ_BUCKETS_PCTS.CSV';
    proc print data=delq_buckets_pcts;
    title 'DELINQUENCY BUCKETS & PERCENTAGES';
    run;
    ods csv close;
    ods listing;

  2. #2
    Points: 2,626, Level: 31
    Level completed: 18%, Points required for next Level: 124

    Location
    Dallas, TX
    Posts
    311
    Thanks
    12
    Thanked 94 Times in 93 Posts

    Re: ODS Output question


    Use ods tagsets.excelXP file=

    Specify a file name with .xml format. This will create a different sheet within the same file for each proc.

+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts








Advertise on Talk Stats