Virtual Join links a main data table to one or more auxiliary data tables. The feature enables the main data table to access data from the auxiliary data tables without physically joining the tables. See 虚拟连接数据表 in the Using JMP book for details.
dt1 = Open( "$SAMPLE_DATA/Pizza Profiles.jmp" );
dt1:ID << Set Property( "Link ID", 1 );
// add Link ID and turn it on
dt2 = Open( "$SAMPLE_DATA/Pizza Responses.jmp" );
dt2:Choice1 << Set Property( "Link Reference", Reference Table( "$SAMPLE_DATA/Pizza Profiles.jmp" ) );
dt2:Choice2 << Set Property( "Link Reference", Reference Table( "$SAMPLE_DATA/Pizza Profiles.jmp" ) );
dt2:Choice << Set Property( "Link Reference", Reference Table( "$SAMPLE_DATA/Pizza Profiles.jmp" ) );
// add Link Reference to the Choice1, Choice2, and Choice columns
obj = dt2 << Distribution( // create a distribution of Crust[Choice1]
Weight( :Subject ),
Nominal Distribution(
Column(
Referenced Column(
"Crust[Choice1]",
Reference( Column( :Choice1 ), Reference( Column( :Crust ) ) )
)
)
),
Nominal Distribution( Column( :Choice1 ) )
);