dear all, I would like to export to sav some ctables results, but once the data are exported I see generic column names: ColumnN ColumnN_A ColumnN_B. I would like to see as column name something relatated to data, such as area_a area_b area_c.
is that possible? here's an example to clarify my situation data list list / id * product (A3) area (A1) . begin data 1 "P_1" "b" 2 "P_2" "a" 3 "P_2" "a" 4 "P_3" "c" 5 "P_4" "c" 6 "P_1" "a" 7 "P_1" "a" 8 "P_1" "b" 9 "P_1" "c" 10 "P_2" "b" end data. * OMS. DATASET DECLARE my_table. OMS /SELECT TABLES /IF COMMANDS=['CTables'] SUBTYPES=['Custom Table'] /DESTINATION FORMAT=SAV NUMBERED=TableNumber_ OUTFILE='my_table'. * Custom Tables. CTABLES /VLABELS VARIABLES=product area DISPLAY=LABEL /TABLE product [COLPCT.COUNT PCT40.1] BY area /CATEGORIES VARIABLES=product area ORDER=A KEY=VALUE EMPTY=EXCLUDE. omsend. |
OMS has a default way of naming columns which I don't believe is adjusatble. You can only after creation of OMS CTABLE dataset change variable names. I would do something like this (assuing you know how many area categories you shall have so to be able to specify Area_1 to Area_4):
=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD
dataset activate my_table. numeric EndVar (f1.0). rename variables (ColumnN to EndVar=Area_1 to Area_4). add files file=* /drop=Area_4. On 27 November 2015 at 10:48, progster <[hidden email]> wrote: dear all, I would like to export to sav some ctables results, but once the |
Free forum by Nabble | Edit this page |