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 ) )
);