|
试下这个:
Use the SHEET_NAME= and SHEET_INTERVAL= options to specify the name of a worksheet as well as the interval in which to create new worksheets.
ods tagsets.excelxp file='multitable.xml' style=statistical
options(auto_subtotals='yes' default_column_width='7, 10, 10, 7, 7'
frozen_rowheaders='yes' sheet_interval='none' sheet_name='Canada'
autofilter='all' autofilter_table='2');
*;
* The output from the following two procs will be in a single worksheet
* with a user-specified name of 'Canada'.
*;
proc tabulate data=prdsale;
where country eq 'CANADA' and year eq 1993;
var predict actual;
class region division prodtype;
table
region*(division*prodtype all={label='Division Total'}) all={label='Grand Total'},
predict={label='Total Predicted Sales'}*f=dollar10.*sum={label=''}
actual={label='Total Actual Sales'}*f=dollar10.*sum={label=''};
run; quit;
proc print data=prdsale noobs label split='*';
where country eq 'CANADA' and year eq 1993;
id country region division;
var prodtype product quarter month year;
sum predict / style={tagattr='format:Currency'};
sum actual / style={tagattr='format:Currency'};
sum difference / style={tagattr='format:Currency formula:RC[-1]-RC[-2]'};
label prodtype = 'Product*Type'
predict = 'Predicted*Sales'
actual = 'Actual*Sales';
run; quit;
|