cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar

Set column as Marker for a graphic.

Hello everyone,

 

I'm triying to put a column which contains pictures as marker for a graphic. 

 

This is what i want : 

CheeseProgram_0-1650970537241.png

When I make this graphic get the script and copy it in my script then play it I got this : 

CheeseProgram_1-1650970614239.png

 

In fact I have to select this : 

 

CheeseProgram_2-1650970659423.png

 which "is define a column as shape" and it works. ( yes i'm french ).

 

But i would like to have a script which make it. 

 

This script should be good : 

CheeseProgram_3-1650970755834.png

but it doesn't work.

 

 

And a second question is about marker size, i would like to decide how many size i want because JMP selection is too big when i use continuous variable as size. 

 

Have a nice day,

 

Dorian Grousset

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
SDF1
Super User

Re: Set column as Marker for a graphic.

Hi @CheeseProgram ,

 

  Your JSL that you save should work, at least in looking it over, I would think it should work. One possibility why it doesn't might be the reference to the column. When you call the Set Shape Column() command, you might need to change the column reference within it to something like :"Column name"n with the parentheses and 'n' at the end. JMP has replaced the former :Name("Column name") with the :"name here"n format. It's possible that could be causing problems in the script.

 

  I tried it out using the Big Class Families.jmp file in the sample directory. I got something like the following, which is basically what you want: 

SDF1_0-1650975898212.png

  This is the JSL code saved from the Graph Builder platform I used to generate the above graph.

Graph Builder(
	Size( 534, 456 ),
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :weight ), Size( :age ) ),
	Elements(
		Points( X, Y, Legend( 3 ), Set Shape Column( :picture ) ),
		Smoother( X, Y, Legend( 4 ) )
	),
	SendToReport(
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model(
				3,
				Properties(
					0,
					{Marker Scale( {N Labels( 5 )} )},
					Item ID( "age", 1 )
				)
			)}
		)
	)
);

  I think you have to first manually set the image column as well as the number of levels (I'm using age as an ORDINAL size variable). You might need to change your :Feret size column to ordinal instead of continuous as this might allow for more flexibility when defining the number of levels.

 

  If you right click on the size options and select size settings...

SDF1_1-1650976053970.png

 

  You can define the number of levels (or labels) to show on the legend.

SDF1_2-1650976082470.png

  

  When I save and run the above JSL script, it works as expected and reproduces the graph that I had manually created in order to generate the script to begin with.

 

  I hope this helps.

 

Good luck!,

DS

View solution in original post

2 REPLIES 2
SDF1
Super User

Re: Set column as Marker for a graphic.

Hi @CheeseProgram ,

 

  Your JSL that you save should work, at least in looking it over, I would think it should work. One possibility why it doesn't might be the reference to the column. When you call the Set Shape Column() command, you might need to change the column reference within it to something like :"Column name"n with the parentheses and 'n' at the end. JMP has replaced the former :Name("Column name") with the :"name here"n format. It's possible that could be causing problems in the script.

 

  I tried it out using the Big Class Families.jmp file in the sample directory. I got something like the following, which is basically what you want: 

SDF1_0-1650975898212.png

  This is the JSL code saved from the Graph Builder platform I used to generate the above graph.

Graph Builder(
	Size( 534, 456 ),
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :weight ), Size( :age ) ),
	Elements(
		Points( X, Y, Legend( 3 ), Set Shape Column( :picture ) ),
		Smoother( X, Y, Legend( 4 ) )
	),
	SendToReport(
		Dispatch(
			{},
			"400",
			ScaleBox,
			{Legend Model(
				3,
				Properties(
					0,
					{Marker Scale( {N Labels( 5 )} )},
					Item ID( "age", 1 )
				)
			)}
		)
	)
);

  I think you have to first manually set the image column as well as the number of levels (I'm using age as an ORDINAL size variable). You might need to change your :Feret size column to ordinal instead of continuous as this might allow for more flexibility when defining the number of levels.

 

  If you right click on the size options and select size settings...

SDF1_1-1650976053970.png

 

  You can define the number of levels (or labels) to show on the legend.

SDF1_2-1650976082470.png

  

  When I save and run the above JSL script, it works as expected and reproduces the graph that I had manually created in order to generate the script to begin with.

 

  I hope this helps.

 

Good luck!,

DS

Re: Set column as Marker for a graphic.

Hello,

 

that's good, I just put the definition of my variable before my graphic construction, in fact i was confused by too much graph. For this part this is good.

 

For the second part is there any option to use continuous variable as size ? For exemple JMP use my continuous variable as coefficient to set the size. In my example my pictures has to be represented with their size so if I put groups of size it doesn't look good. 

 

Thanks a lot and have nice day !