try(close(dtLatLon,nosave));
try(close(dtTempTime,nosave));
dtLatLon = New Table( "LatLon",
New Column( "city", Character, "Nominal", Set Values( {"New York", "London"} ) ),
New Column( "lat", Numeric, "Continuous", Format( "Best", 12 ), Set Values( [40.73061, 51.509865] ) ),
New Column( "lon", Numeric, "Continuous", Format( "Best", 12 ), Set Values( [-73.935242, -0.118092] ) )
);
dtLatLon << save( "$temp/LatLon_deleteme.jmp" ); // disk file name is required for virtual join
dtLatLon:city << Set Property( "Link ID", 1 );
dtTempTime = New Table( "TempTime",
New Column( "city", Character, "Nominal",
Set Values( {"New York", "London", "New York", "London", "New York", "London", "New York", "London", "New York", "London"} )
),
New Column( "temp", Numeric, "Continuous", Format( "Best", 12 ), Set Values( [18, 30, 18, 12, 24, 17, 15, 30, 29, 19] ) ),
New Column( "time", Numeric, "Continuous", Format( "yyyy-mm-ddThh:mm", 16 ), Input Format( "yyyy-mm-ddThh:mm" ),
Set Values( [3660682600, 3660683600, 3660684600, 3660685600, 3660686600, 3660687600, 3660688600, 3660689600, 3660690600, 3660691600] )
)
);
dtTempTime << save( "$temp/TempTime_deleteme.jmp" ); // disk file name is required
dtTempTime:city << Set Property( "Link Reference", Reference Table( dtLatLon ) );
dtTempTime << Bubble Plot(
X( Referenced Column( "lon[city]", Reference( Column( :city ), Reference( Column( :lon ) ) ) ) ),
Y( Referenced Column( "lat[city]", Reference( Column( :city ), Reference( Column( :lat ) ) ) ) ),
Sizes( :temp ),
Time( :time ),
ID( :city ),
Time Index( 4.0938 ),
Title Position( -59.21926910299, 46.12 ),
SendToReport(
Dispatch( {}, "1", ScaleBox, {Format( "Best", 12 ), Min( -80 ), Max( 10 ), Inc( 10 ), Minor Ticks( 0 )} ),
Dispatch(
{},
"2",
ScaleBox,
{Scale( "Geodesic" ), Format( "Best", 12 ), Min( 19.0897009966777 ), Max( 72.9102990033223 ), Inc( 2 ), Minor Ticks( 1 )}
),
Dispatch(
{},
"Bubble Plot",
FrameBox,
{Frame Size( 602, 360 ), Background Map( Boundaries( "World" ) ), Grid Line Order( 2 ), Reference Line Order( 3 )}
)
)
);
Yours will look simpler since your data already exists. You might have a numeric ID rather than a city name to link the tables together.
Bubble Plot
Craige