// sample data
dt = Open( "$SAMPLE_DATA/Consumer Preferences.jmp" );
col = New Column( :Gender );
// get JMP version as a number
jmpVersionNumber = num(words(JMPVersion(),".")[1]);
// don't use 'update properties' before v16
if (jmpVersionNumber>=16,
dt << Recode Column(
:Gender,
{if(
_rcNow == 1, 0,
1,
)},
Update Properties( 1 ),
Target Column( col )
)
, // else
dt << Recode Column(
:Gender,
{if(
_rcNow == 1, 0,
1,
)},
Target Column( col )
)
);
-Dave