cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
antonio-domenic
Level III

JMP15 Graph Builder does not update Map after changing -XY coordinates file


old working JMP13 script does not work anymore with JMP15. The script changes the coordinates of -XY map file and neither Graph Builder updates nor the changed map appear creating a new graph builder instance. Just opening a new session new map is shown. It looks like that a sort of caching prevent updates.

Is it possible to fix or workaround this behavior?

dt2 = open("C:/TEMP/map-Name.jmp");
dt3 = open("C:/TEMP/map-XY.jmp");
dt= open("C:/TEMP/map.jmp");

new window("shift up",
	gb = dt << Graph Builder(
		Size( 1381, 885 ),
		Variables( Shape( :xy ) ),
		Elements( Map Shapes( Legend( 6 ) ) )
	);

	text box("shift up selected columns by 10"),
	button box("up",
		rws= dt<< Get Selected Rows();
		if(nrows(rws),
			r=[];
			for(j=1, j<=nitems(rws), j++,
				sh= dt[rws[j],"X"];
				dt << select where(:X == sh);
				rw= dt << get selected rows;
				r= r |/ rw;
				
			);
			
			
			for(i=1, i<=nitems(r), i++,
						dt[r[i],"bottom"]=dt[r[i],"bottom"] + 10;
						dt[r[i],"top"]=dt[r[i],"top"] + 10;

			);
			rws= r;
			values= column(dt,"xy")[rws];
				
			rws= dt2 << get rows where( Contains( values, :Name ) );
			shapes= column(dt2,"Shape ID")[rws];
			
			rws = dt3 <<  get rows where(Contains( shapes, :Name("Shape ID") ) );
			sy = column(dt3,"Y1") << get values;
			for(i=1, i<=nrows(rws), i++,
					sy[rws[i]] = sy[rws[i]] + 10;
			);
			column(dt3, "Y1") << set values(sy);
			dt3<<save("C:\TEMP\map-XY.jmp");
			//the following the way used to update graph builder with JMP13
				//window:gb <<reshow;
				//ColumnSwitcherObject = window:gb << Column Switcher( :xy, {:xy} );
				//ColumnSwitcherObject << Next;
				//ColumnSwitcherObject << run;
				//ColumnSwitcherObject << remove column switcher;
		,
			caption("nothing selected");
		);	
	),
);	
3 REPLIES 3
xxvvcczz
Level III

Re: JMP15 Graph Builder does not update Map after changing -XY coordinates file

I've got this same problem right now. 

 

It's driving me crazy...

 

I'm going to attempt a delete symbols approach and see if I can get JMP to let go of the stale reference.

antonio-domenic
Level III

Re: JMP15 Graph Builder does not update Map after changing -XY coordinates file

I addressed this problem to JMP support team. They answered me that this bug is fixed in the version 16, while for versions 15.x no release were in plan. 

xxvvcczz
Level III

Re: JMP15 Graph Builder does not update Map after changing -XY coordinates file

My organization doesn't have JMP 16, we barely have major rollout of 15

 

Guess I have to workaround by redrawing, bummer. Thanks for answer!